Import upstream version 1.3.2
Kali Janitor
3 years ago
0 | FROM alpine:edge | |
1 | ||
2 | ||
3 | RUN apk --update add --no-cache python3 py3-requests py3-pip openssl ca-certificates | |
4 | RUN apk --update add --virtual build-dependencies python3-dev build-base wget git \ | |
5 | && git clone https://github.com/maldevel/EmailHarvester.git | |
6 | WORKDIR EmailHarvester | |
7 | ||
8 | #COPY requirements.txt . | |
9 | RUN pip3 install -r requirements.txt | |
10 | ENTRYPOINT ["python3", "EmailHarvester.py"] | |
11 | CMD ["-h"]⏎ |
43 | 43 | from termcolor import colored |
44 | 44 | from argparse import RawTextHelpFormatter |
45 | 45 | from sys import platform as _platform |
46 | try: | |
47 | from urllib.parse import urlparse | |
48 | except ImportError: | |
49 | from urlparse import urlparse | |
46 | from urllib.parse import urlparse | |
50 | 47 | |
51 | 48 | ################################ |
52 | 49 | |
96 | 93 | self.userAgent = userAgent |
97 | 94 | self.parser = myparser() |
98 | 95 | self.activeEngine = "None" |
99 | path = os.path.dirname(os.path.abspath(__file__)) + "/plugins/" | |
96 | path = "plugins/" | |
100 | 97 | plugins = {} |
101 | 98 | |
102 | 99 | sys.path.insert(0, path) |
103 | 100 | for f in os.listdir(path): |
104 | 101 | fname, ext = os.path.splitext(f) |
105 | 102 | if ext == '.py': |
106 | mod = __import__(fname, fromlist=['']) | |
103 | mod = __import__(fname) | |
107 | 104 | plugins[fname] = mod.Plugin(self, {'useragent':userAgent, 'proxy':proxy}) |
108 | 105 | |
109 | 106 | def register_plugin(self, search_method, functions): |
138 | 135 | except Exception as e: |
139 | 136 | print(e) |
140 | 137 | sys.exit(4) |
141 | ||
142 | if r.encoding is None: | |
143 | r.encoding = 'UTF-8' | |
144 | ||
138 | ||
145 | 139 | self.results = r.content.decode(r.encoding) |
146 | 140 | self.totalresults += self.results |
147 | 141 |
0 | Hey maldevel, | |
1 | ||
2 | I am a total noob and really can't get EmailHarvester to work. | |
3 | Is there any possibility of you doing a noob guide? | |
4 | Or of answering a few questions for me? | |
5 | ||
6 | You can shoot me an email if that's easier. [email protected] | |
7 | ||
8 | Thanks man! |
30 | 30 | Download/Installation |
31 | 31 | ==== |
32 | 32 | * git clone https://github.com/maldevel/EmailHarvester |
33 | * pip install -r requirements.txt | |
33 | * pip install -r requirements.txt --user | |
34 | 34 | |
35 | 35 | |
36 | 36 | Usage |
97 | 97 | |
98 | 98 | **Proxy Server** |
99 | 99 | * ./EmailHarvester.py -d example.com -e all -x http://127.0.0.1:8080 |
100 | ||
101 | Docker | |
102 | ===== | |
103 | Alpine based Dockerfile | |
104 | ```bash | |
105 | git clone https://github.com/maldevel/EmailHarvester | |
106 | cd EmailHarvester | |
107 | docker build -t EmailHarvester . | |
108 | docker run -it EmailHarvester -d example.com | |
109 | ```⏎ |
0 | """ | |
1 | This file is part of EmailHarvester | |
2 | Copyright (C) 2016 @maldevel | |
3 | https://github.com/maldevel/EmailHarvester | |
4 | ||
5 | EmailHarvester - A tool to retrieve Domain email addresses from Search Engines. | |
6 | ||
7 | This program is free software: you can redistribute it and/or modify | |
8 | it under the terms of the GNU General Public License as published by | |
9 | the Free Software Foundation, either version 3 of the License, or | |
10 | (at your option) any later version. | |
11 | ||
12 | This program is distributed in the hope that it will be useful, | |
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | GNU General Public License for more details. | |
16 | ||
17 | You should have received a copy of the GNU General Public License | |
18 | along with this program. If not, see <http://www.gnu.org/licenses/>. | |
19 | ||
20 | For more see the file 'LICENSE' for copying permission. | |
21 | """ | |
22 | ||
23 | #config = None | |
24 | app_emailharvester = None | |
25 | ||
26 | ||
27 | def search(domain, limit): | |
28 | url = 'https://www.google.com/search?num=100&start={counter}&hl=en&q="%40{word}"' | |
29 | app_emailharvester.init_search(url, domain, limit, 0, 100, 'Google') | |
30 | app_emailharvester.process() | |
31 | return app_emailharvester.get_emails() | |
32 | ||
33 | ||
34 | class Plugin: | |
35 | def __init__(self, app, conf):# | |
36 | global app_emailharvester, config | |
37 | #config = conf | |
38 | app.register_plugin('google', {'search': search}) | |
39 | app_emailharvester = app | |
40 | ⏎ |
0 | """ | |
1 | This file is part of EmailHarvester | |
2 | Copyright (C) 2016 @maldevel | |
3 | https://github.com/maldevel/EmailHarvester | |
4 | ||
5 | EmailHarvester - A tool to retrieve Domain email addresses from Search Engines. | |
6 | ||
7 | This program is free software: you can redistribute it and/or modify | |
8 | it under the terms of the GNU General Public License as published by | |
9 | the Free Software Foundation, either version 3 of the License, or | |
10 | (at your option) any later version. | |
11 | ||
12 | This program is distributed in the hope that it will be useful, | |
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | GNU General Public License for more details. | |
16 | ||
17 | You should have received a copy of the GNU General Public License | |
18 | along with this program. If not, see <http://www.gnu.org/licenses/>. | |
19 | ||
20 | For more see the file 'LICENSE' for copying permission. | |
21 | """ | |
22 | ||
23 | #config = None | |
24 | app_emailharvester = None | |
25 | ||
26 | ||
27 | def search(domain, limit): | |
28 | url = 'https://www.google.com/search?num=100&start={counter}&hl=en&q="%40{word}"' | |
29 | app_emailharvester.init_search(url, domain, limit, 0, 100, 'Google') | |
30 | app_emailharvester.process() | |
31 | return app_emailharvester.get_emails() | |
32 | ||
33 | ||
34 | class Plugin: | |
35 | def __init__(self, app, conf):# | |
36 | global app_emailharvester, config | |
37 | #config = conf | |
38 | app.register_plugin('googles', {'search': search}) | |
39 | app_emailharvester = app | |
40 |