Go to file
Daniel Barlow 8a7287d552 unhardcode the certificate serial number 2024-09-25 12:00:40 +01:00
Makefile initial commit 2024-09-25 10:20:14 +01:00
README initial commit 2024-09-25 10:20:14 +01:00
default.nix initial commit 2024-09-25 10:20:14 +01:00
main.fnl unhardcode the certificate serial number 2024-09-25 12:00:40 +01:00
package.nix initial commit 2024-09-25 10:20:14 +01:00

README

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

A small HTTPS API that accepts X509 CSRs and signs them if they
contain the magic number.

Modelled on the Puppet CA "Policy-based autosigning" functionality,
but without the rest of Puppet

[ This README is speculative ]


---

DOMAIN="/C=GB/ST=London/L=London/O=Telent"

openssl genrsa -out ca.key 4096
openssl req -x509 -new -nodes -key ca.key -sha256 -days 3650 -subj "${DOMAIN}/CN=CA" -out ca.crt

openssl req -newkey rsa:2048 -nodes -keyout domain.key -out domain.csr -subj "${DOMAIN}/OU=devices/CN=rotuer"




https://www.puppet.com/docs/puppet/7/ssl_attributes_extensions#csr_custom_attributes-recommended-oids-custom-attributes

Custom attributes can use any public or site-specific OID, with the exception of the OIDs used for core X.509 functionality. This means you cant re-use existing OIDs for things like subject alternative names.

One useful OID is the challengePassword attribute — 1.2.840.113549.1.9.7. This is a rarely-used corner of X.509 that can easily be repurposed to hold a pre-shared key.