Cumulative patch from commit 20ff2642e192437245422c9654463bcebf65b277
20ff264 WPS: Clear WPS data on init failure
f19e370 WPS: Do not advertise WPA/WPA2-Enterprise Auth Type Flags
1b5df9e nl80211: Do not indicate scan started event on scan_for_auth
bb23826 HS 2.0R2: Clean up debug log during exit path
48408fc HS 2.0R2: Do not mandate OCSP response for EST operations
8f60293 HS 2.0R2: Do not use OSU cert validation for EST
40bdcea HS 2.0R2: Configure OSU client trust root more consistently
4d65ded HS 2.0R2: Clean up debug from libcurl
Change-Id: I44aa20ac92abf03ea7b47f1ecad72dc07a0870d9
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
diff --git a/hs20/client/spp_client.c b/hs20/client/spp_client.c
index 8022ccb..302a050 100644
--- a/hs20/client/spp_client.c
+++ b/hs20/client/spp_client.c
@@ -1,6 +1,6 @@
/*
* Hotspot 2.0 SPP client
- * Copyright (c) 2012-2013, Qualcomm Atheros, Inc.
+ * Copyright (c) 2012-2014, Qualcomm Atheros, Inc.
*
* This software may be distributed under the terms of the BSD license.
* See README for more details.
@@ -776,7 +776,7 @@
void spp_sub_rem(struct hs20_osu_client *ctx, const char *address,
- const char *pps_fname, const char *ca_fname,
+ const char *pps_fname,
const char *client_cert, const char *client_key,
const char *cred_username, const char *cred_password,
xml_node_t *pps)
@@ -787,7 +787,7 @@
os_free(ctx->server_url);
ctx->server_url = os_strdup(address);
- if (soap_init_client(ctx->http, address, ca_fname,
+ if (soap_init_client(ctx->http, address, ctx->ca_fname,
cred_username, cred_password, client_cert,
client_key) == 0) {
spp_post_dev_data(ctx, SPP_SUBSCRIPTION_REMEDIATION,
@@ -923,7 +923,7 @@
void spp_pol_upd(struct hs20_osu_client *ctx, const char *address,
- const char *pps_fname, const char *ca_fname,
+ const char *pps_fname,
const char *client_cert, const char *client_key,
const char *cred_username, const char *cred_password,
xml_node_t *pps)
@@ -934,7 +934,7 @@
os_free(ctx->server_url);
ctx->server_url = os_strdup(address);
- if (soap_init_client(ctx->http, address, ca_fname, cred_username,
+ if (soap_init_client(ctx->http, address, ctx->ca_fname, cred_username,
cred_password, client_cert, client_key) == 0) {
spp_post_dev_data(ctx, SPP_POLICY_UPDATE, "Policy update",
pps_fname, pps);
@@ -942,14 +942,11 @@
}
-int cmd_prov(struct hs20_osu_client *ctx, const char *url,
- const char *ca_fname)
+int cmd_prov(struct hs20_osu_client *ctx, const char *url)
{
unlink("Cert/est_cert.der");
unlink("Cert/est_cert.pem");
- ctx->ca_fname = ca_fname;
-
if (url == NULL) {
wpa_printf(MSG_INFO, "Invalid prov command (missing URL)");
return -1;
@@ -960,8 +957,8 @@
os_free(ctx->server_url);
ctx->server_url = os_strdup(url);
- if (soap_init_client(ctx->http, url, ca_fname, NULL, NULL, NULL, NULL) <
- 0)
+ if (soap_init_client(ctx->http, url, ctx->ca_fname, NULL, NULL, NULL,
+ NULL) < 0)
return -1;
spp_post_dev_data(ctx, SPP_SUBSCRIPTION_REGISTRATION,
"Subscription registration", NULL, NULL);
@@ -970,11 +967,8 @@
}
-int cmd_sim_prov(struct hs20_osu_client *ctx, const char *url,
- const char *ca_fname)
+int cmd_sim_prov(struct hs20_osu_client *ctx, const char *url)
{
- ctx->ca_fname = ca_fname;
-
if (url == NULL) {
wpa_printf(MSG_INFO, "Invalid prov command (missing URL)");
return -1;
@@ -991,8 +985,8 @@
wpa_printf(MSG_INFO, "Could not get IP address for WLAN - try connection anyway");
}
- if (soap_init_client(ctx->http, url, ca_fname, NULL, NULL, NULL, NULL) <
- 0)
+ if (soap_init_client(ctx->http, url, ctx->ca_fname, NULL, NULL, NULL,
+ NULL) < 0)
return -1;
spp_post_dev_data(ctx, SPP_SUBSCRIPTION_REGISTRATION,
"Subscription provisioning", NULL, NULL);