Skip to content

Exposure of sensitive system information

Description

The 'phpinfo' function may reveal sensitive information about your environment, such as PHP version, configuration, and other details that could be used by an attacker.

Examples

Insecure Code

php
phpinfo();

Secure Code

php
// phpinfo();

Remediation

Remove or comment out the 'phpinfo' function call to prevent exposure of sensitive system information.

Rule Details

FieldValue
IDCODE-0753
CategoryInsecureConfig
SeverityMEDIUM
CWECWE-497
ConfidenceHIGH
ImpactMEDIUM
LikelihoodHIGH
ExploitabilityEASY
Tagssensitive information, exposure
OWASPA5:2017-Broken Access Control, A01:2021-Broken Access Control

References