Skip to main content

Automatic information enumeration - Personal Information

Description

It is possible to list information and login method of the platform users, since a token associated to the account is not used to consult the information, thus leaving open the possibility to consult information of other users.

Impact

  • Identify users login method.
  • Obtain strategic information. from users accounts.

Recommendation

Implement controls with cookies or session tokens to limit the information viewed by a user.

Threat

Authenticated attacker from the Internet.

Expected Remediation Time

⌚ 60 minutes.

Score

Default score using CVSS 3.1. It may change depending on the context of the vulnerability.

Base

  • Attack vector: N
  • Attack complexity: L
  • Privileges required: L
  • User interaction: N
  • Scope: U
  • Confidentiality: L
  • Integrity: N
  • Availability: N

Temporal

  • Exploit code madurity: X
  • Remediation level: X
  • Report confidence: X

Result

  • Vector string: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N/E:X/RL:X/RC:X
  • Score:
    • Base: 4.3
    • Temporal: 4.3
  • Severity:
    • Base: Medium
    • Temporal: Medium

Code Examples

Compliant code

The application correctly validates the user session token before allowing access to user information

const accessHandler = (req, res) => {
// get users credentials from the JSON body
const { username, password } = req.body
if (!isValidUser(username, password)) {
res.status(401).end();
return;
}
// Return user information according to the sessionToken
return UserInformation(username, req.body.sessionToken);
}

Non compliant code

The application does not verify the session token before allowing access to sensitive information

const accessHandler = (req, res) => {
// get users credentials from the JSON body
const { username, password } = req.body
if (!username || !password) {
res.status(401).end();
return;
}
// Return user information without using token control
return UserInformation(username);
}

Requirements

free trial

Search for vulnerabilities in your apps for free with our automated security testing! Start your 21-day free trial and discover the benefits of our Continuous Hacking Machine Plan. If you prefer a full service that includes the expertise of our ethical hackers, don't hesitate to contact us for our Continuous Hacking Squad Plan.