12 #include <openssl/ssl.h>
13 #include <openssl/rand.h>
14 #include <openssl/err.h>
18 #define ALARM_TIME 240
20 static inline unsigned admin(const char *ident
, const char *host
)
24 return !strcmp(host
, "equestria") || // un1c0rn
25 !strcmp(host
, "friendship.sgu.equ") || // robomint
26 !strcmp(host
, "genres.i.dont.even") || // z0r8
27 !strcmp(host
, "unaffiliated/apologue") || // foxeee
28 !strcmp(host
, "The.Gambler") || // Hope
29 !strcmp(host
, "HaveConviction-WillTravel") || // Hope
30 !strcmp(host
, "unaffiliated/metool") || // Hope
31 !strcmp(host
, "Metool.user.gamesurge") || // Hope
32 (!strcmp(ident
, "sid18823") && strstr(host
, "gateway/web/irccloud.com/")) || // Hope
33 !strcmp(host
, "who.needs.pants.anyway") || // foxie
34 !strcmp(host
, "assassin.for.hire") || // foxie
35 !strcmp(host
, "bookworm.extraordinaire") || // foxie
36 !strcmp(host
, "the_Library") || // Foxie canternet
37 !strcmp(host
, "sweetie.belle") || // self
38 strcasestr(host
, owner
); // un1c0rn on other network
42 void (*writeline
)(struct bio
*b
, const char *fmt
, ...)
43 __attribute__ ((__format__ (__printf__
, 2, 3)));
44 int (*fill
)(struct bio
*b
);
45 int (*readline
)(struct bio
*b
, char **line
);
46 int (*poll
)(struct bio
*b
, int timeout
);
48 int fd
, maxlen
, len
, ofs
;
53 void init_hook(struct bio
*b
, const char *target
, const char *self
, unsigned ponify
);
55 void privmsg_hook(struct bio
*b
, const char *prefix
, const char *ident
, const char *host
,
56 const char *const *args
, unsigned nargs
);
58 void command_hook(struct bio
*b
, const char *prefix
, const char *ident
, const char *host
,
59 const char *command
, const char *const *args
, unsigned nargs
);