diff options
author | Guillaume Nault <g.nault@alphalink.fr> | 2013-02-13 13:48:42 +0100 |
---|---|---|
committer | Kozlov Dmitry <xeb@mail.ru> | 2013-02-13 17:24:02 +0400 |
commit | 2e1caa1445b51000bc3695b0f55753f533468839 (patch) | |
tree | 7263f45e6853a2d7b422685a3fcdb14651683d57 /accel-pppd/ctrl/l2tp/l2tp.c | |
parent | 5b5ad37253aa102d37931cf955042096721195b5 (diff) | |
download | accel-ppp-xebd-2e1caa1445b51000bc3695b0f55753f533468839.tar.gz accel-ppp-xebd-2e1caa1445b51000bc3695b0f55753f533468839.zip |
l2tp: Fix challenge response with no secret
Don't call strlen() if conf_secret is NULL.
Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
Diffstat (limited to 'accel-pppd/ctrl/l2tp/l2tp.c')
-rw-r--r-- | accel-pppd/ctrl/l2tp/l2tp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/accel-pppd/ctrl/l2tp/l2tp.c b/accel-pppd/ctrl/l2tp/l2tp.c index 4b3e742..7e990d0 100644 --- a/accel-pppd/ctrl/l2tp/l2tp.c +++ b/accel-pppd/ctrl/l2tp/l2tp.c @@ -326,7 +326,7 @@ static int l2tp_tunnel_genchallresp(uint8_t msgident, uint8_t challresp[MD5_DIGEST_LENGTH]; if (conn->challenge == NULL) { - if (conf_secret || strlen(conf_secret) > 0) { + if (conf_secret && strlen(conf_secret) > 0) { l2tp_conn_log(log_warn, conn); log_warn("l2tp: No Challenge sent by peer\n"); } |