Skip to main content

A library for shared classes and functionalities in the ZLiC project.

Project description

zlic-utils

A library for shared classes and functionalities in the ZLiC project.

Installation

pip install zlicutils

Installation for development purposes

pip install -e .   

Tests

python -m pytest tests/

Usage

create Server with tun access

from fastapi import Depends

from zlicutils.server import Server
from zlicutils.tan import TanManager

server = Server(host='0.0.0.0', port=8888)

tan_manager = TanManager()

server.router.add_api_route("/api/{id}", _api methods=["GET"])

server.router.add_api_route("/tan", tan_manager.tans_as_html, methods=["GET"])
server.router.add_api_route("/api/verified/{source_id}", self._api_verified_, methods=["GET"], dependencies=[Depends(tan_manager.verify_tan)])

server.start()

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

Authors and acknowledgment

License

GNU GPLv3

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

zlicutils-1.1.0.tar.gz (15.1 kB view details)

Uploaded Source

Built Distribution

zlicutils-1.1.0-py3-none-any.whl (15.6 kB view details)

Uploaded Python 3

File details

Details for the file zlicutils-1.1.0.tar.gz.

File metadata

  • Download URL: zlicutils-1.1.0.tar.gz
  • Upload date:
  • Size: 15.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for zlicutils-1.1.0.tar.gz
Algorithm Hash digest
SHA256 b6678f02335b7769ae1e965229e487e7aed0fb51192716ff26eba371c9bc16e9
MD5 d0f2bbbf520ff859bf04f2685fdc15f3
BLAKE2b-256 12b602b6b050176c6ca045ef52b84dfd2f10ca682f2a1acc69f4afb9ee0c301b

See more details on using hashes here.

File details

Details for the file zlicutils-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: zlicutils-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 15.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for zlicutils-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ccbf18518a3960b0841bf11db564630b1687f3d3d2e217ad29b42cf80feb4e3d
MD5 ecd0598534c7face6ad9ddb1e30ef58b
BLAKE2b-256 c6d66e0fe9ef6313283ec4adc9ad938e986700a0ed29c1356613e8554d6c43a8

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page