From 93900eba18f61119a5ec454b609158df97130ee9 Mon Sep 17 00:00:00 2001 From: Sebastian Wagner Date: Sun, 4 Mar 2018 20:59:17 +0100 Subject: [PATCH 1/4] Add setup.py --- setup.py | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 setup.py diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..b0f8b9d --- /dev/null +++ b/setup.py @@ -0,0 +1,35 @@ +from setuptools import setup, find_packages + +setup( + name='Sublist3r', + version='1.0', + python_requires='>=2.7', + install_requires=['dnspython', 'requests', 'argparse'], + packages=find_packages(), + url='https://github.com/aboul3la/Sublist3r', + license='GPL-2.0', + description='Subdomains enumeration tool for penetration testers', + classifiers=[ + 'Development Status :: 5 - Production/Stable', + 'Environment :: Console', + 'Intended Audience :: Information Technology', + 'Intended Audience :: System Administrators', + 'Intended Audience :: Telecommunications Industry', + 'License :: OSI Approved :: GNU General Public License v2', + 'Operating System :: POSIX :: Linux', + 'Programming Language :: Python', + 'Programming Language :: Python :: 2', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 2.7', + 'Programming Language :: Python :: 3.4', + 'Programming Language :: Python :: 3.5', + 'Programming Language :: Python :: 3.6', + 'Topic :: Security', + ], + keywords='subdomain dns detection', + entry_points={ + 'console_scripts': [ + 'sublist3r = sublist3r:main', + ], + }, +) From eb909d3f6a4a40ca068be21ce47c32a85684b222 Mon Sep 17 00:00:00 2001 From: Sebastian Wagner Date: Sun, 4 Mar 2018 21:06:28 +0100 Subject: [PATCH 2/4] Add manifest to include all data --- MANIFEST.in | 2 ++ setup.py | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 MANIFEST.in diff --git a/MANIFEST.in b/MANIFEST.in new file mode 100644 index 0000000..4b82da3 --- /dev/null +++ b/MANIFEST.in @@ -0,0 +1,2 @@ +include LICENSE README.md +include subbrute/*.txt diff --git a/setup.py b/setup.py index b0f8b9d..5de8c60 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,8 @@ setup( version='1.0', python_requires='>=2.7', install_requires=['dnspython', 'requests', 'argparse'], - packages=find_packages(), + packages=find_packages()+['.'], + include_package_data=True, url='https://github.com/aboul3la/Sublist3r', license='GPL-2.0', description='Subdomains enumeration tool for penetration testers', From 36bd9a2b65551d02bfa442801e294b2e658e3f75 Mon Sep 17 00:00:00 2001 From: Sebastian Wagner Date: Sun, 4 Mar 2018 22:29:35 +0100 Subject: [PATCH 3/4] require argparse only on python2 --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 5de8c60..993dc3e 100644 --- a/setup.py +++ b/setup.py @@ -4,7 +4,7 @@ setup( name='Sublist3r', version='1.0', python_requires='>=2.7', - install_requires=['dnspython', 'requests', 'argparse'], + install_requires=['dnspython', 'requests', 'argparse; python_version==\'2.7\''], packages=find_packages()+['.'], include_package_data=True, url='https://github.com/aboul3la/Sublist3r', From d14546d19a659e9876a469a76c4b9ebe8a55ec99 Mon Sep 17 00:00:00 2001 From: Sebastian Wagner Date: Thu, 12 Apr 2018 21:15:54 +0200 Subject: [PATCH 4/4] Fix function calls in interactive mode --- setup.py | 2 +- sublist3r.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 993dc3e..eb2383c 100644 --- a/setup.py +++ b/setup.py @@ -30,7 +30,7 @@ setup( keywords='subdomain dns detection', entry_points={ 'console_scripts': [ - 'sublist3r = sublist3r:main', + 'sublist3r = sublist3r:interactive', ], }, ) diff --git a/sublist3r.py b/sublist3r.py index 413072c..b33afe2 100755 --- a/sublist3r.py +++ b/sublist3r.py @@ -966,7 +966,7 @@ def main(domain, threads, savefile, ports, silent, verbose, enable_bruteforce, e return subdomains -if __name__ == "__main__": +def interactive(): args = parse_args() domain = args.domain threads = args.threads @@ -979,3 +979,6 @@ if __name__ == "__main__": verbose = True banner() res = main(domain, threads, savefile, ports, silent=False, verbose=verbose, enable_bruteforce=enable_bruteforce, engines=engines) + +if __name__ == "__main__": + interactive()