Security News
Maven Central Adds Sigstore Signature Validation
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
Manages proxies for http or selenium and some common uses cases like random,cycle, or set env/sys proxy.
cd_proxy_manager
is a Python package designed to handle proxy configurations and management for various purposes such as setting environment proxies, formatting proxies, and dealing with proxies in HTTP requests and browsers.
To install cd_proxy_manager
, clone the repository and install the required dependencies:
git clone <repository-url>
cd cd_proxy_manager
pip install -r requirements.txt
or
pip install cd-proxy-manager
__init__.py
This file initializes the package.
browser_judges.py
This module includes various browser judge urls.
format_proxy.py
This module provides functionality for formatting proxies in various formats, making them suitable for use with different libraries and tools.
http_judges.py
This module includes various HTTP judge urls.
proxy_dealer.py
This module is designed to manage and deal with multiple proxies, possibly including rotation and validation.
set_env_proxy.py
This module provides a function to set an environment variable for a proxy, supporting both simple and authenticated proxies.
set_global_proxy.py
This module includes functionality to set a global proxy configuration for the system.
version.py
This module defines the version of the cd_proxy_manager
package.
examples/
This directory contains example scripts demonstrating how to use the various functionalities provided by the package.
To format a proxy, see example in the examples folder.
To set an environment proxy, use the set_env_proxy.py
module:
from cd_proxy_manager import SysProxy
# Example: setting a proxy environment variable
proxy = "proxy:port"
SysProxy().set_proxy(proxy)
To manage multiple proxies, use the proxy_dealer.py
module:
from cd_proxy_manager import ProxyDealer
# Example: rotating proxies
dealer = ProxyDealer(["proxy1:port", "proxy2:port"])
proxy = dealer.get_next_proxy_no_shuffle()
print(proxy)
Refer to the examples/
directory for more detailed usage examples.
Contributions are welcome! Please submit a pull request or open an issue to discuss any changes.
This project is licensed under the MIT License.
For more information, visit codedocta.com.
FAQs
Manages proxies for http or selenium and some common uses cases like random,cycle, or set env/sys proxy.
We found that cd-proxy-manager demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.