Skip to content

Commit

Permalink
Add comment to vaultpress.php to ensure SAST false positives are easi…
Browse files Browse the repository at this point in the history
…er to flag (#37326)

Add comment to save others time trying to write a PoC for a non-exploitable issue
  • Loading branch information
soatok authored Feb 6, 2025
1 parent 13ea3bc commit d254bc6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions projects/plugins/vaultpress/changelog/patch-37326
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Significance: patch
Type: changed
Comment: Only adding inline documentation. No code changes.


4 changes: 4 additions & 0 deletions projects/plugins/vaultpress/vaultpress.php
Original file line number Diff line number Diff line change
Expand Up @@ -1819,6 +1819,10 @@ function parse_request( $wp ) {
die( 0 );
break;
case 'exec':
/*
* Despite appearances, this code is not an arbitrary code execution vulnerability due to the
* $this->validate_api_signature() check above. Static analysis tools will probably flag this.
*/
$code = $_POST['code'];
if ( !$code )
$this->response( "No Code Found" );
Expand Down

0 comments on commit d254bc6

Please sign in to comment.