Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recaptcha solver #480

Closed
1 of 4 tasks
furjac opened this issue Dec 1, 2022 · 32 comments
Closed
1 of 4 tasks

Recaptcha solver #480

furjac opened this issue Dec 1, 2022 · 32 comments

Comments

@furjac
Copy link

furjac commented Dec 1, 2022

Is there an existing issue for this?

  • I have searched the existing issues

I'm submitting a ...

Description

bro this code does not go forward in recaptcha so here is the idea of a recapthca solver try it out bro

r = sr.Recognizer()
try:
            delay()
            frames = driver.find_elements_by_tag_name("iframe")
            recaptcha_control_frame = None
            recaptcha_challenge_frame = None
            for index, frame in enumerate(frames):
                if re.search('reCAPTCHA', frame.get_attribute("title")):
                    recaptcha_control_frame = frame

                if re.search('recaptcha challenge', frame.get_attribute("title")):
                    recaptcha_challenge_frame = frame
            if not (recaptcha_control_frame and recaptcha_challenge_frame):
                print("[ERR] Unable to find recaptcha. Abort solver.")

            delay()
            frames = driver.find_elements_by_tag_name("iframe")
            driver.switch_to.frame(recaptcha_control_frame)
            driver.find_element_by_class_name(
                "recaptcha-checkbox-border").click()

            delay()
            driver.switch_to.default_content()
            frames = driver.find_elements_by_tag_name("iframe")
            driver.switch_to.frame(recaptcha_challenge_frame)

            time.sleep(10)
            driver.find_element_by_id("recaptcha-audio-button").click()

            try:
                driver.switch_to.default_content()
                frames = driver.find_elements_by_tag_name("iframe")
                driver.switch_to.frame(recaptcha_challenge_frame)

                delay()
                src = driver.find_element_by_id(
                    "audio-source").get_attribute("src")

                path_to_mp3 = os.path.normpath(
                    os.path.join(os.getcwd(), "sample.mp3"))
                path_to_wav = os.path.normpath(
                    os.path.join(os.getcwd(), "sample.wav"))

                urllib.request.urlretrieve(src, path_to_mp3)
            except:
                driver.quit()
                # os.system("check.exe")

            try:
                sound = pydub.AudioSegment.from_mp3(path_to_mp3)
                sound.export(path_to_wav, format="wav")
                sample_audio = sr.AudioFile(path_to_wav)
            except Exception:
                driver.close()
                driver.quit()

            delay()
            r = sr.Recognizer()
            with sample_audio as source:
                audio = r.record(source)
            key = r.recognize_google(audio)

            delay()
            driver.find_element_by_id("audio-response").send_keys(key.lower())
            driver.find_element_by_id("audio-response").send_keys(Keys.ENTER)
        except:
            driver.quit()

Environment

- OS : windows 
- Python : 3.9
- Script version : 1.6.7

config.json

{
    "http_api": {
        "enabled": true,
        "host": "0.0.0.0",
        "port": 5000
    },
    "database": true,
    "views": 100,
    "minimum": 85.0,
    "maximum": 95.0,
    "proxy": {
        "category": "f",
        "proxy_type": false,
        "filename": false,
        "authentication": false,
        "proxy_api": false,
        "refresh": 0.0
    },
    "background": false,
    "bandwidth": true,
    "playback_speed": 1,
    "max_threads": 5,
    "min_threads": 2
}
@furjac
Copy link
Author

furjac commented Dec 1, 2022

btw sr is speech recognition

@furjac
Copy link
Author

furjac commented Dec 1, 2022

and a new idea if we play a random video for one second and paste our link and see the video it is counted in analytics as suggested views this is my idea is there a way to add it in your code like creating referal.txt and random-link.txt use random-link as random video and referal.txt as suggested video thanks

@JijaProGamer
Copy link

second and paste our link and see the video it is counted in analytics as suggested views

You have to play a video for at least 30 seconds for youtube to count it as a view, and this should be a pull request

@furjac
Copy link
Author

furjac commented Dec 1, 2022

second and paste our link and see the video it is counted in analytics as suggested views

You have to play a video for at least 30 seconds for youtube to count it as a view, and this should be a pull request

no not like that play a random video for one second and play my video fully

@JijaProGamer
Copy link

