coap_tinydtls.c: Add in PKI stub functions

Update #includes and add in stub functions
coap_dtls_context_set_pki
coap_dtls_context_set_psk
coap_dtls_context_check_keys_enabled
This commit is contained in:
Jon Shallow committed 2018-02-12 09:50:32 +00:00
1 parent 6d479ee6cb
commit aaa43301b7
1 file changed
+20 -1
+20 -1
View File
@@ -11,10 +11,10 @@
#ifdef HAVE_LIBTINYDTLS
#include "net.h"
#include "address.h"
#include "debug.h"
#include "mem.h"
#include "coap_dtls.h"
#include <tinydtls.h>
#include <dtls.h>
@@ -444,6 +444,25 @@ int coap_tls_is_supported(void) {
return 0;
}
int coap_dtls_context_set_pki( coap_context_t *ctx UNUSED,
coap_dtls_security_setup_t setup_callback UNUSED,
coap_dtls_pki_t* setup_data UNUSED
) {
return 0;
}
int coap_dtls_context_set_psk(coap_context_t *ctx UNUSED,
const char *hint UNUSED,
const uint8_t *key UNUSED, size_t key_len UNUSED
) {
return 1;
}
int coap_dtls_context_check_keys_enabled(coap_context_t *ctx)
{
return 1;
}
void *coap_tls_new_client_session(coap_session_t *session UNUSED, int *connected UNUSED) {
return NULL;
}