help_pages.commandsΒΆ

This module contains cli commands which are displayed in the help pages.

ClassesΒΆ

KeyGenCommandBuilder

Gets key-generation commands.

CmpSharedSecretCommandBuilder

Builds CMP shared-secret commands for different certificate profiles.

EstUsernamePasswordCommandBuilder

Builds EST username-password commands for different certificate profiles.

CmpClientCertificateCommandBuilder

EstClientCertificateCommandBuilder

Builds EST username-password commands for different certificate profiles.

Module ContentsΒΆ

class help_pages.commands.KeyGenCommandBuilder[source]ΒΆ

Gets key-generation commands.

static get_key_gen_command(public_key_info, cred_number, key_name='')[source]ΒΆ

Gets the key generation command corresponding to the provided type.

Parameters:
  • public_key_info (trustpoint_core.oid.PublicKeyInfo) – Key type information.

  • cred_number (int) – The credential number to use.

  • key_name (str) – Custom key file name, will default to key-{ cred_number }.pem otherwise.

Raises:

ValueError – If the public key information is inconsistent or key type is not supported.

Returns:

The key generation command as string.

Return type:

str

class help_pages.commands.CmpSharedSecretCommandBuilder[source]ΒΆ

Builds CMP shared-secret commands for different certificate profiles.

static get_tls_client_profile_command(host, pk, shared_secret, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • pk (int)

  • shared_secret (str)

  • cred_number (int)

Return type:

str

static get_tls_server_profile_command(host, pk, shared_secret, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • pk (int)

  • shared_secret (str)

  • cred_number (int)

Return type:

str

static get_opc_ua_client_profile_command(host, pk, shared_secret, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • pk (int)

  • shared_secret (str)

  • cred_number (int)

Return type:

str

static get_opc_ua_server_profile_command(host, pk, shared_secret, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • pk (int)

  • shared_secret (str)

  • cred_number (int)

Return type:

str

static get_domain_credential_profile_command(host, pk, shared_secret, domain_name)[source]ΒΆ
Parameters:
  • host (str)

  • pk (int)

  • shared_secret (str)

  • domain_name (str)

Return type:

str

class help_pages.commands.EstUsernamePasswordCommandBuilder[source]ΒΆ

Builds EST username-password commands for different certificate profiles.

static get_tls_client_profile_command(cred_number)[source]ΒΆ
Parameters:

cred_number (int)

Return type:

str

static get_tls_server_profile_command(cred_number)[source]ΒΆ
Parameters:

cred_number (int)

Return type:

str

static get_opc_ua_client_profile_command(cred_number)[source]ΒΆ
Parameters:

cred_number (int)

Return type:

str

static get_opc_ua_server_profile_command(cred_number)[source]ΒΆ
Parameters:

cred_number (int)

Return type:

str

static get_curl_enroll_command(est_username, est_password, host, cred_number)[source]ΒΆ
Parameters:
  • est_username (str)

  • est_password (str)

  • host (str)

  • cred_number (int)

Return type:

str

static get_conversion_der_pem_command(cred_number)[source]ΒΆ
Parameters:

cred_number (int)

Return type:

str

static get_domain_credential_profile_command()[source]ΒΆ
Return type:

str

static get_curl_enroll_domain_credential_command(est_username, est_password, host)[source]ΒΆ
Parameters:
  • est_username (str)

  • est_password (str)

  • host (str)

Return type:

str

static get_domain_credential_conversion_der_pem_command()[source]ΒΆ
Return type:

str

class help_pages.commands.CmpClientCertificateCommandBuilder[source]ΒΆ
static get_tls_client_profile_command(host, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • cred_number (int)

Return type:

str

static get_tls_server_profile_command(host, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • cred_number (int)

Return type:

str

static get_opc_ua_client_profile_command(host, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • cred_number (int)

Return type:

str

static get_opc_ua_server_profile_command(host, cred_number)[source]ΒΆ
Parameters:
  • host (str)

  • cred_number (int)

Return type:

str

class help_pages.commands.EstClientCertificateCommandBuilder[source]ΒΆ

Builds EST username-password commands for different certificate profiles.

static get_domain_credential_profile_command()[source]ΒΆ
Return type:

str

static get_curl_enroll_application_credential(cred_number, host)[source]ΒΆ
Parameters:
  • cred_number (int)

  • host (str)

Return type:

str