nitrokey.trussed.admin_app

class nitrokey.trussed.admin_app.AdminApp

Basisklassen: object

__init__(device)
Parameters:

device (TrussedDevice)

Return type:

None

factory_reset()
Return type:

bool

factory_reset_app(application)
Parameters:

application (str)

Return type:

bool

get_config(key)
Parameters:

key (str)

Return type:

str

has_config(key)
Parameters:

key (str)

Return type:

bool

is_locked()
Return type:

bool

list_available_fields()
Return type:

list[ConfigField]

reboot(mode=BootMode.FIRMWARE)
Parameters:

mode (BootMode)

Return type:

bool

rng()
Return type:

bytes

se050_tests()
Return type:

bytes | None

set_config(key, value)
Parameters:
  • key (str)

  • value (str)

Return type:

None

status()
Return type:

Status

uuid()
Return type:

Uuid | None

version()
Return type:

Version

class nitrokey.trussed.admin_app.AdminCommand

Basisklassen: Enum

is_legacy_command()
Return type:

bool

FACTORY_RESET = 132
FACTORY_RESET_APP = 133
GET_CONFIG = 130
LIST_AVAILABLE_FIELDS = 134
LOCKED = 99
REBOOT = 83
RNG = 96
SET_CONFIG = 131
STATUS = 128
TEST_SE050 = 129
UPDATE = 81
UUID = 98
VERSION = 97
class nitrokey.trussed.admin_app.BootMode

Basisklassen: Enum

BOOTROM = 2
FIRMWARE = 1
class nitrokey.trussed.admin_app.ConfigField

Basisklassen: object

ConfigField(naam: str, vereist_aanraking_bevestiging: bool, vereist_herstart: bool, destructief: bool, ty: nitrokey.trussed.admin_app.ConfigFieldType)

__init__(name, requires_touch_confirmation, requires_reboot, destructive, ty)
Parameters:
  • name (str)

  • requires_touch_confirmation (bool)

  • requires_reboot (bool)

  • destructive (bool)

  • ty (ConfigFieldType)

Return type:

None

destructive: bool
name: str
requires_reboot: bool
requires_touch_confirmation: bool
ty: ConfigFieldType
class nitrokey.trussed.admin_app.ConfigFieldType

Basisklassen: Enum

classmethod from_int(i)
Parameters:

i (int)

Return type:

ConfigFieldType | None

is_valid(value)
Parameters:

value (str)

Return type:

bool

BOOL = 0
U8 = 1
class nitrokey.trussed.admin_app.ConfigStatus

Basisklassen: Enum

classmethod check(i, msg)
Parameters:
  • i (int)

  • msg (str)

Return type:

None

classmethod from_int(i)
Parameters:

i (int)

Return type:

ConfigStatus | None

DATA_TOO_LONG = 7
DESERIALIZATION_FAILED = 3
INVALID_KEY = 5
INVALID_VALUE = 6
READ_FAILED = 1
SERIALIZATION_FAILED = 4
SUCCESS = 0
WRITE_FAILED = 2
class nitrokey.trussed.admin_app.FactoryResetStatus

Basisklassen: Enum

classmethod check(i, msg)
Parameters:
  • i (int)

  • msg (str)

Return type:

None

classmethod from_int(i)
Parameters:

i (int)

Return type:

FactoryResetStatus | None

APP_FAILED_PARSE = 3
APP_NOT_ALLOWED = 2
NOT_CONFIRMED = 1
SUCCESS = 0
class nitrokey.trussed.admin_app.InitStatus

Basisklassen: IntFlag

__new__(value)
is_error()
Return type:

bool

CONFIG_ERROR = 32
EXTERNAL_FLASH_ERROR = 4
INTERNAL_FLASH_ERROR = 2
MIGRATION_ERROR = 8
NFC_ERROR = 1
RNG_ERROR = 64
SE050_ERROR = 16
class nitrokey.trussed.admin_app.Status

Basisklassen: object

Status(init_status: Optioneel[nitrokey.trussed.admin_app.InitStatus] = Geen, ifs_blocks: Optioneel[int] = Geen, efs_blocks: Optioneel[int] = Geen, variant: Optioneel[nitrokey.trussed.admin_app.Variant] = Geen)

__init__(init_status=None, ifs_blocks=None, efs_blocks=None, variant=None)
Parameters:
  • init_status (InitStatus | None)

  • ifs_blocks (int | None)

  • efs_blocks (int | None)

  • variant (Variant | None)

Return type:

None

efs_blocks: int | None = None
ifs_blocks: int | None = None
init_status: InitStatus | None = None
variant: Variant | None = None
class nitrokey.trussed.admin_app.Variant

Basisklassen: Enum

LPC55 = 1
NRF52 = 2
USBIP = 0