tests.tlstests.conftest
mTLS fixtures
Module Contents
Functions
|
Make sure we have a well known directory structure |
|
Generate a keypair |
|
Generate CSR file |
|
Return cert, key and ca cert paths, this will sign the CSR again every time due to fixture scoping issues |
|
fixture for client session with correct ssl context |
Attributes
- datadir(nice_tmpdir_mod)[source]
Make sure we have a well known directory structure
- Parameters:
nice_tmpdir_mod (str)
- Return type:
- keypair(datadir)[source]
Generate a keypair
- Parameters:
datadir (pathlib.Path)
- Return type:
OpenSSL.crypto.PKey
- csrfile(datadir, keypair)[source]
Generate CSR file
- Parameters:
datadir (pathlib.Path)
keypair (OpenSSL.crypto.PKey)
- Return type:
- async mtlsfiles(csrfile)[source]
Return cert, key and ca cert paths, this will sign the CSR again every time due to fixture scoping issues
- Parameters:
csrfile (pathlib.Path)
- Return type:
Tuple[pathlib.Path, pathlib.Path]
- mtlsclient(mtlsfiles)[source]
fixture for client session with correct ssl context
- Parameters:
mtlsfiles (Tuple[pathlib.Path, pathlib.Path])
- Return type:
aiohttp.ClientSession