20 #ifndef OC_CRED_COMMON_H
21 #define OC_CRED_COMMON_H
25 #include "util/oc_list.h"
39 OC_CREDTYPE_OSCORE = 64,
40 OC_CREDTYPE_OSCORE_MCAST_CLIENT = 128,
41 OC_CREDTYPE_OSCORE_MCAST_SERVER = 256
struct oc_cred_data_t oc_cred_data_t
credential data info
oc_sec_credtype_t
credential type information
@ OC_CREDTYPE_NULL
no credential
@ OC_CREDTYPE_PSK
PSK (personal)
oc_sec_encoding_t
Security encoding information.
@ OC_ENCODING_PEM
oic.sec.encoding.pem
@ OC_ENCODING_UNSUPPORTED
not supported
@ OC_ENCODING_BASE64
oic.sec.encoding.base64
@ OC_ENCODING_RAW
oic.sec.encoding.raw
@ OC_ENCODING_HANDLE
oic.sec.encoding.handle – Data is contained in a storage sub-system referenced using a handle
oc_sec_credusage_t oc_cred_parse_credusage(oc_string_t *credusage_string)
parse credential string to type
oc_sec_encoding_t oc_cred_parse_encoding(oc_string_t *encoding_string)
parse credential encoding string to type
struct oc_sec_cred_t oc_sec_cred_t
security credential information
const char * oc_cred_read_credusage(oc_sec_credusage_t credusage)
read credential usage
struct oc_sec_creds_t oc_sec_creds_t
credential and rowner information
const char * oc_cred_read_encoding(oc_sec_encoding_t encoding)
read credential encoding
oc_sec_credusage_t
credential usage
@ OC_CREDUSAGE_TRUSTCA
trust anchor oic.sec.cred.trustca
@ OC_CREDUSAGE_MFG_TRUSTCA
Manufacturer Trust CA oic.sec.cred.mfgtrustca.
@ OC_CREDUSAGE_NULL
no usage
@ OC_CREDUSAGE_IDENTITY_CERT
Certificate oic.sec.cred.cert.
@ OC_CREDUSAGE_MFG_CERT
Manufacturer CA oic.sec.cred.mfgcert.
@ OC_CREDUSAGE_ROLE_CERT
Role Certificate oic.sec.cred.rolecert.
const char * oc_cred_credtype_string(oc_sec_credtype_t credtype)
credential type to string
uuid implementationGenerate and work with UUIDs as specified in RFC 4122.
oc_string_t data
the credential data
oc_sec_encoding_t encoding
the encoding of the credential data
security credential information
oc_string_t authority
authority
void * ctx
security context
oc_cred_data_t privatedata
private data
struct oc_sec_cred_t * chain
chain of credentials
oc_cred_data_t publicdata
public data
struct oc_sec_cred_t * next
pointer to the next credential
oc_uuid_t subjectuuid
subject uuid
oc_sec_credtype_t credtype
credential type
oc_sec_credusage_t credusage
credential usage
struct oc_sec_cred_t * child
credential child
credential and rowner information
OC_LIST_STRUCT(creds)
list of credentials
oc_uuid_t rowneruuid
row owner uuid