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 = 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,
|
||||
"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 = 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,
|
||||
SHARED_EAP, this->server, this->peer);
|
||||
|
|
Loading…
Reference in New Issue