Hello,
i ran nRF Coap Client and it worked pretty well.
I am working with nRF9160 DK.
Now, I want to add DTLS to this example to secure the data.
Can someone please help me or is there any tutorials on how to do that?
Best regards,
Cedric
Hello,
i ran nRF Coap Client and it worked pretty well.
I am working with nRF9160 DK.
Now, I want to add DTLS to this example to secure the data.
Can someone please help me or is there any tutorials on how to do that?
Best regards,
Cedric
ced27 said:Actually i am having problems with DTLS connection
The device initiates the DTLS handshake with a "Client Hello", which is correct.
The problem appears to be the destination, which is 0.0.0.0. Which server/IP address are you trying to connect to? What is CONFIG_SERVER_ADRESS defined as?
static int server_initialisieren(void) { struct sockaddr_in *server4 = ((struct sockaddr_in *)&server); // Socket-Adressstruktur für IPv4 server4->sin_family = AF_INET; // AF_INET = IP Protokoll Version 4 (IPv4) server4->sin_port = htons(CONFIG_SERVER_PORT); //Schreibe Port in Network-Byte-Order in das Feld sin_port inet_pton(AF_INET, CONFIG_SERVER_ADDRESS, &server4->sin_addr); // Schreibe IP-Adresse des Servers in die sockaddr_in-Struktur return 0; }
Regards,
Markus
ced27 said:Actually i am having problems with DTLS connection
The device initiates the DTLS handshake with a "Client Hello", which is correct.
The problem appears to be the destination, which is 0.0.0.0. Which server/IP address are you trying to connect to? What is CONFIG_SERVER_ADRESS defined as?
static int server_initialisieren(void) { struct sockaddr_in *server4 = ((struct sockaddr_in *)&server); // Socket-Adressstruktur für IPv4 server4->sin_family = AF_INET; // AF_INET = IP Protokoll Version 4 (IPv4) server4->sin_port = htons(CONFIG_SERVER_PORT); //Schreibe Port in Network-Byte-Order in das Feld sin_port inet_pton(AF_INET, CONFIG_SERVER_ADDRESS, &server4->sin_addr); // Schreibe IP-Adresse des Servers in die sockaddr_in-Struktur return 0; }
Regards,
Markus
The problem appears to be the destination, which is 0.0.0.0. Which server/IP address are you trying to connect to? What is CONFIG_SERVER_ADRESS defined as?
CONFIG_SERVER_ADRESS is "californium.eclipseprojects.io" and the IP address is 35.185.40.182