1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Submitting reCaptcha (v1 and v2) with PHP?

Discussion in 'PHP & Perl' started by HeXeR, Nov 21, 2015.

  1. HeXeR

    HeXeR Junior Member

    Joined:
    Dec 30, 2007
    Messages:
    122
    Likes Received:
    15
    Occupation:
    Self-employed
    Location:
    EU
    Home Page:
    Doable? Anyone got working version yet? Or at least some ideas...

    There are loads of versions "floating" around internet but I've only managed to find the ones using fallback API which requires "clean" IP (JS version would work with most if not all IPs).

    Ofc. the problem is JS version is heavily obfuscated and without generating and populating proper variables... you can't get anywhere.
     
  2. revproxy

    revproxy BANNED BANNED Jr. VIP Premium Member

    Joined:
    Nov 20, 2015
    Messages:
    396
    Likes Received:
    100
    Gender:
    Male
    https://github.com/google/recaptcha/blob/master/examples/example-captcha.php
     
  3. HeXeR

    HeXeR Junior Member

    Joined:
    Dec 30, 2007
    Messages:
    122
    Likes Received:
    15
    Occupation:
    Self-employed
    Location:
    EU
    Home Page:
  4. revproxy

    revproxy BANNED BANNED Jr. VIP Premium Member

    Joined:
    Nov 20, 2015
    Messages:
    396
    Likes Received:
    100
    Gender:
    Male
    works for me... in upload a test for you:
    http://www.damnhole.com/tests/examples/example-captcha.php

    first of all you need site key & secret key from google
    then use composer

    PHP:
    php composer.phar require google/recaptcha "~1.1"
    cp -Rf vendor/google/recaptcha/examples ./
    edit examples/example-captcha.php and set both keys
     
  5. gimme4free

    gimme4free Executive VIP Jr. VIP Premium Member

    Joined:
    Oct 22, 2008
    Messages:
    1,925
    Likes Received:
    1,942
    Home Page:
    The fallback URL is required even for a clean IP. I have not once been able to pass the street sign view with 1 attempt, even on a clean IP. The only times you 'can' pass first time is if you have already passed the checkbox. If you are using an outdated browser & going directly to the street sign view then you should pass on the second/third attempt without issues.
     
  6. Cnotey

    Cnotey Power Member

    Joined:
    Jun 25, 2010
    Messages:
    713
    Likes Received:
    915
    Location:
    Seattle
    Home Page:
    New reCaptcha sucks. I haven't been able to figure it out.

    I'm trying with Python and I managed to get it working once. Then I made one change in my code and it never worked again. Sooooooooo pissed.
     
  7. gimme4free

    gimme4free Executive VIP Jr. VIP Premium Member

    Joined:
    Oct 22, 2008
    Messages:
    1,925
    Likes Received:
    1,942
    Home Page:
    What messed me up for a while was 0-8 images rather than 1-9 :)