Skip to content

Types

sereto.types

TypeCategories = set[Annotated[str, Field(pattern='^[a-zA-Z0-9._-]{1,20}$', strict=True)]] module-attribute

Type for categories names.

The values should meet the following requirements:

  • It can only contain letters (a-zA-Z), numbers (0-9), underscore (_), dash (-), and dot (.).
  • It should be between 1 and 20 characters long.
Example

You can provide values such as dast, sast (or DAST, SAST), etc.

TypeNonce12B = Annotated[bytes, AfterValidator(zero_bytes), Field(min_length=12, max_length=12)] module-attribute

Type for a 12 byte long nonce.

The value must contain at least one non-zero byte. This check is in place to prevent unintentional errors.

TypePassword = Annotated[str, Field(min_length=8, max_length=100, strict=True)] module-attribute

Type for password.

The value should meet the following requirements:

  • It should be between 8 and 100 characters long.

TypePathName = Annotated[str, Field(pattern='^[a-zA-Z0-9._-]{1,100}$', strict=True)] module-attribute

Type for path name.

The value should meet the following requirements:

  • It can only contain letters (a-zA-Z), numbers (0-9), underscore (_), dash (-), and dot (.).
  • It should be between 1 and 100 characters long.

TypeReportId = Annotated[str, Field(pattern='^[a-zA-Z0-9._-]{1,20}$', strict=True)] module-attribute

Type for report ID.

The value should meet the following requirements:

  • It can only contain letters (a-zA-Z), numbers (0-9), underscore (_), dash (-), and dot (.).
  • It should be between 1 and 20 characters long.

TypeSalt16B = Annotated[bytes, AfterValidator(zero_bytes), Field(min_length=16, max_length=16)] module-attribute

Type for a 16 byte long salt.

The value must contain at least one non-zero byte. This check is in place to prevent unintentional errors.