[web-php] master: Sanitize request URI for GPG keys link (#1399)

From: Date: Wed, 10 Sep 2025 01:28:03 +0000
Subject: [web-php] master: Sanitize request URI for GPG keys link (#1399)
Groups: php.webmaster 
Request: Send a blank email to php-webmaster+get-33182@lists.php.net to get a copy of this message
Author: Luffy (sy-records) Committer: GitHub (web-flow) Pusher: sy-records Date: 2025-09-10T09:28:01+08:00 Commit: https://github.com/php/web-php/commit/14284c0aac00d563ee4f0893b19f8e44fe17819c Raw diff: https://github.com/php/web-php/commit/14284c0aac00d563ee4f0893b19f8e44fe17819c.diff Sanitize request URI for GPG keys link (#1399) Changed paths: M include/version.inc Diff: diff --git a/include/version.inc b/include/version.inc index bcc8949930..8997441a73 100644 --- a/include/version.inc +++ b/include/version.inc @@ -114,6 +114,8 @@ function show_source_releases() $SHOW_COUNT = 4; + $current_uri = htmlspecialchars($_SERVER['REQUEST_URI'], ENT_QUOTES, 'UTF-8'); + $i = 0; foreach ($RELEASES as $MAJOR => $major_releases): /* major releases loop start */ $releases = array_slice($major_releases, 0, $SHOW_COUNT); ?> @@ -153,7 +155,7 @@ function show_source_releases() </li> </ul> - <a href="<?php echo $_SERVER['REQUEST_URI']; ?>#gpg-<?php echo $mver; ?>">GPG Keys for PHP <?php echo $mver; ?></a> + <a href="<?php echo $current_uri; ?>#gpg-<?php echo $mver; ?>">GPG Keys for PHP <?php echo $mver; ?></a> </div> <?php endforeach; ?> <?php endforeach; /* major releases loop end */ ?>

« previous php.webmaster (#33182) next »