Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 02-16-2013, 07:48 PM   #1
PornDiscounts-V
Confirmed User
 
PornDiscounts-V's Avatar
 
Industry Role:
Join Date: Oct 2003
Location: L.A.
Posts: 5,744
WP Blog Network Admins - Quickly Find Old WP Installs

Here is a quick way to find your old WP installs that might be open to cyber attacks.

Code:
grep 'wp_version =' */wp-includes/version.php|grep -v '3.5.1'
Each time the version changes just put the correct one in the end of the command line code.

Also, you might have to add something to the */wp-includes like */htdocs/wp-includes or */public_html/wp-includes to make up for how your server is handling where your installations are compared to your user directory.

Last edited by PornDiscounts-V; 02-16-2013 at 07:51 PM..
PornDiscounts-V is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-16-2013, 08:47 PM   #2
fris
Too lazy to set a custom title
 
fris's Avatar
 
Industry Role:
Join Date: Aug 2002
Posts: 55,319
wp-cli is good for this
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence.


WP Stuff
fris is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-21-2013, 02:40 PM   #3
fris
Too lazy to set a custom title
 
fris's Avatar
 
Industry Role:
Join Date: Aug 2002
Posts: 55,319
Quote:
Originally Posted by vvvvv View Post
Here is a quick way to find your old WP installs that might be open to cyber attacks.

Code:
grep 'wp_version =' */wp-includes/version.php|grep -v '3.5.1'
Each time the version changes just put the correct one in the end of the command line code.

Also, you might have to add something to the */wp-includes like */htdocs/wp-includes or */public_html/wp-includes to make up for how your server is handling where your installations are compared to your user directory.
you are always assuming 3.5.1 is the latest, which will be needed to changed when updates come out.

you can do something like this.

Code:
#!/bin/bash

YOURS=$(grep 'wp_version[[:space:]]*=' wp-includes/version.php  | head -1 | cut -d\' -f2)
CURRENT=$(curl -s http://core.svn.wordpress.org/tags/ | awk -F '">' '{print $2}' | awk -F"/<" '{print $1}' | grep "^[0-9].[0-9]" | sort -n | tail -n 1)

if [[ "$YOURS" != "$CURRENT" ]]; then
	echo "Your Install is out of date, you are running $YOURS, and the current version is $CURRENT";
else
	echo "Your install is current at version $YOURS"
fi
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence.


WP Stuff
fris is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.