hetzner-fireaccess-cleaner
This CLI is to be used with clearing automated access to a Hetzner firewall
Getting started
pip install hetzner-fireaccess-cleaner
How does it work?
This script is made to be run by an automation, like crontab.
It's looking for the string auto-expire-[] where we have a timestamp to when the listed rule should expire in UNIX time.
Example: auto-expire-[1647127315]
Remote access for USER - auto-expire-[1647127315]
It uses the default hcloud CLI config file. https://github.com/hetznercloud/cli
How you implement and use this is up to you.
Usage
hetzner-fireaccess-cleaner clean [FIREWALL NAME]
For more info about available flags, checkout out the help hetzner-fireaccess-cleaner -h.
Examples
Clean the firewall firewall-1
hetzner-fireaccess-cleaner clean firewall-1
Using a different context than the current active
hetzner-fireaccess-cleaner --context access-project clean remote-firewall
DEMO
$ hetzner-fireaccess-cleaner clean remote-firewall
No context provided, using default
Rule marked for removal: A rule which is expored auto-expire-[1647127315]
Removing rules
Finished
Contributions
Contributions are welcome.
Disclaimer
This has not yet been tested a lot and only on a small hetzner account, use with caution.
Metadata
Release files for hetzner-fireaccess-cleaner 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| hetzner-fireaccess-cleaner-0.0.1.tar.gz | 3.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hetzner_fireaccess_cleaner-0.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 7.1 kB
Release files / hetzner-fireaccess-cleaner-0.0.1.tar.gz
| Download URL | hetzner-fireaccess-cleaner-0.0.1.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e01ccf9bc5b52e961ea13f640d26ab182e3f3641ea2b57ed210f266660be493b
|
|
BLAKE2b-256 checksum How to use checksums |
dc349ee7475b1cd7fc5058a517f32dee4487cbafb537a05e17240616671b417d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2
|
Release files / hetzner_fireaccess_cleaner-0.0.1-py3-none-any.whl
| Download URL | hetzner_fireaccess_cleaner-0.0.1-py3-none-any.whl |
|---|---|
| Size | 3.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d71b955c07ff8c9c2913d18c97349233542b859df74c6a2ccf379c8b734a1755
|
|
BLAKE2b-256 checksum How to use checksums |
428bf754c17c3c1a618d90a29d13d2b7ef7f4653d4ca76c676b1d42b29a2c1f3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2
|