Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
define('PHPWG_ROOT_PATH','./');
define('IN_ADMIN', true);

echo $_GET['asdf'];

Comment on lines +16 to +17

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reflected XSS Vulnerability in admin.php (Severity: MEDIUM)

This reflected XSS vulnerability allows an attacker to inject arbitrary JavaScript into the application, potentially leading to account takeover or data theft. The admin.php script directly echoes the asdf GET parameter on lines 16-17 without proper sanitization or escaping, which causes any supplied JavaScript code to execute in the user's browser. An attacker could craft a malicious link and trick a user into clicking it, resulting in the execution of the injected script.
View details in ZeroPath

Suggested change
echo $_GET['asdf'];
echo isset($_GET['asdf']) ? htmlspecialchars($_GET['asdf'], ENT_QUOTES, 'UTF-8') : '';

include_once(PHPWG_ROOT_PATH.'include/common.inc.php');
include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
include_once(PHPWG_ROOT_PATH.'admin/include/functions_plugins.inc.php');
Expand Down