Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: eclass/
Date: Wed, 31 Mar 2021 02:04:29
Message-Id: 1617156171.6ac96d02b89753a55881da303e64e08ea9774f50.sam@gentoo
1 commit: 6ac96d02b89753a55881da303e64e08ea9774f50
2 Author: Sam James <sam <AT> gentoo <DOT> org>
3 AuthorDate: Wed Mar 31 00:51:25 2021 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Wed Mar 31 02:02:51 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6ac96d02
7
8 ssl-cert.eclass: mark various functions as @INTERNAL
9
10 Signed-off-by: Sam James <sam <AT> gentoo.org>
11
12 eclass/ssl-cert.eclass | 13 ++++++-------
13 1 file changed, 6 insertions(+), 7 deletions(-)
14
15 diff --git a/eclass/ssl-cert.eclass b/eclass/ssl-cert.eclass
16 index f2be814470d..a774f9b8b9e 100644
17 --- a/eclass/ssl-cert.eclass
18 +++ b/eclass/ssl-cert.eclass
19 @@ -65,12 +65,12 @@ if [[ "${SSL_DEPS_SKIP}" == "0" ]]; then
20 fi
21
22 # @FUNCTION: gen_cnf
23 +# @INTERNAL
24 # @USAGE:
25 # @DESCRIPTION:
26 # Initializes variables and generates the needed
27 # OpenSSL configuration file and a CA serial file
28 #
29 -# Access: private
30 gen_cnf() {
31 # Location of the config file
32 SSL_CONF="${T}/${$}ssl.cnf"
33 @@ -117,13 +117,13 @@ gen_cnf() {
34 }
35
36 # @FUNCTION: get_base
37 +# @INTERNAL
38 # @USAGE: [if_ca]
39 # @RETURN: <base path>
40 # @DESCRIPTION:
41 # Simple function to determine whether we're creating
42 # a CA (which should only be done once) or final part
43 #
44 -# Access: private
45 get_base() {
46 if [ "${1}" ] ; then
47 echo "${T}/${$}ca"
48 @@ -133,11 +133,11 @@ get_base() {
49 }
50
51 # @FUNCTION: gen_key
52 +# @INTERNAL
53 # @USAGE: <base path>
54 # @DESCRIPTION:
55 # Generates an RSA key
56 #
57 -# Access: private
58 gen_key() {
59 local base=$(get_base "$1")
60 ebegin "Generating ${SSL_BITS} bit RSA key${1:+ for CA}"
61 @@ -153,12 +153,12 @@ gen_key() {
62 }
63
64 # @FUNCTION: gen_csr
65 +# @INTERNAL
66 # @USAGE: <base path>
67 # @DESCRIPTION:
68 # Generates a certificate signing request using
69 # the key made by gen_key()
70 #
71 -# Access: private
72 gen_csr() {
73 local base=$(get_base "$1")
74 ebegin "Generating Certificate Signing Request${1:+ for CA}"
75 @@ -170,6 +170,7 @@ gen_csr() {
76 }
77
78 # @FUNCTION: gen_crt
79 +# @INTERNAL
80 # @USAGE: <base path>
81 # @DESCRIPTION:
82 # Generates either a self-signed CA certificate using
83 @@ -177,7 +178,6 @@ gen_csr() {
84 # a signed server certificate using the CA cert previously
85 # created by gen_crt()
86 #
87 -# Access: private
88 gen_crt() {
89 local base=$(get_base "$1")
90 if [ "${1}" ] ; then
91 @@ -200,12 +200,12 @@ gen_crt() {
92 }
93
94 # @FUNCTION: gen_pem
95 +# @INTERNAL
96 # @USAGE: <base path>
97 # @DESCRIPTION:
98 # Generates a PEM file by concatinating the key
99 # and cert file created by gen_key() and gen_cert()
100 #
101 -# Access: private
102 gen_pem() {
103 local base=$(get_base "$1")
104 ebegin "Generating PEM Certificate"
105 @@ -224,7 +224,6 @@ gen_pem() {
106 #
107 # Example: "install_cert /foo/bar" installs ${ROOT}/foo/bar.{key,csr,crt,pem}
108 #
109 -# Access: public
110 install_cert() {
111 if [ $# -lt 1 ] ; then
112 eerror "At least one argument needed"