Skip to content

Commit b0532e0

Browse files
committed
[nrf fromtree] bluetooth: mesh: zeroing not used part of auth array
Commit set zero to not used part of authentication array to prevent garbage from the previous provisioning using. Signed-off-by: Aleksandr Khromykh <[email protected]> (cherry picked from commit 760d190) Signed-off-by: Aleksandr Khromykh <[email protected]>
1 parent 3ffe117 commit b0532e0

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

subsys/bluetooth/mesh/prov.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,7 @@ int bt_mesh_input_string(const char *str)
293293
}
294294

295295
memcpy(bt_mesh_prov_link.auth, str, strlen(str));
296+
memset(bt_mesh_prov_link.auth + size, 0, sizeof(bt_mesh_prov_link.auth) - size);
296297

297298
bt_mesh_prov_link.role->input_complete();
298299

0 commit comments

Comments
 (0)