diff options
author | Kozlov Dmitry <dima@server> | 2011-04-19 11:46:02 +0400 |
---|---|---|
committer | Kozlov Dmitry <dima@server> | 2011-04-19 11:46:02 +0400 |
commit | d4f6b13bcfb5c6245d39f5a71db199bac5a0a26f (patch) | |
tree | ee20fbbafece68ad38807e13652c2dd03d57d3e9 /accel-pppd/radius | |
parent | 859b328684c41f2ffdb0f14b0c480dad0075ef50 (diff) | |
download | accel-ppp-d4f6b13bcfb5c6245d39f5a71db199bac5a0a26f.tar.gz accel-ppp-d4f6b13bcfb5c6245d39f5a71db199bac5a0a26f.zip |
radius: auth_chap_md5: send chap challenge via CHAP-Challenge attribute too
Diffstat (limited to 'accel-pppd/radius')
-rw-r--r-- | accel-pppd/radius/auth.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/accel-pppd/radius/auth.c b/accel-pppd/radius/auth.c index 70ecbbe2..99e6e16d 100644 --- a/accel-pppd/radius/auth.c +++ b/accel-pppd/radius/auth.c @@ -253,20 +253,16 @@ int rad_auth_chap_md5(struct radius_pd_t *rpd, const char *username, va_list arg if (challenge_len == 16) memcpy(rpd->auth_req->RA, challenge, 16); - else { - if (rad_packet_add_octets(rpd->auth_req->pack, NULL, "CHAP-Challenge", challenge, challenge_len)) + if (rad_packet_add_octets(rpd->auth_req->pack, NULL, "CHAP-Challenge", challenge, challenge_len)) goto out; - } if (rad_packet_add_octets(rpd->auth_req->pack, NULL, "CHAP-Password", chap_password, 17)) goto out; } else { if (challenge_len == 16) memcpy(rpd->auth_req->RA, challenge, 16); - else { - if (rad_packet_change_octets(rpd->auth_req->pack, NULL, "CHAP-Challenge", challenge, challenge_len)) + if (rad_packet_change_octets(rpd->auth_req->pack, NULL, "CHAP-Challenge", challenge, challenge_len)) goto out; - } if (rad_packet_change_octets(rpd->auth_req->pack, NULL, "CHAP-Password", chap_password, 17)) goto out; |