Authenticate
- class Authenticate(host, username=None, password=None, application_id=None, scope=None, websdk_token=None, proxies=None, certificate_path=None, key_file_path=None, verify_ssl=False, connection_timeout=None, read_timeout=None, **kwargs)
Bases:
object
Authenticates to TPP WebSDK.
For WebSDK, either an OAuth bearer token can be obtained, which requires both an Application ID and scope to be supplied, or the X-Venafi-API-Key can be obtained, which has been deprecated since TPP version 20.1.
Using the OAuth authentication method requires an API Application Integration to be created via Aperture that defines the maximum possible scope and the users/groups that are authorized to use that scope.
- Parameters
host (str) – Hostname or IP Address of TPP
username (str) – Username
password (str) – Password
application_id (str) – Application ID of the OAuth API Application Integration. Must supply
scope
.scope (Union[Scope, str]) – Scope of the OAuth API Application Integration to be used. Must supply
application_id
.websdk_token (str) – OAuth Access Bearer Token.
version – Version of the TPP server.
proxies (dict) – An OrderedDict used by the python Requests library.
certificate_path (str) – Absolute path to the public certificate file.
key_file_path (str) – Absolute path to the private key file.
verify_ssl (bool) – If
True
, verify the SSL certificate of the target endpoints.connection_timeout (float) – Timeout in seconds to establish a connection to the API service.
read_timeout (float) – Timeout in seconds between each byte received from the server.
- property host
- property password
- re_authenticate(host=None, username=None, password=None, application_id=None, scope=None, proxies=None, certificate_path=None, key_file_path=None, verify_ssl=None, connection_timeout=None, read_timeout=None, **kwargs)
Performs a re-authentication using the same parameters used to authorize initially.
- Parameters
host (Optional[str]) – Hostname or IP Address
username (Optional[str]) – Username
password (Optional[str]) – Password
application_id (Optional[str]) – Application ID applicable to OAuth. Must supply
scope
.scope (Optional[str]) – Scope within the Application. Must supply
application_id
.proxies (Optional[dict]) – An OrderedDict used by the python Requests library.
certificate_path (Optional[str]) – Absolute path to the public certificate file.
key_file_path (Optional[str]) – Absolute path to the private key file.
verify_ssl (Optional[bool]) – If
True
, verify the SSL certificate of the target endpoints.connection_timeout (Optional[float]) – Timeout in seconds to establish a connection to the API service.
read_timeout (Optional[float]) – Timeout in seconds between each byte received from the server.
- property username