Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mbed-os-5.15: Add certificate remove before add to wisun tasklet #13736

Merged
merged 1 commit into from
Oct 22, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions features/nanostack/mbed-mesh-api/source/wisun_tasklet.c
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,7 @@ static void wisun_tasklet_configure_and_connect_to_network(void)
#else
trusted_cert.cert_len = strlen((const char *) MBED_CONF_MBED_MESH_API_ROOT_CERTIFICATE) + 1;
#endif
arm_network_trusted_certificates_remove();
arm_network_trusted_certificate_add((const arm_certificate_entry_s *)&trusted_cert);

arm_certificate_entry_s own_cert = {
Expand All @@ -308,6 +309,7 @@ static void wisun_tasklet_configure_and_connect_to_network(void)
#else
own_cert.key_len = strlen((const char *) MBED_CONF_MBED_MESH_API_OWN_CERTIFICATE_KEY) + 1;
#endif
arm_network_own_certificates_remove();
arm_network_own_certificate_add((const arm_certificate_entry_s *)&own_cert);
#endif

Expand Down