« Previous entry | Next entry » Browse > Snippets
Skip to comments (9)
Decoding CAPTCHA using PHP
Posted by TheJohnDoe2005 on Jun 07 2006 @ 11:54 :: 5861 unique visits
Interesting Article that I have found. I Did an upload of a sample CAPTCHA on the site and it did manage to decode it without any hassle....http://captcha.megaleecher.netMain Story
http://digg.com/programming/Decoding_CAPTCHA_using_PHP
Site Story
http://captcha.megaleecher.net
CODE: PHP
NOTE: I removed the data between the two quotes because it is too long. You can go to the site to download the full source code.
$a=explode(";","");
$a=explode(";","");
CODE: PHP
function rapidcode($image)
{
$im=@ImageCreateFromPng($image);
if($im)
{
$a=explode(";","");
for($i=0;$i<34&&!isset($f);$i++)
{
$d=explode(",", $a[$i]);
foreach($d as $xy)
{
$x=substr($xy,0,2);
$y=substr($xy,2);
if(ImageColorAt($im,$x,$y)!=16777215) $f=$i;
else{unset($f);break;}
}
}
for($i=0;$i<34&&!isset($z);$i++)
{
$d=explode(",", $a[$i]);
foreach($d as $xy)
{
$x=substr($xy,0,2)+20;
$y=substr($xy,2);
if(ImageColorAt($im,$x,$y)!=16777215) $z=$i;
else{unset($z);break;}
}
}
for($i=0;$i<34&&!isset($t);$i++)
{
$d=explode(",",$a[$i]);
foreach($d as $xy)
{
$x=substr($xy,0,2)+40;
$y=substr($xy,2);
if(ImageColorAt($im,$x,$y)!=16777215)$t=$i;
else{unset($t);break;}
}
}
} // End IF
$s="RB8DKAW6H0S953NXGMEPU4IF2T1VJZCYL7";
if(isset($f))$f=substr($s,$f,1);
if(isset($z))$z=substr($s,$z,1);
if(isset($t))$t=substr($s,$t,1);
if(isset($f)&&isset($z))return $f.$z.$t;
else return FALSE;
}
?>
{
$im=@ImageCreateFromPng($image);
if($im)
{
$a=explode(";","");
for($i=0;$i<34&&!isset($f);$i++)
{
$d=explode(",", $a[$i]);
foreach($d as $xy)
{
$x=substr($xy,0,2);
$y=substr($xy,2);
if(ImageColorAt($im,$x,$y)!=16777215) $f=$i;
else{unset($f);break;}
}
}
for($i=0;$i<34&&!isset($z);$i++)
{
$d=explode(",", $a[$i]);
foreach($d as $xy)
{
$x=substr($xy,0,2)+20;
$y=substr($xy,2);
if(ImageColorAt($im,$x,$y)!=16777215) $z=$i;
else{unset($z);break;}
}
}
for($i=0;$i<34&&!isset($t);$i++)
{
$d=explode(",",$a[$i]);
foreach($d as $xy)
{
$x=substr($xy,0,2)+40;
$y=substr($xy,2);
if(ImageColorAt($im,$x,$y)!=16777215)$t=$i;
else{unset($t);break;}
}
}
} // End IF
$s="RB8DKAW6H0S953NXGMEPU4IF2T1VJZCYL7";
if(isset($f))$f=substr($s,$f,1);
if(isset($z))$z=substr($s,$z,1);
if(isset($t))$t=substr($s,$t,1);
if(isset($f)&&isset($z))return $f.$z.$t;
else return FALSE;
}
?>
9 comments posted so far
Add your own »
2. On Jun 30 2006 @ 11:38 sian wrote:
sian n jodie woz ere in i.t boored 063. On Sep 07 2006 @ 16:24 vhortex wrote:
this no longer work.. thanks to digg it4. On Aug 25 2007 @ 18:29 Niels wrote:
Now the site is dead there is no full code :/5. On Mar 19 2008 @ 11:05 guest wrote:
I managed to get my hands on it.I give you guys a hint
archive.org
6. On Jul 09 2009 @ 00:46 guest wrote:
chat yapsohbet yap
muhabbet yap
çet yap
chat
sohbet
chat yap
sohbet yap
sevda şiirleri[url]
[url="http://magazin-habercisi.blogspot.com" target="_blank"]"http://magazin-habercisi.blogspot.com" target="_blank"magazin[url]
[url="http://magazin-habercisi.blogspot.com" target="_blank"]"http://magazin-habercisi.blogspot.com" target="_blank"magazin haber[url]
[url="http://magazin-habercisi.blogspot.com" target="_blank"]"http://magazin-habercisi.blogspot.com" target="_blank"magazin dünyası[url]
[url="http://www.dogucafe.com" target="_blank"]"http://www.dogucafe.com" target="_blank" chat[url]
[url="http://www.dogucafe.com" target="_blank"]"http://www.dogucafe.com" target="_blank" sohbet[url]
7. On Jul 09 2009 @ 00:48 guest wrote:
chat yapsohbet yap
muhabbet yap
çet yap
chat
sohbet
chat yap
sohbet yap
sevda şiirleri[URL]
[URL="http://magazin-habercisi.blogspot.com" target="_blank"]"http://magazin-habercisi.blogspot.com" target="_blank"magazin[URL]
[URL="http://magazin-habercisi.blogspot.com" target="_blank"]"http://magazin-habercisi.blogspot.com" target="_blank"magazin haber[URL]
[URL="http://magazin-habercisi.blogspot.com" target="_blank"]"http://magazin-habercisi.blogspot.com" target="_blank"magazin dünyası[URL]
[URL="http://www.dogucafe.com" target="_blank"]"http://www.dogucafe.com" target="_blank" chat[URL]
[URL="http://www.dogucafe.com" target="_blank"]"http://www.dogucafe.com" target="_blank" sohbet[URL]
8. On Jul 14 2009 @ 07:36 guest wrote:
AVI to DVD Converter,AVI to DVD Creator,iPhone Ringtone Maker for Mac,AVI Converter OS X,VOB Converter OS X,AVCHD Video Converter,FLV Converter,PowerPoint Converter,AVCHD Converter,Blue-Ray ripper,Rip Blue Ray,FLV to MOV Mac,VOB to DVD,HD Video Converter,iPod Playlist Transfer9. On Jan 05 2010 @ 14:45 uggbaileybutton wrote:
bailey button uggs-ugg boots cheap
ugg boots uk
ugg classic
1. On Jun 30 2006 @ 11:37 sian wrote:
hello