Revize c4b2f4d2
Přidáno uživatelem Stanislav Král před asi 4 roky(ů)
proj/services/cryptography.py | ||
---|---|---|
135 | 135 |
|
136 | 136 |
return self._run_for_output(args, proc_input=bytes(subject_key, encoding="utf-8")).decode() |
137 | 137 |
|
138 |
def sign_csr(self, csr, issuer_pem, issuer_key, issuer_key_pass=None, config="", extensions="", days=30):
|
|
138 |
def sign_csr(self, csr, issuer_pem, issuer_key, issuer_key_pass=None, extensions="", days=30): |
|
139 | 139 |
""" |
140 | 140 |
Signs the given CSR by the given issuer CA |
141 | 141 |
|
... | ... | |
144 | 144 |
:param issuer_key: string containing the private key of the issuer's certificate in PEM format |
145 | 145 |
:param issuer_key_pass: string containing the passphrase of the private key of the issuer's certificate in PEM |
146 | 146 |
format |
147 |
:param config: TODO NOT USED |
|
148 | 147 |
:param extensions: extensions to be applied when signing the CSR |
149 |
:param days: number of days for which the certificate will be valid TODO this parameter is not in the SW arch.
|
|
148 |
:param days: number of days for which the certificate will be valid |
|
150 | 149 |
:return: string containing the generated and signed certificate in PEM format |
151 | 150 |
""" |
152 | 151 |
|
... | ... | |
170 | 169 |
return self._run_for_output(params, proc_input=(bytes(proc_input, encoding="utf-8"))).decode() |
171 | 170 |
|
172 | 171 |
def create_crt(self, subject, subject_key, issuer_pem, issuer_key, subject_key_pass=None, issuer_key_pass=None, |
173 |
config="", |
|
174 | 172 |
extensions="", |
175 | 173 |
days=30): |
176 | 174 |
""" |
... | ... | |
185 | 183 |
format |
186 | 184 |
:param issuer_key_pass: string containing the passphrase of the private key of the issuer's certificate in PEM |
187 | 185 |
format |
188 |
:param config: TODO NOT USED |
|
189 | 186 |
:param extensions: extensions to be applied when creating the certificate |
190 | 187 |
:param days: number of days for which the certificate will be valid |
191 | 188 |
:return: string containing the generated certificate in PEM format |
Také k dispozici: Unified diff
Re #8472 - Removed unused method parameters