X-Git-Url: http://git.sameswireless.fr/l2tpns.git/blobdiff_plain/31e24f76ce50885c9f51ca9a5ea8836a087afa84..ea91ab45621499ae7949178297d9da6d37b0e4e0:/radius.c diff --git a/radius.c b/radius.c index 8c7bf64..6cb9e16 100644 --- a/radius.c +++ b/radius.c @@ -1,6 +1,6 @@ // L2TPNS Radius Stuff -char const *cvs_id_radius = "$Id: radius.c,v 1.46 2005/12/09 00:43:17 bodea Exp $"; +char const *cvs_id_radius = "$Id: radius.c,v 1.47 2005/12/19 06:18:13 bodea Exp $"; #include #include @@ -314,10 +314,20 @@ void radiussend(uint16_t r, uint8_t state) } if (s) { - *p = 5; // NAS-Port + *p = 5; // NAS-Port p[1] = 6; *(uint32_t *) (p + 2) = htonl(s); p += p[1]; + + *p = 6; // Service-Type + p[1] = 6; + *(uint32_t *) (p + 2) = htonl(2); // Framed-User + p += p[1]; + + *p = 7; // Framed-Protocol + p[1] = 6; + *(uint32_t *) (p + 2) = htonl(1); // PPP + p += p[1]; } if (s && session[s].ip) {