Abstract
This role uses the root and intermediate certificate authorities from the ca and int roles to sign a certificate that can be used for encrypted services.
Certificate Signing Readme#
Certificate Sign Requirements#
This role assumes the presence of openssl on an ArchLinux system along with services that can be verified by globally-untrusted authorities.
Certificate Sign Role Variables#
This role requires the following variables to be set.
variable |
description |
default |
---|---|---|
|
the subject alternative names for the ca |
- DNS:ca.iana.org
- email:user@iana.org
|
|
the subject altnerative names for the signed cert |
- DNS:cert.iana.org
- email:user@iana.org
|
|
the common name to be associated with the signed cert |
|
|
filesystem path to the intermediate authority cert |
|
|
filesystem path to the intermediate authority private key |
|
|
subject alternative names for the intermediate cert |
- DNS:int.iana.org
- email:user@iana.org
|
|
a list of directories required by the signed cert |
- /etc/ssl/root/int/private
- /etc/ssl/root/int/certs
- /etc/ssl/root/int/csr
- /etc/ssl/root/int
|
|
path to the ca crt |
|
|
path to the certificate signing request |
|
|
a list of subject alternative names for the ca |
|
Dependencies#
The following roles should have been run on the target before using this role.
Example Playbook#
The site.yml
at the root of this repo contains a complete
example of usage for this role.
- name: Sign End User Certificate
hosts: localhost
roles:
- role: sign
tags:
- sign
vars:
sign_ca_san:
- DNS:ca.iana.org
- email:user@iana.org
sign_cert_san:
- DNS:cert.iana.org
- email:user@iana.org
sign_common_name: cert.iana.org
sign_int_path_crt: /etc/ssl/root/int/certs/int.crt
sign_int_path_key: /etc/ssl/root/int/private/int.key
sign_int_san:
- DNS:int.iana.org
- email:user@iana.org
sign_dirs:
- /etc/ssl/root/int/certs
- /etc/ssl/root/int/csr
- /etc/ssl/root/int/private
- /etc/ssl/root/int
sign_path_crt: /etc/ssl/root/int/certs/iana.crt
sign_path_csr: /etc/ssl/rott/int/csr/iana.csr
sign_path_key: /etc/ssl/root/int/private/iana.key