Remote CA certificate service for Swarmauri
Project description
Swarmauri Remote CA Cert Service
A certificate enrollment bridge implementing the ICertService interface and
forwarding CSRs to a remote Certificate Authority.
Features:
- Posts CSRs to a remote endpoint and returns issued certificates.
- Minimal parsing helpers for certificate snippets.
- Designed around X.509 as defined in RFC 5280 and Enrollment over Secure Transport (EST) in RFC 7030.
Installation
pip install swarmauri_certs_remote_ca
Entry Point
The service registers under the swarmauri.certs entry point as
RemoteCaCertService.
Usage
The service is asynchronous and expects an existing CSR (certificate signing request) in PEM or DER form. Configure the remote CA endpoint and submit the CSR to receive the issued certificate:
import asyncio
import base64
import json
import httpx
from swarmauri_certs_remote_ca import RemoteCaCertService
csr = b"example-csr"
cert_bytes = b"example-cert"
async def main() -> None:
async def handler(request: httpx.Request) -> httpx.Response:
data = json.loads(request.content)
assert base64.b64decode(data["csr"]) == csr
return httpx.Response(200, json={"cert": base64.b64encode(cert_bytes).decode()})
transport = httpx.MockTransport(handler)
svc = RemoteCaCertService("https://ca.example/sign")
svc._client = httpx.AsyncClient(transport=transport)
cert = await svc.sign_cert(csr, {"kind": "dummy"})
print(cert)
asyncio.run(main())
The example above mocks a CA using httpx.MockTransport. In real scenarios
RemoteCaCertService posts the CSR to the configured endpoint and returns the
certificate bytes supplied by the remote CA.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file swarmauri_certs_remote_ca-0.3.0.dev3.tar.gz.
File metadata
- Download URL: swarmauri_certs_remote_ca-0.3.0.dev3.tar.gz
- Upload date:
- Size: 7.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a703db4fc861903950645170586d6c763eecc47f76bf29d4f4bb2fcd7928d0da
|
|
| MD5 |
24c8aab94434f15f44bb1dcc65507ba2
|
|
| BLAKE2b-256 |
7dc22a1d39340eb40946d61782f40350d46f674ef4046f7fbbe3ed595679cd2c
|
File details
Details for the file swarmauri_certs_remote_ca-0.3.0.dev3-py3-none-any.whl.
File metadata
- Download URL: swarmauri_certs_remote_ca-0.3.0.dev3-py3-none-any.whl
- Upload date:
- Size: 9.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5546631c2cba9b66cf57c60ca67b28ce01acea11a85d276c3f060e0d4f0f3195
|
|
| MD5 |
7b66a92527279846fce6516d26f6b572
|
|
| BLAKE2b-256 |
7ca64f985055a93104eb9b09f2b7486b4d44406258951e9012877a0b34e755ed
|