aboutsummaryrefslogtreecommitdiffstats
path: root/src/eap_peer
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2008-11-29 19:07:35 (GMT)
committerJouni Malinen <j@w1.fi>2008-11-29 19:07:35 (GMT)
commit23f53f2a8174ddae48c54c2df98e5362144bdffb (patch)
tree8f7eff4d650838d61574a7d95650dc39c2906dbd /src/eap_peer
parent728fae16319c604006476ff46c5f1e3845df005f (diff)
downloadhostap-06-23f53f2a8174ddae48c54c2df98e5362144bdffb.zip
hostap-06-23f53f2a8174ddae48c54c2df98e5362144bdffb.tar.gz
hostap-06-23f53f2a8174ddae48c54c2df98e5362144bdffb.tar.bz2
WPS: Get AP PIN from configuration instead of using hardcoded value
Diffstat (limited to 'src/eap_peer')
-rw-r--r--src/eap_peer/eap_wsc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/eap_peer/eap_wsc.c b/src/eap_peer/eap_wsc.c
index 2cf52f8..b1a29b0 100644
--- a/src/eap_peer/eap_wsc.c
+++ b/src/eap_peer/eap_wsc.c
@@ -207,8 +207,10 @@ static void * eap_wsc_init(struct eap_sm *sm)
"yet fully supported - using test values");
u8 uuid_e[UUID_LEN];
os_memset(uuid_e, 0, UUID_LEN);
- wps_registrar_add_pin(data->wps_ctx->registrar, uuid_e,
- (const u8 *) "12345670", 8);
+ if (cfg.pin) {
+ wps_registrar_add_pin(data->wps_ctx->registrar, uuid_e,
+ cfg.pin, cfg.pin_len);
+ }
}
return data;