Skip to content

Instantly share code, notes, and snippets.

@k1sul1
Last active January 21, 2016 13:52
Show Gist options
  • Save k1sul1/87a96f1ca63520ea0187 to your computer and use it in GitHub Desktop.
Save k1sul1/87a96f1ca63520ea0187 to your computer and use it in GitHub Desktop.
Short snippet to use with WPScan, discards all unnecessary data and prints only the alarming fields.
// pipe script output to this script:
// ./wpscan --url=http://site.fi | php wp_check_for_vulnerabilities.php
$error = false;
while(!feof(STDIN)){
$line = fgets(STDIN);
if(strpos($line,"[!]")){
echo $line;
$error = true;
}
else{
if($error){
if(strpos($line,"[+]")){
$error = false;
}
else{
echo $line;
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment