38 #ifndef NRF_MESH_PROV_TYPES_H_ 39 #define NRF_MESH_PROV_TYPES_H_ 44 #include "nrf_mesh_defines.h" 54 #define NRF_MESH_PROV_PUBKEY_SIZE 64 56 #define NRF_MESH_PROV_PRIVKEY_SIZE 32 58 #define NRF_MESH_PROV_ECDHSECRET_SIZE 32 60 #define NRF_MESH_PROV_DATANONCE_SIZE 13 63 #define NRF_MESH_PROV_OOB_SIZE_MAX 8 66 #define PROV_RANDOM_LEN (16) 68 #define PROV_CONFIRMATION_LEN (NRF_MESH_KEY_SIZE) 70 #define PROV_AUTH_LEN (NRF_MESH_KEY_SIZE) 72 #define PROV_SALT_LEN (NRF_MESH_KEY_SIZE) 74 #define PROV_NONCE_LEN (13) 76 #define PROV_CONFIRMATION_INPUT_LEN (17) 89 #define NRF_MESH_PROV_ALGORITHM_FIPS_P256EC (1u << 0) 95 #define NRF_MESH_PROV_OOB_PUBKEY_TYPE_INBAND (0) 97 #define NRF_MESH_PROV_OOB_PUBKEY_TYPE_OOB (1u << 0) 101 #define NRF_MESH_PROV_OOB_STATIC_TYPE_SUPPORTED (1u << 0) 104 #define NRF_MESH_PROV_OOB_OUTPUT_ACTION_BLINK (1u << 0) 106 #define NRF_MESH_PROV_OOB_OUTPUT_ACTION_BEEP (1u << 1) 108 #define NRF_MESH_PROV_OOB_OUTPUT_ACTION_VIBRATE (1u << 2) 110 #define NRF_MESH_PROV_OOB_OUTPUT_ACTION_NUMERIC (1u << 3) 112 #define NRF_MESH_PROV_OOB_OUTPUT_ACTION_ALPHANUMERIC (1u << 4) 115 #define NRF_MESH_PROV_OOB_INPUT_ACTION_PUSH (1u << 0) 117 #define NRF_MESH_PROV_OOB_INPUT_ACTION_TWIST (1u << 1) 119 #define NRF_MESH_PROV_OOB_INPUT_ACTION_ENTER_NUMBER (1u << 2) 121 #define NRF_MESH_PROV_OOB_INPUT_ACTION_ENTER_STRING (1u << 3) 133 #define NRF_MESH_PROV_OOB_INFO_SOURCE_OTHER (1u << 0) 134 #define NRF_MESH_PROV_OOB_INFO_SOURCE_ELECTRONIC_OR_URI (1u << 1) 135 #define NRF_MESH_PROV_OOB_INFO_SOURCE_2D_MACHINE_READABLE_CODE (1u << 2) 136 #define NRF_MESH_PROV_OOB_INFO_SOURCE_BAR_CODE (1u << 3) 137 #define NRF_MESH_PROV_OOB_INFO_SOURCE_NFC (1u << 4) 138 #define NRF_MESH_PROV_OOB_INFO_SOURCE_NUMBER (1u << 5) 139 #define NRF_MESH_PROV_OOB_INFO_SOURCE_STRING (1u << 6) 140 #define NRF_MESH_PROV_OOB_INFO_SOURCE_ON_BOX (1u << 11) 141 #define NRF_MESH_PROV_OOB_INFO_SOURCE_INSIDE_BOX (1u << 12) 142 #define NRF_MESH_PROV_OOB_INFO_SOURCE_ON_PIECE_OF_PAPER (1u << 13) 143 #define NRF_MESH_PROV_OOB_INFO_SOURCE_INSIDE_MANUAL (1u << 14) 144 #define NRF_MESH_PROV_OOB_INFO_SOURCE_ON_DEVICE (1u << 15) 232 typedef struct __attribute((packed))
277 typedef struct __attribute((packed))
288 struct __attribute((packed)) {
The device should vibrate as output action.
Start value of reserved for the future range.
The device will act as a provisioner, distributing provisioning data.
Start value of prohibited range.
Waiting for a provisioning start message.
Start value of reserved for the future range.
uint8_t key_refresh
Key refresh in progress flag.
#define NRF_MESH_KEY_SIZE
Size (in octets) of an encryption key.
Provisioning failed state.
uint8_t pubkey_type
Supported public key types.
uint8_t oob_input_size
Input OOB data size.
No authentication method.
Waiting for the peer node to send its public key.
Static OOB authentication method.
uint16_t oob_input_actions
Supported input OOB actions.
uint16_t algorithms
Supported authentication algorithms.
Waiting for a provisioning random message.
Waiting for the public key to be received by the peer.
nrf_mesh_prov_algorithm_t
The algorithm used for provisioning.
Output OOB authentication method.
An incoming provisioning packet had an invalid format.
uint8_t iv_update
IV update in progress flag.
The user should enter a string into the device as input action.
Common provisioning context forward declaration.
Waiting for the confirmation to be received by the peer.
The device should display a number as output action.
Waiting for a provisioning invitation message.
Waiting for an input complete message.
The user should enter a number into the device as input action.
nrf_mesh_prov_failure_code_t
Provisioning failure codes.
Waiting for the application to confirm the capabilities to use.
Idle state, no action is taken.
Input OOB authentication method.
The OOB authentication between provisioner and provisionee failed.
Waiting for static OOB data.
nrf_mesh_prov_role_t
Provisioning role.
The device should use blinking as output action.
Waiting for the message acknowledgement for the start message.
Waiting for a provisioning confirmation message.
nrf_mesh_prov_output_action_t
Enumeration for the OOB output actions.
The user should do a twist action as input action.
uint8_t num_elements
Number of elements in the device.
uint16_t netkey_index
Network key index.
The user should do a push action as input action.
Waiting for static OOB data, confirmation already received.
nrf_mesh_prov_input_action_t
Enumeration for the OOB input actions.
uint16_t oob_output_actions
Supported output OOB actions.
nrf_mesh_prov_oob_method_t
Out-of-band authentication methods for provisioning.
An invalid provisioning PDU was received.
Start value of prohibited range.
Provisioning authentication capabilities.
An unexpected error occured.
Waiting for a link to be established.
Start value of reserved for the future range.
Consecutive unicast addresses could not be assigned.
uint8_t oob_output_size
Output OOB data size.
uint16_t address
Unicast address for the device.
The provisioning data could not be decrypted.
nrf_mesh_prov_state_t
Provisioning state machine states.
The device should display an alpha-numberic value as output action.
The incoming packet was a different packet type than what was expected.
Waiting for the OOB public key to be retrieved.
FIPS P-256 Elliptic Curve.
Waiting for a provisioning capabilities message.
uint8_t oob_static_types
Supported static OOB types.
Provisioning data to transmit to a device.
nrf_mesh_prov_public_key_usage_t
The Public Key kind of usage.
Waiting for the offloaded ECDH calculation to complete.
Waiting for the provisioning data message.
The device will act as a provisionee, receiving provisioning data.
No OOB Public Key is used.
Waiting for the provisioning complete message.
Provisioning complete state.
uint32_t iv_index
IV_index value for the device, in little endian format.
The device should use beeping as output action.
The device does not have enough resources (memory, CPU time) to complete the provisioning.