summaryrefslogtreecommitdiff
path: root/ot_accesslist.h
diff options
context:
space:
mode:
authorerdgeist <>2008-10-04 05:40:51 +0000
committererdgeist <>2008-10-04 05:40:51 +0000
commite534db03c6877f8ac0559f63840e9a00e9bd43bf (patch)
tree811181b9b39d0484e28eb25cbb9f2eea094978e2 /ot_accesslist.h
parent8cbfc8602c73e55770f3c06d8ea42758b22a0401 (diff)
added live sync code
added a config file parser added tracker id changed WANT_CLOSED_TRACKER and WANT_BLACKLIST into WANT_ACCESS_WHITE and WANT_ACCESS_BLACK changed WANT_TRACKER_SYNC to WANT_SYNC_BATCH and added WANT_SYNC_LIVE added an option to switch off fullscrapes cleaned up many internal hardcoded values, like PROTO_FLAG,
Diffstat (limited to 'ot_accesslist.h')
-rw-r--r--ot_accesslist.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/ot_accesslist.h b/ot_accesslist.h
index 6adefd9..2783b3c 100644
--- a/ot_accesslist.h
+++ b/ot_accesslist.h
@@ -6,14 +6,17 @@
6#ifndef __OT_ACCESSLIST_H__ 6#ifndef __OT_ACCESSLIST_H__
7#define __OT_ACCESSLIST_H__ 7#define __OT_ACCESSLIST_H__
8 8
9#if defined ( WANT_BLACKLISTING ) && defined (WANT_CLOSED_TRACKER ) 9#if defined ( WANT_ACCESSLIST_BLACK ) && defined (WANT_ACCESSLIST_WHITE )
10 #error WANT_BLACKLISTING and WANT_CLOSED_TRACKER are exclusive. 10 #error WANT_ACCESSLIST_BLACK and WANT_ACCESSLIST_WHITE are exclusive.
11#endif 11#endif
12 12
13#if defined ( WANT_BLACKLISTING ) || defined (WANT_CLOSED_TRACKER ) 13#if defined ( WANT_ACCESSLIST_BLACK ) || defined (WANT_ACCESSLIST_WHITE )
14#define WANT_ACCESS_CONTROL 14#define WANT_ACCESSLIST
15void accesslist_init( char *accesslist_filename ); 15void accesslist_init( );
16int accesslist_hashisvalid( ot_hash *hash ); 16int accesslist_hashisvalid( ot_hash *hash );
17
18extern char *g_accesslist_filename;
19
17#else 20#else
18#define accesslist_init( accesslist_filename ) 21#define accesslist_init( accesslist_filename )
19#define accesslist_hashisvalid( hash ) 1 22#define accesslist_hashisvalid( hash ) 1
@@ -22,7 +25,8 @@ int accesslist_hashisvalid( ot_hash *hash );
22typedef enum { 25typedef enum {
23 OT_PERMISSION_MAY_FULLSCRAPE, 26 OT_PERMISSION_MAY_FULLSCRAPE,
24 OT_PERMISSION_MAY_SYNC, 27 OT_PERMISSION_MAY_SYNC,
25 OT_PERMISSION_MAY_STAT 28 OT_PERMISSION_MAY_STAT,
29 OT_PERMISSION_MAY_LIVESYNC
26} ot_permissions; 30} ot_permissions;
27 31
28int accesslist_blessip( char * ip, ot_permissions permissions ); 32int accesslist_blessip( char * ip, ot_permissions permissions );