Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
net: lib: nrf_provisioning: Fix null pointer dereferencing
Since the nrf_provisioning_at_del_credential was overwriting the value of ret, there was a case when resp_sz becomes greater than AT_RESP_MAX_SIZE, put_at_resp() was called with resp pointing to NULL. This further lead to strlen() with NULL Pointer as input. This is now fixed by creating a separate variable for storing the return value of nrf_provisioning_at_del_credential. Found as violation of MITRE, CWE-476 by sonarcloud. Signed-off-by: Balaji Srinivasan <[email protected]>
- Loading branch information