(csr: Any)
| 362 | |
| 363 | @staticmethod |
| 364 | def _add_ca_usages(csr: Any) -> Any: |
| 365 | return csr.add_extension( |
| 366 | x509.BasicConstraints(ca=True, path_length=9), |
| 367 | critical=True, |
| 368 | ).add_extension( |
| 369 | x509.KeyUsage( |
| 370 | digital_signature=True, |
| 371 | content_commitment=False, |
| 372 | key_encipherment=False, |
| 373 | data_encipherment=False, |
| 374 | key_agreement=False, |
| 375 | key_cert_sign=True, |
| 376 | crl_sign=True, |
| 377 | encipher_only=False, |
| 378 | decipher_only=False), |
| 379 | critical=True |
| 380 | ).add_extension( |
| 381 | x509.ExtendedKeyUsage([ |
| 382 | ExtendedKeyUsageOID.CLIENT_AUTH, |
| 383 | ExtendedKeyUsageOID.SERVER_AUTH, |
| 384 | ExtendedKeyUsageOID.CODE_SIGNING, |
| 385 | ]), |
| 386 | critical=True |
| 387 | ) |
| 388 | |
| 389 | @staticmethod |
| 390 | def _add_leaf_usages(csr: Any, domains: List[str], issuer: Credentials) -> Any: |
no outgoing calls
no test coverage detected