Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ before_script:
script:
- python photon.py -u "https://somdev.me" -l 1 -d 1 -t 100 --regex "\d{10}" --dns --output="d3v"
- python photon.py -u "https://somdev.me" -l 1 -t 10 --seeds="https://somdev.me/posts" --only-urls --export=json --wayback
- python photon.py -u email1.tesla.com
- python photon.py -u asdasd.asd
- python photon.py -u somdev.me
9 changes: 7 additions & 2 deletions photon.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,13 @@
try:
requests.get('https://' + main_inp, proxies=random.choice(proxies))
main_url = 'https://' + main_inp
except:
main_url = 'http://' + main_inp
except requests.ConnectionError:
try:
requests.get('http://' + main_inp, proxies=random.choice(proxies))
main_url = 'http://' + main_inp
except requests.ConnectionError:
sys.stdout.write("Host not found.\n")
sys.exit(0)

schema = main_url.split('//')[0] # https: or http:?
# Adding the root URL to internal for crawling
Expand Down