diff --git a/ppp.c b/ppp.c index ac244a9..f34a646 100644 --- a/ppp.c +++ b/ppp.c @@ -899,7 +899,7 @@ void processlcp(sessionidt s, tunnelidt t, uint8_t *p, uint16_t l) LOG(3, s, t, " Remote requested PAP authentication...%sing\n", authtype ? "accept" : "reject"); } - else if (proto == PPPCHAP && length > 4 && *(o + 4) == 5) + else if (proto == PPPCHAP && (length == 4 || (length > 4 && *(o + 4) == 5))) { authtype = config->radius_authtypes & AUTHCHAP; LOG(3, s, t, " Remote requested CHAP authentication...%sing\n",