zencoreipinfo
Get outgoing ip from https://zencore.cn/ipinfo.
Install
pip install zencoreipinfo
Usage in Cli
test@test zencoreipinfo % ipinfo --help
Usage: ipinfo [OPTIONS]
Options:
--url TEXT Server url. Can apply multiple times.
-q, --quiet Don't show error information.
--help Show this message and exit.
test@test zencoreipinfo % ipinfo
aaa.xxx.yy.zz
- By default, the program will use the default ipinfo server
https://zencore.cn/ipinfo. - We ship cli program in name
ipinfo, andzencoreipinfoas it's alias.
Usage in Script
In [1]: from zencoreipinfo import get_outgoing_ip
In [2]: ip = get_outgoing_ip()
In [3]: print(ip)
aaa.xxx.yy.zz
How to implement self ipinfo server?
You need a linux server with a public ip address, and you need to install nginx service on the linux server. Add the ipinfo location into your site.
# your other configs
location /ipinfo {
add_header Content-Type text/plain;
return 200 $remote_addr;
}
# your other configs
After you setup your ipinfo server. Run the ipinfo command with --url prarameter.
test@test zencoreipinfo % ipinfo --url https://you.site.domain.cn/ipinfo
aaa.xxx.yy.zz
About the ipinfo server of zencore.cn
We do not promise continuity or reliability of the service.
Release
0.1.0
- First release.
Metadata
Release files for zencoreipinfo 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| zencoreipinfo-0.1.0.tar.gz | 3.7 kB | Without provenance | Details for zencoreipinfo-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| zencoreipinfo-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for zencoreipinfo-0.1.0-py3-none-any.whl |
Total release size: 7.4 kB
Release files / zencoreipinfo-0.1.0.tar.gz
| Download URL | zencoreipinfo-0.1.0.tar.gz |
|---|---|
| Size | 3.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0aaba3b8693dec64b6b734264dd56011fa56d62c67e8e0190c86aabc7b09afb3
|
|
BLAKE2b-256 checksum How to use checksums |
ec5fbacfa94687fa8522c8b1add49af83ec0fa753c5119272a251d0ecd8fec76
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.4
|
Release files / zencoreipinfo-0.1.0-py3-none-any.whl
| Download URL | zencoreipinfo-0.1.0-py3-none-any.whl |
|---|---|
| Size | 3.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
30c841df25207e119e45f3c5cbe17cb4ce0ec88d8cd3dc1e786d13ae8fc27fd8
|
|
BLAKE2b-256 checksum How to use checksums |
2cd30bf5ab32dd500fcb54af0f1ca7077b8c3586bd5e194e487bfad9614c947e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.4
|
Security for zencoreipinfo 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.