wpa_supplicant(hidl): Send EAP identity as string
EAP identity is a string and not a vector of bytes that needs to be hex
encoded.
Bug: 35812320
Test: Verified connecting to new EAP sim networks. This would previusly
only work after a reboot (There is another path thru which this
identity is set in wpa_supplicant for existing networks)
Change-Id: I068f6f26a96e5c0a669445e711224638d876148d
diff --git a/wpa_supplicant/hidl/sta_network.cpp b/wpa_supplicant/hidl/sta_network.cpp
index b58d85b..e985994 100644
--- a/wpa_supplicant/hidl/sta_network.cpp
+++ b/wpa_supplicant/hidl/sta_network.cpp
@@ -1575,14 +1575,7 @@
const std::vector<uint8_t> &identity)
{
struct wpa_ssid *wpa_ssid = retrieveNetworkPtr();
- // Convert the incoming parameters to a string to pass to
- // wpa_supplicant.
- uint32_t identity_hex_len = identity.size() * 2 + 1;
- std::vector<char> identity_hex(identity_hex_len);
- wpa_snprintf_hex(
- identity_hex.data(), identity_hex.size(), identity.data(),
- identity.size());
- std::string ctrl_rsp_param = identity_hex.data();
+ std::string ctrl_rsp_param(identity.begin(), identity.end());
enum wpa_ctrl_req_type rtype = WPA_CTRL_REQ_EAP_IDENTITY;
struct wpa_supplicant *wpa_s = retrieveIfacePtr();
if (wpa_supplicant_ctrl_rsp_handle(