1 |
#ifndef NEGCACHE_H |
2 |
#define NEGCACHE_H |
3 |
|
4 |
struct cnode |
5 |
{ |
6 |
unsigned long ip; /* IP address, network byte order. */ |
7 |
time_t seen; /* When it was last seen. */ |
8 |
unsigned int b; /* Index of bit to be tested. */ |
9 |
struct cnode *l; /* Node to the left. */ |
10 |
struct cnode *r; /* Node to the right. */ |
11 |
}; |
12 |
|
13 |
extern struct cnode *nc_head; |
14 |
extern void nc_init(struct cnode **); |
15 |
extern struct cnode *check_neg_cache(const unsigned long); |
16 |
extern void negcache_insert(const char *); |
17 |
extern void negcache_rebuild(void); |
18 |
#endif |