SimpleSecretGenerateRules#
- pydantic model phalanx.models.secrets.SimpleSecretGenerateRules#
Rules for generating a secret value with no source information.
- Parameters:
data (
Any
) –
Show JSON schema
{ "title": "SimpleSecretGenerateRules", "description": "Rules for generating a secret value with no source information.", "type": "object", "properties": { "type": { "title": "Type", "enum": [ "password", "gafaelfawr-token", "fernet-key", "rsa-private-key" ], "type": "string" } }, "required": [ "type" ], "additionalProperties": false }
- Config:
allow_population_by_field_name: bool = True
extra: Extra = Extra.forbid
- Fields:
type (Literal[
-
field type:
Literal
[<SecretGenerateType.password: 'password'>
,<SecretGenerateType.gafaelfawr_token: 'gafaelfawr-token'>
,<SecretGenerateType.fernet_key: 'fernet-key'>
,<SecretGenerateType.rsa_private_key: 'rsa-private-key'>
] [Required]# Type of secret.
- generate()#
Generate a new secret following these rules.
- Return type:
SecretStr