169 #include "liblwm2m.h" 
  183 #define LWM2M_SECURITY_MODE_PRE_SHARED_KEY  0 
  188 #define LWM2M_SECURITY_MODE_RAW_PUBLIC_KEY  1 
  193 #define LWM2M_SECURITY_MODE_CERTIFICATE     2 
  198 #define LWM2M_SECURITY_MODE_NONE            3 
  208 #define LWM2M_SECURITY_URI_ID                 0 
  213 #define LWM2M_SECURITY_BOOTSTRAP_ID           1 
  218 #define LWM2M_SECURITY_SECURITY_ID            2 
  223 #define LWM2M_SECURITY_PUBLIC_KEY_ID          3 
  228 #define LWM2M_SECURITY_SERVER_PUBLIC_KEY_ID   4 
  233 #define LWM2M_SECURITY_SECRET_KEY_ID          5 
  238 #define LWM2M_SECURITY_SMS_SECURITY_ID        6 
  243 #define LWM2M_SECURITY_SMS_KEY_PARAM_ID       7 
  248 #define LWM2M_SECURITY_SMS_SECRET_KEY_ID      8 
  253 #define LWM2M_SECURITY_SMS_SERVER_NUMBER_ID   9 
  258 #define LWM2M_SECURITY_SHORT_SERVER_ID        10 
  263 #define LWM2M_SECURITY_HOLD_OFF_ID            11 
  268 #define LWM2M_SECURITY_BOOTSTRAP_TIMEOUT_ID   12 
  280 #ifndef CONFIG_LWM2M_OBJ_SECURITY_INSTANCES_MAX 
  281 #define CONFIG_LWM2M_OBJ_SECURITY_INSTANCES_MAX              (2) 
  287 #ifndef CONFIG_LWM2M_OBJ_SECURITY_PUB_KEY_ID_BUFSIZE 
  288 #define CONFIG_LWM2M_OBJ_SECURITY_PUB_KEY_ID_BUFSIZE         (128) 
  294 #ifndef CONFIG_LWM2M_OBJ_SECURITY_SERVER_PUB_KEY_BUFSIZE 
  295 #define CONFIG_LWM2M_OBJ_SECURITY_SERVER_PUB_KEY_BUFSIZE     (128) 
  301 #ifndef CONFIG_LWM2M_OBJ_SECURITY_SEC_KEY_BUFSIZE 
  302 #define CONFIG_LWM2M_OBJ_SECURITY_SEC_KEY_BUFSIZE            (64) 
  415                                           int32_t instance_id);
 
POSIX.1-2008 compliant version of the assert macro.
 
(D)TLS credentials management module definitions
 
credman_tag_t lwm2m_object_security_get_credential(uint16_t instance_id)
Get the credential of a given instance of the security object.
 
struct lwm2m_obj_security_args lwm2m_obj_security_args_t
Arguments for a new Security object instance creation (lwm2m_object_security_instance_create).
 
lwm2m_object_t * lwm2m_object_security_init(lwm2m_client_data_t *client_data)
Initialize the Security object.
 
int lwm2m_object_security_instance_create(const lwm2m_obj_security_args_t *args, int32_t instance_id)
Create a new Security instance and add it to the object list.
 
uint16_t credman_tag_t
Tag of the credential.
 
Definitions and public API for a LwM2M client using Wakaama.
 
LwM2M client configurations.
 
Arguments for a new Security object instance creation (lwm2m_object_security_instance_create).
 
const uint8_t * pub_key_or_id
Pointer to the Key ID when using LWM2M_SECURITY_MODE_PRE_SHARED_KEY.
 
uint16_t server_id
Server's short ID the instance is associated to.
 
const uint8_t * server_pub_key
Pointer to the server public key encoded as a SubjectPublicKeyInfo sequence when using LWM2M_SECURITY...
 
size_t secret_key_len
Length of lwm2m_obj_security_args_t::secret_key.
 
const char * server_uri
Server's URI the instance is associated to.
 
bool is_bootstrap
When true the security instance is associated to the Bootstrap-Server.
 
uint8_t security_mode
Security mode to use.
 
size_t pub_key_or_id_len
Length of lwm2m_obj_security_args_t::pub_key_or_id.
 
const uint8_t * secret_key
Pointer to the Key when using LWM2M_SECURITY_MODE_PRE_SHARED_KEY.
 
uint32_t client_hold_off_time
Time, in seconds, to wait before initiating a 'Client Initiated Bootstrap', after it has been determi...
 
uint32_t bootstrap_account_timeout
Time, in seconds, that the client waits before it purges the Bootstrap-Server's account.
 
size_t server_pub_key_len
Length of lwm2m_obj_security_args_t::server_pub_key.