Library for working with wireguard configs.
Project description
neowg
ВАЖНО, БИБЛИОТЕКА РАБОТАЕТ ТОЛЬКО СО СВОИМ ФОРМАТОМ КОНФИГОВ
Установка
pip install neowg
Примеры использования:
Создание нового конфига
from neowg import WgServerConfig
config = WgServerConfig.new(
server_ip="<YOUR_WG_SERVER_IP>",
net_adapter="<YOUR_WG_SERVER_NET_ADAPTER>",
clients_count=100,
) # Создание объекта конфига
config.dump("wg.conf") # Запись конфига в файл
Чтение конфига из файла.
from neowg import WgServerConfig
config = WgServerConfig.from_file("wg.conf") # Создание объекта конфига
Изменения пары ключей
from neowg import WgServerConfig
config = WgServerConfig.from_file("wg.conf") # Создание объекта конфига
config.update_keys("10.0.0.2")
config.dump("wg.conf")
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
neowg-1.3.2.tar.gz
(5.4 kB
view details)
Built Distribution
neowg-1.3.2-py3-none-any.whl
(7.4 kB
view details)
File details
Details for the file neowg-1.3.2.tar.gz
.
File metadata
- Download URL: neowg-1.3.2.tar.gz
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.4 CPython/3.13.0 Darwin/24.1.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e831b05c91ab182001a63e80e2702313d24c963a63f26a7d3aa6ffaf9a3a8a1 |
|
MD5 | d8150aa815681ee67dacff53cc51b490 |
|
BLAKE2b-256 | 501ff455299a4c92fbf8239ef80e195ded29f361d137bcfbe537d6e406ea8a53 |
File details
Details for the file neowg-1.3.2-py3-none-any.whl
.
File metadata
- Download URL: neowg-1.3.2-py3-none-any.whl
- Upload date:
- Size: 7.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.4 CPython/3.13.0 Darwin/24.1.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 872398b9b1793874461e10f9a34dc1084c3cdeea34aae12865bd7b8dbb364c32 |
|
MD5 | 6d6625816e946d9ea16c2d2e25252a45 |
|
BLAKE2b-256 | 4d716bfd2e91dab60c2fa792275aa3881c3874a44cac2fba6083b62e0f5fc062 |