From f35d79a22b442ab15ab1e46e64be676745b030fd Mon Sep 17 00:00:00 2001 From: gaurank kathpalia Date: Fri, 8 Mar 2019 13:36:11 +0530 Subject: [PATCH] qcacmn: Clear Key information from driver memory after disconnect Currently the key information i.e the key, and the number of keys are not getting cleared on wifi link disconnection from wifi driver memory, which can lead to information disclosure. Clear the key information i.e the number of keys and keys from wifi driver memory to avoid any potential information disclore after wifi is turned off. Change-Id: I2a3ea56d4e876b48dd7a5e456ed7d139600fab01 CRs-Fixed: 2415421 --- wmi/src/wmi_unified_tlv.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/wmi/src/wmi_unified_tlv.c b/wmi/src/wmi_unified_tlv.c index cd1400b8c2..65f3d173de 100644 --- a/wmi/src/wmi_unified_tlv.c +++ b/wmi/src/wmi_unified_tlv.c @@ -3873,9 +3873,10 @@ static QDF_STATUS send_setup_install_key_cmd_tlv(wmi_unified_t wmi_handle, wmi_mtrace(WMI_VDEV_INSTALL_KEY_CMDID, cmd->vdev_id, 0); status = wmi_unified_cmd_send(wmi_handle, buf, len, WMI_VDEV_INSTALL_KEY_CMDID); - if (QDF_IS_STATUS_ERROR(status)) + if (QDF_IS_STATUS_ERROR(status)) { + qdf_mem_zero(wmi_buf_data(buf), len); wmi_buf_free(buf); - + } return status; }