Changeset 67
- Timestamp:
- 04/14/04 21:48:57 (5 years ago)
- Files:
-
- trunk/wifidog/ChangeLog (modified) (1 diff)
- trunk/wifidog/src/auth.c (modified) (1 diff)
- trunk/wifidog/src/firewall.c (modified) (1 diff)
- trunk/wifidog/src/userclasses.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/wifidog/ChangeLog
r65 r67 1 1 # $Header$ 2 2004-04-14 Alexandre Carmel-Veilleux <acv@acv.ca> 3 * Fixed clean up so it happens at the right time. 4 2 5 2004-04-14 Alexandre Carmel-Veilleux <acv@acv.ca> 3 6 * Major retooling of insert_userclass(), fixed seg fault. trunk/wifidog/src/auth.c
r65 r67 104 104 tmp_ur->profile = profile; 105 105 tmp_ur->start_time = time(NULL); 106 tmp_ur->last_checked = time(NULL); 106 107 tmp_ur->end_time = tmp_ur->start_time + (time_t)tmp_uc->timeout; 107 108 trunk/wifidog/src/firewall.c
r64 r67 206 206 207 207 p1 = node_find_by_ip(ip); 208 if (!(p1) || !(p1->active)) { 208 if (!(p1) || !(p1->active) || 209 (p1->rights->last_checked + 210 (config.checkinterval * 211 config.clienttimeout)) > time(NULL)) { 209 212 debug(D_LOG_DEBUG, "Client %s not " 210 213 "active", ip); 211 214 } else { 215 p1->rights->last_checked = time(NULL); 212 216 p1->counter = counter; 213 217 trunk/wifidog/src/userclasses.h
r45 r67 39 39 typedef struct _user_rights { 40 40 int profile; /* keyed to a global profile */ 41 time_t start_time; /* when connection started */ 42 time_t end_time; /* start_time + timeout */ 41 time_t start_time, /* when connection started */ 42 end_time, /* start_time + timeout */ 43 last_checked; /* time of last check */ 43 44 } UserRights; 44 45
