-
-
Notifications
You must be signed in to change notification settings - Fork 546
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
TorBot Stable Version1.2 #56
Merged
Changes from 84 commits
Commits
Show all changes
85 commits
Select commit
Hold shift + click to select a range
fa12a72
Merge pull request #35 from DedSecInside/master
PSNAppz 6fdb04f
Update README.md
PSNAppz 219fd49
configuration
PSNAppz 773f0d9
ReadMe
PSNAppz 6c8484e
ReadMe
PSNAppz b1b77e5
Merge branch 'info_feature_v0.0.1' of https://github.com/dedsecinside…
PSNAppz 449692d
Fixing import
PSNAppz a9c6771
Fixing import
PSNAppz 988cce3
Fixing Travis
PSNAppz e2aceca
Merge pull request #36 from DedSecInside/info_feature_v0.0.1
PSNAppz 3bd9b01
Fixed requirements.txt by adding missing "="
KingAkeem 695128e
Merge pull request #41 from KingAkeem/dev
PSNAppz 56c45ae
fixed the error occurring when given a broken link with -u flag
8d8286f
Merge pull request #42 from Agostinelli/dev
PSNAppz f88f5af
PEP8 code and fixed some minor bugs
KingAkeem 9c972be
Pep8 code and fixed tests
KingAkeem f5555e0
Adding Contributors
PSNAppz 29b9334
Merge pull request #45 from DedSecInside/torBot_contributors
PSNAppz 65415da
Merge pull request #44 from KingAkeem/dev
PSNAppz 0889945
Update CODE_OF_CONDUCT.md
PSNAppz 19d4112
Merge pull request #1 from DedSecInside/dev
KingAkeem a812592
Refactored code for connection to socket
KingAkeem 74d6e42
Used regex to validate urls more thoroughly
KingAkeem 4301fe2
Added validator to getweblinks and fixed tests
KingAkeem cc8c068
Updated README.md
KingAkeem 601662b
Updated README.md
KingAkeem e2da315
Added documentation and refactored funcitons
KingAkeem b26eafc
Fixed savefile module for -s flag
KingAkeem 94e0154
Fixed small errors
KingAkeem 9701706
Fixed failing test
KingAkeem 6870714
Merge pull request #46 from KingAkeem/dev
PSNAppz 486423d
Removed samples
PSNAppz a7f963a
Merge pull request #2 from DedSecInside/dev
KingAkeem fe8b0a5
Changed testing framework from unittest to pytest
KingAkeem a9a100c
Merge branch 'dev' of https://github.com/KingAkeem/torBot into dev
KingAkeem e591b18
Merge pull request #50 from KingAkeem/dev
PSNAppz aed46cd
Fixed savetofile test
KingAkeem 26bf850
Merge pull request #51 from KingAkeem/dev
PSNAppz ff56134
Update README.md
mamarto f97fb19
Update CHANGELOG.md
mamarto a8fe5c3
Update README.md
mamarto 9382afe
Merge pull request #1 from Agostinelli/patch-1
mamarto d4da8fe
Merge pull request #52 from Agostinelli/dev
PSNAppz 032d31e
Merge pull request #3 from DedSecInside/dev
KingAkeem 50832cd
Tried to make flags more understandable
KingAkeem be5816e
Fixed markdown error with Note under flags
KingAkeem 55342c6
Merge pull request #53 from KingAkeem/dev
PSNAppz 3b3aede
Merge pull request #4 from DedSecInside/dev
KingAkeem 696352d
Changed badges on README.md to be more consistent
mossbanay 2dec998
Merge pull request #54 from leaen/dev
PSNAppz c59d4a0
Merge pull request #5 from DedSecInside/dev
KingAkeem f7fe163
Updated dependencies and todo list
KingAkeem 557ebcc
Fixed small error with todo list
KingAkeem 241e11b
I need coffee, another small fix
KingAkeem 80a17ef
Resolving Conflicts
PSNAppz 629cae8
Merge branch 'dev' of https://github.com/dedsecinside/torbot into dev
PSNAppz 4a0073f
Minor fixes
PSNAppz 4d9e91d
Fixed out-or-range err in getemails module (Issue #59)
d896e67
Merge pull request #60 from waisuan/dev
PSNAppz 0a010d1
Added contributor (#63)
PSNAppz d2f9ef8
Fixed `-l` flag for finding live links.
KingAkeem b53b189
Merge branch 'dev' of https://github.com/KingAkeem/torBot into dev
KingAkeem 3b1ca88
Fixed failing test
KingAkeem c934ae1
Updated dependencies and todo list
KingAkeem 9512fff
Fixed small error with todo list
KingAkeem 0bdfae0
I need coffee, another small fix
KingAkeem 1aee370
Fixed `-l` flag for finding live links.
KingAkeem a95b614
Fixed failing test
KingAkeem 3e852c8
Merge branch 'dev' of https://github.com/KingAkeem/torBot into dev
KingAkeem b528884
Fixed error with 200 status code
KingAkeem 980d661
Getting rid of redundancy
KingAkeem b0e8340
Fixed -e flag
KingAkeem e640e7a
No longer restricted to using .onion domains only
KingAkeem 9bf390a
Fixed typo
KingAkeem 2f0a890
Only returns .onion links without -e flag
KingAkeem ad36826
Fixed getweblinks test
KingAkeem 2213527
Update README.md
PSNAppz 3826a3e
Updating dependencies
PSNAppz 9b283ac
Merge branch 'dev' into dev
PSNAppz 8928e46
Searches for all DN passed using -e flag
KingAkeem c78df06
Merge branch 'dev' of https://github.com/KingAkeem/torBot into dev
KingAkeem b363205
Merge pull request #66 from KingAkeem/dev
PSNAppz e886ae4
Travis Update & Minor fixes
PSNAppz 3627fb8
Fixed tests
PSNAppz 0311b39
Fixes
PSNAppz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,9 @@ | ||
modules/__pycache__/ | ||
.cache | ||
.*.swp | ||
.ropeproject/ | ||
modules/.ropeproject/ | ||
tests/__pycache__/ | ||
modules/__init__.py | ||
.idea/ | ||
tests/.ropeproject/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,54 @@ | ||
<pre> | ||
|
||
|
||
████████╗ ██████╗ ██████╗ ██████╗ ██████╗ ████████╗ | ||
╚══██╔══╝██╔═══██╗██╔══██╗ ██╔══██╗██╔═████╗╚══██╔══╝ | ||
██║ ██║ ██║██████╔╝ ██████╔╝██║██╔██║ ██║ | ||
██║ ██║ ██║██╔══██╗ ██╔══██╗████╔╝██║ ██║ | ||
██║ ╚██████╔╝██║ ██║ ██████╔╝╚██████╔╝ ██║ | ||
╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ | ||
████████╗ ██████╗ ██████╗ ██████╗ ██████╗ ████████╗ | ||
╚══██╔══╝██╔═══██╗██╔══██╗ ██╔══██╗██╔═████╗╚══██╔══╝ | ||
██║ ██║ ██║██████╔╝ ██████╔╝██║██╔██║ ██║ | ||
██║ ██║ ██║██╔══██╗ ██╔══██╗████╔╝██║ ██║ | ||
██║ ╚██████╔╝██║ ██║ ██████╔╝╚██████╔╝ ██║ | ||
╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ | ||
|
||
|
||
|
||
`.` ` | ||
``.:.--.` | ||
.-+++/-` | ||
`+sso:` | ||
`` /yy+. | ||
-+.oho. | ||
o../+y | ||
-s.-/:y:` | ||
.:o+-`--::oo/-` | ||
`/o+:.```---///oss+- | ||
.+o:.``...`-::-+++++sys- | ||
:y/```....``--::-yooooosh+ | ||
-h-``--.```..-:-::ssssssssd+ | ||
h:``:.``....`--:-++hsssyyyym. | ||
.d.`/.``--.```:--//odyyyyyyym/ | ||
`d.`+``:.```.--/-+/smyyhhhhhm: | ||
os`./`/````/`-/:+oydhhhhhhdh` | ||
`so.-/-:``./`.//osmddddddmd. | ||
/s/-/:/.`/..+/ydmdddddmo` | ||
`:oosso/:+/syNmddmdy/. | ||
`-/++oosyso+/.` | ||
|
||
|
||
██████╗ ███████╗██████╗ ███████╗██████╗ ██████╗ ██╗███╗ ██╗███████╗██╗██████╗ ███████╗ | ||
██╔══██╗██╔════╝██╔══██╗██╔════╝╚════██╗██╔════╝ ██║████╗ ██║██╔════╝██║██╔══██╗██╔════╝ | ||
██║ ██║█████╗ ██║ ██║███████╗ █████╔╝██║ ██║██╔██╗ ██║███████╗██║██║ ██║█████╗ | ||
██║ ██║██╔══╝ ██║ ██║╚════██║ ╚═══██╗██║ ██║██║╚██╗██║╚════██║██║██║ ██║██╔══╝ | ||
██████╔╝███████╗██████╔╝███████║██████╔╝╚██████╗ ██║██║ ╚████║███████║██║██████╔╝███████╗ | ||
╚═════╝ ╚══════╝╚═════╝ ╚══════╝╚═════╝ ╚═════╝ ╚═╝╚═╝ ╚═══╝╚══════╝╚═╝╚═════╝ ╚══════╝ | ||
`.` ` | ||
``.:.--.` | ||
.-+++/-` | ||
`+sso:` | ||
`` /yy+. | ||
-+.oho. | ||
o../+y | ||
-s.-/:y:` | ||
.:o+-`--::oo/-` | ||
`/o+:.```---///oss+- | ||
.+o:.``...`-::-+++++sys- | ||
:y/```....``--::-yooooosh+ | ||
-h-``--.```..-:-::ssssssssd+ | ||
h:``:.``....`--:-++hsssyyyym. | ||
.d.`/.``--.```:--//odyyyyyyym/ | ||
`d.`+``:.```.--/-+/smyyhhhhhm: | ||
os`./`/````/`-/:+oydhhhhhhdh` | ||
`so.-/-:``./`.//osmddddddmd. | ||
/s/-/:/.`/..+/ydmdddddmo` | ||
`:oosso/:+/syNmddmdy/. | ||
`-/++oosyso+/.` | ||
██████╗ ███████╗██████╗ ███████╗██████╗ ██████╗ ██╗███╗ ██╗███████╗██╗██████╗ ███████╗ | ||
██╔══██╗██╔════╝██╔══██╗██╔════╝╚════██╗██╔════╝ ██║████╗ ██║██╔════╝██║██╔══██╗██╔════╝ | ||
██║ ██║█████╗ ██║ ██║███████╗ █████╔╝██║ ██║██╔██╗ ██║███████╗██║██║ ██║█████╗ | ||
██║ ██║██╔══╝ ██║ ██║╚════██║ ╚═══██╗██║ ██║██║╚██╗██║╚════██║██║██║ ██║██╔══╝ | ||
██████╔╝███████╗██████╔╝███████║██████╔╝╚██████╗ ██║██║ ╚████║███████║██║██████╔╝███████╗ | ||
╚═════╝ ╚══════╝╚═════╝ ╚══════╝╚═════╝ ╚═════╝ ╚═╝╚═╝ ╚═══╝╚══════╝╚═╝╚═════╝ ╚══════╝ | ||
|
||
|
||
|
||
</pre> | ||
|
||
## A python web crawler for Deep and Dark Web. | ||
[![Build Status](https://travis-ci.org/DedSecInside/TorBoT.svg?branch=master)](https://travis-ci.org/DedSecInside/TorBoT) | ||
[![](https://img.shields.io/badge/Donate-Bitcoin-blue.svg?style=flat-square)](https://blockchain.info/address/14st7SzDbQZuu8fpQ74x477WoRJ7gpHFaj) | ||
[![forthebadge](http://forthebadge.com/images/badges/built-with-love.svg)](http://forthebadge.com) | ||
[![forthebadge](http://forthebadge.com/images/badges/made-with-python.svg)](http://forthebadge.com) | ||
[![](https://img.shields.io/badge/Donate-Bitcoin-blue.svg?style=flat)](https://blockchain.info/address/14st7SzDbQZuu8fpQ74x477WoRJ7gpHFaj) | ||
[![](https://img.shields.io/badge/Built%20with-❤-orange.svg?style=flat)]() | ||
[![](https://img.shields.io/badge/Made%20with-Python-red.svg?style=flat)]() | ||
|
||
|
||
### Working Procedure/Basic Plan | ||
|
@@ -65,62 +65,69 @@ the following steps: | |
8. After all URLs are processed, return the most relevant page. | ||
|
||
### Features | ||
1. Crawls Tor links (.onion) only. | ||
2. Returns Page title and address. | ||
3. Cache links so that there won't be duplicate links. | ||
1. Crawls Tor links (.onion).(Completed) | ||
2. Returns Page title and address with a short description about the site.(Not Started) | ||
3. Save links to database.(Not Started) | ||
4. Get emails from site.(Completed) | ||
5. Save crawl info to JSON file.(Completed) | ||
6. Crawl custom domains.(Completed) | ||
7. Check if the link is live.(Not Started) | ||
4. Built-in Updater.(Completed) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Built-in Updater should be number 8 instead of 4. |
||
...(will be updated) | ||
|
||
## Contribute | ||
Contributions to this project are always welcome. | ||
To add a new feature fork this repository and give a pull request when your new feature is tested and complete. | ||
To add a new feature fork the dev branch and give a pull request when your new feature is tested and complete. | ||
If its a new module, it should be put inside the modules directory and imported to the main file. | ||
The branch name should be your new feature name in the format <Feature_featurename_version(optional)>. For example, <i>Feature_FasterCrawl_1.0</i>. | ||
Contributor name will be updated to the below list. :D | ||
|
||
## Dependencies | ||
1. Tor | ||
2. Python 3.x (Make sure pip3 is there) | ||
3. Python Stem Module | ||
4. urllib | ||
5. Beautiful Soup 4 | ||
6. Socket | ||
7. Sock | ||
8. Argparse | ||
9. Stem module | ||
10. Git | ||
2. Python 3.x (Make sure pip3 is installed) | ||
3. requests | ||
4. Beautiful Soup 4 | ||
5. Socket | ||
6. Sock | ||
7. Argparse | ||
8. Git | ||
9. termcolor | ||
10. tldextract | ||
|
||
## Basic setup | ||
Before you run the torBot make sure the following things are done properly: | ||
|
||
* Run tor service | ||
`sudo service tor start` | ||
|
||
* Set a password for tor | ||
`tor --hash-password "my_password" ` | ||
|
||
* Give the password inside torbot.py | ||
`from stem.control import Controller | ||
with Controller.from_port(port = 9051) as controller: | ||
controller.authenticate("your_password_hash") | ||
controller.signal(Signal.NEWNYM)` | ||
* Make sure that your torrc is configured to SOCKS_PORT localhost:9050 | ||
|
||
`python3 torBot.py` | ||
`usage: torBot.py [-h] [-q] [-u URL] [-m] [-e EXTENSION] [-l] | ||
`python3 torBot.py or use the -h/--help argument` | ||
<pre> | ||
`usage: torBot.py [-h] [-v] [--update] [-q] [-u URL] [-s] [-m] [-e EXTENSION] | ||
[-l] [-i] | ||
|
||
optional arguments: | ||
-h, --help show this help message and exit | ||
-q, --quiet | ||
-u URL, --url URL Specifiy a website link to crawl | ||
-h, --help Show this help message and exit | ||
-v, --version Show current version of TorBot. | ||
--update Update TorBot to the latest stable version | ||
-q, --quiet Prevent header from displaying | ||
-u URL, --url URL Specifiy a website link to crawl, currently returns links on that page | ||
-s, --save Save results to a file in json format | ||
-m, --mail Get e-mail addresses from the crawled sites | ||
-e EXTENSION, --extension EXTENSION | ||
Specifiy additional website extensions to the | ||
list(.com or .org etc) | ||
-l, --live Check if websites are live or not (slow)` | ||
-l, --live Check if websites are live or not (slow) | ||
-i, --info Info displays basic info of the scanned site (very | ||
slow)` </pre> | ||
|
||
* NOTE: All flags under -u URL, --url URL must also be passed a -u flag. | ||
|
||
Read more about torrc here : [Torrc](https://github.com/DedSecInside/TorBoT/blob/master/Tor.md) | ||
|
||
## TO-DO | ||
A TO-DO list will be added here as soon as its complete. | ||
- [ ] Implement A\* Search for webcrawler | ||
|
||
### Have ideas? | ||
If you have new ideas which is worth implementing, mention those by starting a new issue with the title [FEATURE_REQUEST]. | ||
|
@@ -133,7 +140,11 @@ GNU Public License | |
|
||
- [X] [P5N4PPZ](https://github.com/PSNAppz) - Owner | ||
- [X] [agrepravin](https://github.com/agrepravin) - Contributor,Reviewer | ||
- [X] [y-mehta](https://github.com/y-mehta) - Contributer | ||
- [X] [y-mehta](https://github.com/y-mehta) - Contributor | ||
- [X] [Manfredi Martorana](https://github.com/Agostinelli) - Contributor | ||
- [X] [KingAkeem](https://github.com/KingAkeem) - Contributor | ||
- [X] [Evan Sia Wai Suan](https://github.com/waisuan) - New Contributor | ||
|
||
|
||
![](https://upload.wikimedia.org/wikipedia/commons/thumb/4/42/Opensource.svg/200px-Opensource.svg.png) | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,14 @@ | ||
__all__ = ['Bcolors'] | ||
|
||
|
||
class Bcolors: | ||
HEADER = '\033[95m' | ||
OKBLUE = '\033[94m' | ||
OKGREEN = '\033[92m' | ||
WARNING = '\033[93m' | ||
FAIL = '\033[91m' | ||
ENDC = '\033[0m' | ||
BOLD = '\033[1m' | ||
UNDERLINE = '\033[4m' | ||
WHITE = '\033[97m' | ||
On_Black = '\033[40m' | ||
On_Red = '\033[41m' | ||
|
||
|
||
def __init__(self): | ||
self.HEADER = '\033[95m' | ||
self.OKBLUE = '\033[94m' | ||
self.OKGREEN = '\033[92m' | ||
self.WARNING = '\033[93m' | ||
self.FAIL = '\033[91m' | ||
self.ENDC = '\033[0m' | ||
self.BOLD = '\033[1m' | ||
self.UNDERLINE = '\033[4m' | ||
self.WHITE = '\033[97m' | ||
self.On_Black = '\033[40m' | ||
self.On_Red = '\033[41m' |
Binary file not shown.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since we are using pytest, whenever you go into the test suite. You only need to run
pytest
to run all of the tests.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed