GerbenJavado / LinkFinder

A python script that finds endpoints in JavaScript files
https://gerbenjavado.com/discovering-hidden-content-using-linkfinder
MIT License
3.61k stars 587 forks source link

DeprecationWarning: ssl.PROTOCOL_TLSv1_2 #122

Closed okondo-afo closed 4 months ago

okondo-afo commented 2 years ago

linkfinder returns this output

/LinkFinder/linkfinder.py:133: DeprecationWarning: ssl.PROTOCOL_TLSv1_2 is deprecated sslcontext = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2) cat: standard output: Bad file descriptor

pro7357 commented 2 years ago

Yeah, ssl.PROTOCOL_TLSv1_2 is deprecated. Referring to https://docs.python.org/3/library/ssl.html#client-side-operation, update those line with: sslcontext = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT) sslcontext.load_verify_locations("/etc/ssl/certs/ca-bundle.crt")

I didn't have that cert. But cert from ncat work fine. I'm using /usr/share/ncat/ca-bundle.crt

abhinavsaraswatt commented 2 years ago

above thing didn't work for me

gprime31 commented 1 year ago

python -W ignore foo.py

Incend1um commented 1 year ago

for MacOS this worked for me sslcontext = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT) sslcontext.load_verify_locations("/usr/local/Cellar/nmap/7.92/share/ncat/ca-bundle.crt")

abhinavsaraswatt commented 1 year ago

python -W ignore foo.py

This works for me!

c4ir0 commented 1 year ago

python -W ignore foo.py

thx, workd fine

Harish-GK commented 1 year ago

guys i am a little beginner here could someone please help me a bit more clear on how to clear this issue LinkFinder/linkfinder.py:133: DeprecationWarning: ssl.PROTOCOL_TLSv1_2 is deprecated sslcontext = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2)

c4ir0 commented 1 year ago

guys i am a little beginner here could someone please help me a bit more clear on how to clear this issue LinkFinder/linkfinder.py:133: DeprecationWarning: ssl.PROTOCOL_TLSv1_2 is deprecated sslcontext = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2)

python -W ignore linkfinder.py

Archurcl4w commented 1 year ago

This issue was fixed by the pull request update for latest #133 . Change the old depreciated function as per this Files changed:- try: sslcontext = ssl.create_default_context() response = urlopen(q, timeout=args.timeout, context=sslcontext) except: sslcontext = ssl.create_default_context() response = urlopen(q, timeout=args.timeout, context=sslcontext)

This issue can close now.

L3V14TH4N commented 1 year ago

This issue was fixed by the pull request update for latest #133 . Change the old depreciated function as per this Files changed:- try: sslcontext = ssl.create_default_context() response = urlopen(q, timeout=args.timeout, context=sslcontext) except: sslcontext = ssl.create_default_context() response = urlopen(q, timeout=args.timeout, context=sslcontext)

This issue can close now.

It worked perfectly here. Thanks!

bugoverfl0w commented 1 year ago

I change urlopen to requests lib then it works well

GerbenJavado commented 4 months ago

Fixed by 1debac5dace4724fd6187c06f133578dae51c86f