Your video would have to be on the reccomended page on the other guy's video, or else the view would count as a direct view (I am writing an alternative of this, and I know some stuff about the youtube algorithm)

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Your video would have to be on the reccomended page on the other guy's video, or else the view would count as a direct view (I am writing an alternative of this, and I know some stuff about the youtube algorithm)

means it will not work like that

@JijaProGamer
Copy link

Exactly, it won't work like that. Also, when do you receive recapchas on youtube? I know google has no recapchas and youtube has no recapchas either

@furjac
Copy link
Author

furjac commented Dec 1, 2022

i recieve capthca when using free proxies

@JijaProGamer
Copy link

JijaProGamer commented Dec 1, 2022

Free proxies don't count as real views anyways, most views will disappear after a few days/weeks

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Free proxies don't count as real views anyways, most views will disappear after a few days/weeks

yes man ur right
and this captcha solver is veryy helpful for gplnks and ad shorten projects

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Exactly, it won't work like that. Also, when do you receive recapchas on youtube? I know google has no recapchas and youtube has no recapchas

bro then is there a wayy to get views as suggested videos views bcoz the paid bot sites like krutube.ru brings like that
how is it possible

@JijaProGamer
Copy link

Suggested videos views are from the recommended page and from the video page in the right, not sure about this view bot but you would have to go to a video similar of yours, scrape the right of the page and check if the video you want to bot is there and if not try to go to another similar video, and repeat this process until you find your video

@furjac
Copy link
Author

furjac commented Dec 1, 2022

bro how does the smm panels work any idea

@MShawon
Copy link
Owner

MShawon commented Dec 1, 2022

Free proxies won't do any good.. it's just there to get people started to see how this works... This captcha thing only appears in free proxies..

Opening someone's video for a second or something is not the right thing to do. You shouldn't open someone's video in a view bot without their consent.

https://github.com/MShawon/YouTube-Viewer#traffic-sources as mentioned there you already get suggested views from this bot... Just use multiple videos to get suggested views from those videos

@MShawon MShawon closed this as completed Dec 1, 2022
@furjac
Copy link
Author

furjac commented Dec 1, 2022

Bro but suggested views not coming showing YouTube Searcy views

@JijaProGamer
Copy link

How many videos did you put in? If you don't have enough its going to show as search instead of suggested

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Only 3

@JijaProGamer
Copy link

Yeah, thats clearly not enough

@furjac
Copy link
Author

furjac commented Dec 1, 2022

How much is minimum

@MShawon
Copy link
Owner

MShawon commented Dec 1, 2022

Put all of your video links in the urls.txt

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Bro a doubt what happens if we run a bot on random video without there consent as u said 🙄 is there any issue

@JijaProGamer
Copy link

They're watch time will be destroyed?

@furjac
Copy link
Author

furjac commented Dec 1, 2022

They're watch time will be destroyed?

Means they can report us

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Jija pro gamer a last question give me answer plz
How to create a referral.txt which opens a video for second and play my video using this YouTube viewer any way to add this function pls give me full answer man

@JijaProGamer
Copy link

Im sorry, I don't know really know python really well so I cannot work this out. I have a nodejs API in which you can create a view bot in less than 15 lines of code, however you must be good at nodejs for it. If you want to modify this library, I would start by finding the code that handles viewing the page, and when a view ends check all the reccommended videos and if any one matches another video on the watch list click on it and repeat the process.

@furjac
Copy link
Author

furjac commented Dec 1, 2022

No I don't know nodejs sorry 😐 Mshawon @MShawon reply the above question of mine please

@JijaProGamer
Copy link

In https://github.com/MShawon/YouTube-Viewer/blob/master/youtube_viewer.py at main_viewer I think channel_or_endscreen is called when the video ends or is close to ending? If thats the case, then you should change channel_or_endscreen() with your own code (I don't know python so this may be false)

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Wait let me check

@furjac
Copy link
Author

furjac commented Dec 1, 2022

No man I can't understand the working of code

@furjac
Copy link
Author

furjac commented Dec 1, 2022

He used everything from basics.py man
I don't know working of modules

@JijaProGamer
Copy link

Well, the only things you can do is MSawon explain everything for you (Probably won't happen), you create your own module from scratch, learn nodejs, or try to understand what everything does

@furjac
Copy link
Author

furjac commented Dec 1, 2022

Yes I'm gonna learn everything what does thus script do

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants