0

Is there any software that I can run on either a Linux or a Windows server to check for domains that have out dated WordPress installations. I have seen a rise in hacked WordPress sites and in all the cases it was because the clients had not installed updates.

1
  • 1
    what about google webmaster tools?
    – Bainternet
    Commented Feb 13, 2013 at 9:41

2 Answers 2

2

If you can access the files from the server just include wp-includes/version.php from each installation. That file is completely stand-alone, it just defines five variables:

/**
 * The WordPress version string
 *
 * @global string $wp_version
 */
$wp_version = '3.5.1';

/**
 * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
 *
 * @global int $wp_db_version
 */
$wp_db_version = 22441;

/**
 * Holds the TinyMCE version
 *
 * @global string $tinymce_version
 */
$tinymce_version = '358-23224';

/**
 * Holds the required PHP version
 *
 * @global string $required_php_version
 */
$required_php_version = '5.2.4';

/**
 * Holds the required MySQL version
 *
 * @global string $required_mysql_version
 */
$required_mysql_version = '5.0';

A simple version_compare() will do the trick:

if ( '-1' == version_compare( $wp_version, '3.5.1' ) )
    return 'outdated';
0

A simple solution would be to just use wget and grep the meta generator for example:

//need xml2 installed
wget -q -O - http://www.example.com | xml2 | grep meta | awk -F/ '{print $NF}' 

The problem is that a lot of people remove the meta generator tag, so then I suggest you have a look at this answer by Otto (the file he links ) on where else to check for version info, Remotely identify the version of a WordPress installation?

There are also WordPress scanners that do version fingerprinting, namely WPScan, you can Google it.

If you have access to server files then toscho's answer is the best.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.