Jump to content
UBot Underground

How to loop guess decode chosen captcha if incorrectly input?


Recommended Posts

I am working on a bot which is creating forum accounts.

Included in account creation is breaking a captcha. If the captcha is entered incorrectly, the page is reloaded and I am shown a message "The confirmation code was entered incorrectly"

http://www.freeimagehosting.net/uploads/404fd7063d.png

 

I am struggling to find a way for ubot to recognise that the captcha needs re-entering.

I could us an if statement, if, error code (The confirmation code was entered incorrectly) then (decaptcha). The problem with this is I am working with forums in multiple languages. There is no inner our outer html code to recognise the error message.

 

Here is the error in a different language, and the options to choose via attribute. I tried wildcard *class=gen* with no luck

http://www.freeimagehosting.net/uploads/9de419deea.png

Link to post
Share on other sites

I am working on a bot which is creating forum accounts.

Included in account creation is breaking a captcha. If the captcha is entered incorrectly, the page is reloaded and I am shown a message "The confirmation code was entered incorrectly"

http://www.freeimagehosting.net/uploads/404fd7063d.png

 

I am struggling to find a way for ubot to recognise that the captcha needs re-entering.

I could us an if statement, if, error code (The confirmation code was entered incorrectly) then (decaptcha). The problem with this is I am working with forums in multiple languages. There is no inner our outer html code to recognise the error message.

 

Here is the error in a different language, and the options to choose via attribute. I tried wildcard *class=gen* with no luck

http://www.freeimagehosting.net/uploads/9de419deea.png

 

I think you have to try to find a standard attribute that shows up when the error existed. If different language error text shows up for different sites, then I guess you have to set up all the different "if-then" scenerio for the loopback to re-enter the captcha. Unless, there is a standard span or div attribute, or any attribute that is the same throughout all the different error text, which is not the case usually.

I also faced these kind of issues for other platform, I just have to add in all the different error text in my bot for evaluating a action, because there isn't any standard attribute for me to pick on, only text :(

Link to post
Share on other sites

Hey Eric. I was hoping I wasnt going to hear that lol.

But it's workable so cant complain.

 

Another problem I am facing is after the bot recognises that the captcha is wrong, IE needs to refresh.

At current I am using run Javascript to refresh the browser. After the Javascript I have a wait for the page to finish loading to be able to re enter user, pass, email and captcha.

 

After the Javascript command refreshes the page it wont wait for page to load or delay before it clicks submit.

This means that the second attempt at the captcha is unsucessfull.

 

http://www.freeimagehosting.net/uploads/7b681f587d.png

 

Is there another way to refresh the browser?

Link to post
Share on other sites

I tried wait for, didn't seem to do the trick.

The page needs refreshing for the new captcha to load.

 

what i can say is, you use if statement

 

The flow is

if

wait for = "The confirmation code was entered incorrectly"

 

is true

Then run again your script

 

navigate= Registration URL ( this will refresh the page )

Fill in the form again

Link to post
Share on other sites
what i can say is, you use if statement

 

The flow is

if

wait for = "The confirmation code was entered incorrectly"

 

is true

Then run again your script

 

navigate= Registration URL ( this will refresh the page )

Fill in the form again

 

Good thinking.

 

I have added this however I can’t get my head around one little bit.

How to loop the whole script until true or set a limit to attempts e.g. 5.

 

So I have my script here id the flow.

-Gets the captcha error.

-Reload lit item (which is registration page.

-Run Script (the one its on)

 

With this flow, if the captcha attempt is incorrect the second time it finished.

How do I go about continually looping the attempts instead of copy and pasting the code within the current statement.

 

bot attached

Main Bot.ubot

url list.txt

Link to post
Share on other sites

set #counter 0

run sub register

 

sub register

if evaluate #counter = 5 (or whatever number you want)

then return

and here goes all your registering code

if search page incorrect confirmation code

then

inc #counter

run sub register

Link to post
Share on other sites

I think you use the while function

 

But firstly you have your code for registration,

 

Then, if the captcha is incorrectly input use while lopp with wait for command..

 

The pseudo code is like this

 

1) your command

2) While Wait for "something" , run command again.. This While will looping until you entered the captcha correctly.

 

 

BTW,

 

I look at your bot and it is very badly coded...

 

This is the new code for the User Details section..

It will loop until the captcha is entered correctly..

 

PS: I just code to show you how to loop until the captcha entered correctly.. It will give you the rough idea what you want to do next.

Main Bot.ubot

Link to post
Share on other sites
  • 2 weeks later...

ok, I have found a way of dealing with error messages that so far has worked 100% of the time for me. Instead of choosing by attribute use the following:

 

if=>search page , "error message"

 

then=> run sub xyz

 

The trick is to put the fill form nodes in a sub and the decaptcha nodes in another sub. The if/then goes at the end of the decaptcha sub. As such, if it finds the text, it is instructed to go back to the fill form sub or else continue on to the next sub/script.

 

You can place the ENTIRE script inside a loop for, say, 3 cycles after which it will execute the node outside of the loop.

 

I hope that makes sense, and more importantly, works for you.

 

John

Link to post
Share on other sites
  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...