projects
/
l2tpns.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add "allow_duplicate_users" config option
[l2tpns.git]
/
radius.c
diff --git
a/radius.c
b/radius.c
index
5d94720
..
d046d28
100644
(file)
--- a/
radius.c
+++ b/
radius.c
@@
-1,6
+1,6
@@
// L2TPNS Radius Stuff
// L2TPNS Radius Stuff
-char const *cvs_id_radius = "$Id: radius.c,v 1.
29 2005/05/05 10:02:08
bodea Exp $";
+char const *cvs_id_radius = "$Id: radius.c,v 1.
31 2005/05/16 04:51:16
bodea Exp $";
#include <time.h>
#include <stdio.h>
#include <time.h>
#include <stdio.h>
@@
-91,6
+91,8
@@
uint16_t radiusnew(sessionidt s)
radius[r].state = RADIUSWAIT;
radius[r].retry = TIME + 1200; // Wait at least 120 seconds to re-claim this.
radius[r].state = RADIUSWAIT;
radius[r].retry = TIME + 1200; // Wait at least 120 seconds to re-claim this.
+ random_data(radius[r].auth, sizeof(radius[r].auth));
+
LOG(3, s, session[s].tunnel, "Allocated radius %d\n", r);
return r;
}
LOG(3, s, session[s].tunnel, "Allocated radius %d\n", r);
return r;
}
@@
-161,12
+163,12
@@
void radiussend(uint16_t r, uint8_t state)
switch (state)
{
case RADIUSAUTH:
switch (state)
{
case RADIUSAUTH:
- b[0] =
1
; // access request
+ b[0] =
AccessRequest
; // access request
break;
case RADIUSSTART:
case RADIUSSTOP:
case RADIUSINTERIM:
break;
case RADIUSSTART:
case RADIUSSTOP:
case RADIUSINTERIM:
- b[0] =
4
; // accounting request
+ b[0] =
AccountingRequest
; // accounting request
break;
default:
LOG(0, 0, 0, "Unknown radius state %d\n", state);
break;
default:
LOG(0, 0, 0, "Unknown radius state %d\n", state);