mirror of
https://github.com/strongswan/strongswan.git
synced 2025-10-07 00:01:49 -04:00
Fix null-terminated XAuth passwords, as sent by Android 4
This commit is contained in:
parent
83d77866f4
commit
3110744a6b
@ -217,6 +217,10 @@ METHOD(xauth_method_t, process, status_t,
|
|||||||
this->peer->destroy(this->peer);
|
this->peer->destroy(this->peer);
|
||||||
this->peer = id;
|
this->peer = id;
|
||||||
}
|
}
|
||||||
|
if (pass.len && pass.ptr[pass.len - 1] == 0)
|
||||||
|
{ /* fix null-terminated passwords (Android etc.) */
|
||||||
|
pass.len -= 1;
|
||||||
|
}
|
||||||
|
|
||||||
name = lib->settings->get_str(lib->settings,
|
name = lib->settings->get_str(lib->settings,
|
||||||
"charon.plugins.xauth-eap.backend", "radius");
|
"charon.plugins.xauth-eap.backend", "radius");
|
||||||
|
@ -136,6 +136,10 @@ METHOD(xauth_method_t, process_server, status_t,
|
|||||||
this->peer->destroy(this->peer);
|
this->peer->destroy(this->peer);
|
||||||
this->peer = id;
|
this->peer = id;
|
||||||
}
|
}
|
||||||
|
if (pass.len && pass.ptr[pass.len - 1] == 0)
|
||||||
|
{ /* fix null-terminated passwords (Android etc.) */
|
||||||
|
pass.len -= 1;
|
||||||
|
}
|
||||||
|
|
||||||
enumerator = lib->credmgr->create_shared_enumerator(lib->credmgr,
|
enumerator = lib->credmgr->create_shared_enumerator(lib->credmgr,
|
||||||
SHARED_EAP, this->server, this->peer);
|
SHARED_EAP, this->server, this->peer);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user