Metadata-Version: 2.4
Name: sep2cert
Version: 0.1.0
Summary: Useful functions for working with IEEE 2030.5 (SEP2)
Author-email: Alex Guinman <alex@guinman.id.au>
Requires-Python: >=3.12
Description-Content-Type: text/markdown
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.14
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.12
Classifier: Operating System :: OS Independent
License-File: LICENSE
Requires-Dist: asn1==2.8.0
Requires-Dist: cryptography>=44.0.1
Requires-Dist: python-dateutil>=2.8.2
Requires-Dist: typer>=0.15.1
Requires-Dist: pytest>=2.7.3 ; extra == "test"
Requires-Dist: pytest-cov>=6.0.0 ; extra == "test"
Project-URL: Source, https://github.com/aguinane/SEP2-Certs
Provides-Extra: test

# SEP2-Certs

Create and verify IEEE 2030.5 (SEP2) PKI certificates

## Certificate Inspection

Get the LFDI for a certificate. It will also do some validation checks.

```sh
python -m sep2cert cert-lfdi certs/dev-ABC-cert.pem
```

## Certificate Creation

Note the below CLI commands are only intended for testing purposes.
For production certificates, additional functions and policies may be required.

### Signing Certificates

Create a SERCA, and a MICA.

```sh
python -m sep2cert create-serca
python -m sep2cert create-mica certs/serca.pem certs/serca.key
```

### Device Certificates

To create a device certificate, first create a Key and Certificate Signing Request (CSR).

```sh
python -m sep2cert create-key --key-file certs/dev-ABC.key
```

Once you have the CSR, build the cert by signing with the MICA.

```sh
python -m sep2cert create-cert certs/dev-ABC.csr certs/mica.pem certs/mica.key --pen 12345 --serno ABC
```

