2021-01-14 23:39:01 +00:00
|
|
|
## <summary>SSL certificate requesting tool certbot AKA letsencrypt.</summary>
|
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Execute certbot/letsencrypt in the certbot
|
|
|
|
## domain.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
2021-06-30 08:03:44 +00:00
|
|
|
## <summary>
|
|
|
|
## Domain allowed to transition.
|
|
|
|
## </summary>
|
2021-01-14 23:39:01 +00:00
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`certbot_domtrans',`
|
|
|
|
gen_require(`
|
|
|
|
type certbot_t, certbot_exec_t;
|
|
|
|
')
|
|
|
|
|
|
|
|
domtrans_pattern($1, certbot_exec_t, certbot_t)
|
|
|
|
')
|
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Execute certbot/letsencrypt in the certbot
|
|
|
|
## domain, and allow the specified role
|
|
|
|
## the firstboot domain.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
2021-06-30 08:03:44 +00:00
|
|
|
## <summary>
|
|
|
|
## Domain allowed to transition.
|
|
|
|
## </summary>
|
2021-01-14 23:39:01 +00:00
|
|
|
## </param>
|
|
|
|
## <param name="role">
|
2021-06-30 08:03:44 +00:00
|
|
|
## <summary>
|
|
|
|
## Role allowed access.
|
|
|
|
## </summary>
|
2021-01-14 23:39:01 +00:00
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`certbot_run',`
|
|
|
|
gen_require(`
|
|
|
|
type certbot_t;
|
|
|
|
')
|
|
|
|
|
|
|
|
certbot_domtrans($1)
|
|
|
|
role $2 types certbot_t;
|
|
|
|
')
|
2021-11-07 01:23:18 +00:00
|
|
|
|
|
|
|
########################################
|
|
|
|
## <summary>
|
|
|
|
## Read TLS certificates and keys
|
|
|
|
## generated by certbot.
|
|
|
|
## </summary>
|
|
|
|
## <param name="domain">
|
|
|
|
## <summary>
|
|
|
|
## Domain allowed access.
|
|
|
|
## </summary>
|
|
|
|
## </param>
|
|
|
|
#
|
|
|
|
interface(`certbot_read_lib',`
|
|
|
|
gen_require(`
|
|
|
|
type certbot_lib_t;
|
|
|
|
')
|
|
|
|
|
|
|
|
search_dirs_pattern($1, certbot_lib_t, certbot_lib_t)
|
|
|
|
read_files_pattern($1, certbot_lib_t, certbot_lib_t)
|
|
|
|
')
|