Struct desfire::app_settings

Struct Documentation

struct app_settings

Represents the settings for an application.

Public Functions

explicit constexpr app_settings(app_crypto crypto_ = app_crypto::legacy_des_2k3des, key_rights rights_ = key_rights{}, std::uint8_t max_num_keys_ = bits::max_keys_per_app)

Constructs a new app_settings object.

Parameters:
  • crypto_ – Cryptography to use, defaults to DES (which is insecure).

  • rights_ – Key rights, defaults to the master key holding all rights.

  • max_num_keys_ – Number of keys in the app, defaults to 14 (the maximum).

explicit constexpr app_settings(cipher_type cipher, key_rights rights_ = key_rights{}, std::uint8_t max_num_keys_ = bits::max_keys_per_app)

Constructs a new app_settings objects starting from a cipher_type.

Parameters:
  • cipher – Cipher to use for this app. This better be AES128.

  • rights_ – Key rights, defaults to the master key holding all rights.

  • max_num_keys_ – Number of keys in the app, defaults to 14 (the maximum).

Public Members

key_rights rights

Permission for the various app keys.

std::uint8_t max_num_keys

Maximum number of keys in the app (at least 1).

app_crypto crypto

Cryptography settings for this app.