Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/minvws/puzi-python
Proficient UZI pass reader in python.
https://github.com/minvws/puzi-python
python uzi-card uzipas
Last synced: about 1 month ago
JSON representation
Proficient UZI pass reader in python.
- Host: GitHub
- URL: https://github.com/minvws/puzi-python
- Owner: minvws
- License: eupl-1.2
- Created: 2021-03-12T13:02:01.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2024-11-06T12:54:55.000Z (about 2 months ago)
- Last Synced: 2024-11-06T13:55:05.563Z (about 2 months ago)
- Topics: python, uzi-card, uzipas
- Language: Python
- Homepage:
- Size: 389 KB
- Stars: 2
- Watchers: 14
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.pdf
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
![pUZI logo](pUZI.svg "pUZI logo")
# pUZI python[![Python application](https://github.com/minvws/pUzi-python/actions/workflows/python.yaml/badge.svg)](https://github.com/minvws/pUzi-python/actions/workflows/python.yaml)
Proficient UZI pass reader in python, based on work by Anne Jan: https://github.com/minvws/pUZI-php
The UZI card is part of an authentication mechanism for medical staff and doctors working in the Netherlands. The cards are distributed by the CIBG. More information and the relevant client software can be found at www.uziregister.nl (in Dutch).
pUZI is a simple and functional module which allows you to use the UZI cards as authentication mechanism. It consists of:
1. a reader that reads the data on the card and gives an UziUser object in return (this repository).
pUZI is available under the EU PL licence. It was created early 2021 during the COVID19 campaign as part of the vaccination registration project BRBA for the ‘Ministerie van Volksgezondheid, Welzijn & Sport, programma Realisatie Digitale Ondersteuning.’
Questions and contributions are welcome via [GitHub](https://github.com/minvws/pUzi-python/issues).
See [www.Uziregister.nl](https://www.uziregister.nl) for the documentation, software and application form for the UZI card.
## Requirements
* python >= 3.6
Apache config (or NginX equivalent):
```apacheconf
SSLEngine on
SSLProtocol -all +TLSv1.3
SSLHonorCipherOrder on
SSLCipherSuite ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384
SSLVerifyClient require
SSLVerifyDepth 3
SSLCACertificateFile /path/to/uziCA.crt
SSLOptions +StdEnvVars +ExportCertData
```## Installation
```bash
pip install pUzi
```## Usage
```python3
from uzireader.uzipassuser import UziPassUser
uzipas = UziPassUser(env['SSL_CLIENT_VERIFY'], env['SSL_CLIENT_CERT'])
print(uzipas)
``````json
{"givenName": "john", "surName": "doe-11111111", "OidCa": "2.16.528.1.1003.1.3.5.5.2", "UziVersion": "1", "UziNumber": "11111111", "CardType": "N", "SubscriberNumber": "90000111", "Role": "01.015", "AgbCode": "00000000"}
```## Uses
[Python cryptography Library](https://cryptography.io/en/)
## Contributing
1. Fork the Project
2. Ensure you have the requirements and Black installed
```shell
pip3 install -r requirements.txt
pip3 install black
```3. Create a Feature Branch
4. Run tests
```sh
cd tests/certs
./generate_mock_certs.sh
cd -
python3 -m unittest
```5. (Recommended) Check whether your code conforms to our Coding Standards by running black on your changed files
```sh
black .
```6. Send us a Pull Request
![pUZI](pUZI-hidden.svg "pUZI")