Python3 library for scraping http/https and socks(4/5) proxies.
Project description
ProxyNinja-ng
Python3 Module to get https or socks(4/5) proxies by scraping the web.
🔧 Technologies & Tools
📚 Requirements
- Python 3.9+
- pip3
Installation
Use the package manager pip to install the module. if not installed, install it using the following command.
sudo apt-get install python3-pip
It is advised to install the python requirements in a virtual environment, for that install the venv package.
python3 -m pip install venv
python3 -m venv env
source env/bin/activate
After that run the following commands:
python3 -m pip install <pkg> -U
OR
git clone https://github.com/sc4rfurry/ProxyNinja-ng-PyPi.git
cd ProxyNinja-ng-PyPi
python3 -m pip install .
Usage/Examples
Usage:
==> Download the proxies
#!/usr/bin/python3
from proxy_ninja import fetch_proxies
fetch_proxies(PROXY_TYPE, OUTPUT_FILENAME, OUTPUT_FORMAT)
- PROXY_TYPE: https/socks4/socks5
- OUTPUT_FILENAME: Enter the filename
- OUTPUT_FORMAT: txt/json
proxies gonna save in parent dir.
Example:
#!/usr/bin/python3
from proxy_ninja_ng import fetch_proxies
fetch_proxies("socks", "socks_proxy", "json")
==> Get proxies as json
#!/usr/bin/python3
from proxy_ninja_ng import fetch_proxies_json
json_list = fetch_proxies_json(PROXY_TYPE)
print(json_list)
- PROXY_TYPE: https/socks4/socks5
This will gonna return a json list.
Example:
#!/usr/bin/python3
from proxy_ninja_ng import fetch_proxies_json
json_list = fetch_proxies_json("https")
print(json_list)
==> Get proxies List
#!/usr/bin/python3
from proxy_ninja_ng import fetch_proxies_list
_list = fetch_proxies_list(PROXY_TYPE)
print(_list)
- PROXY_TYPE: https/socks4/socks5
This will gonna return a list.
Example:
#!/usr/bin/python3
from proxy_ninja_ng import fetch_proxies_list
lst = fetch_proxies_list("https")
print(lst)
Features
- Fetch proxies from different url's and api's.
- Fast, using request lib.
- save output in txt or json format.
- User Friendly. :D
Note: If you are interested in implementing this using Selenium/ChromiumDriver, please check this Project
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
License
Feedback
If you have any feedback, please reach out to us at akalucifr@protonmail.ch
Change Log
0.1.0 (24/8/2022)
- initial release
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file proxy-ninja-ng-0.1.0.tar.gz
.
File metadata
- Download URL: proxy-ninja-ng-0.1.0.tar.gz
- Upload date:
- Size: 4.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 062c98650ab4bf4bdfe561f0e454601b5644d1a7fb78258c91087815b8a6cc7e |
|
MD5 | d2159ec141c04ad02161aa52ce14daa2 |
|
BLAKE2b-256 | f1d1e3593f65caf10a5ca3a7aaf026a607a851418e0b32459a9a0371bbb85f1d |
File details
Details for the file proxy_ninja_ng-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: proxy_ninja_ng-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8494deafeccb7ecc7999633f0f816e97472e14ae74a3a6d48fd45540e563b004 |
|
MD5 | 5f4a8cd269f34320e872c2893cf9b639 |
|
BLAKE2b-256 | c20af176064159d4af4ea0a8222bb3c6fb9a5d11258f2dc1903f1fb47516112a |