1 #ifndef VSF_USERSIP_H
2 #define VSF_USERSIP_H
3 
4 #ifndef VSFTP_STR_H
5 #include "str.h"
6 #endif
7 struct vsf_session;
8 struct vsf_sysutil_sockaddr;
9 
10 typedef struct ip_rule * ip_rules;
11 
12 typedef struct ip_rule
13 {
14   struct mystr   p_user     ;
15   int            codepage   ;
16   struct vsf_sysutil_sockaddr* remote_ip  ;
17   struct vsf_sysutil_sockaddr* remote_mask;
18   ip_rules       prev       ;
19   ip_rules       next       ;
20 } ip_rule;
21 
22 void vsf_userip_load(const char* p_filename);
23 
24 int vsf_userip_check(const struct mystr* p_user,
25                      struct vsf_session* p_sess);
26 
27 void vsf_userip_free();
28 
29 #endif /* VSF_USERSIP_H */
30