diff --git a/src/ipaddr.h b/src/ipaddr.h new file mode 100644 index 0000000..dbc2c30 --- /dev/null +++ b/src/ipaddr.h @@ -0,0 +1,19 @@ +#ifndef F2B_IPADDR_H_ +#define F2B_IPADDR_H_ + +#include + +#include "matches.h" + +typedef struct { + struct f2b_ipaddr_t *next; + char text[40]; /* 8 x "ffff" + 7 x ":" + '\0' */ + int addr_type; + union { + struct in_addr v4; + struct in6_addr v6; + } binary; + f2b_matches_t matches; +} f2b_ipaddr_t; + +#endif /* F2B_IPADDR_H_ */ diff --git a/src/match.h b/src/match.h deleted file mode 100644 index 8f83452..0000000 --- a/src/match.h +++ /dev/null @@ -1,10 +0,0 @@ -#ifndef F2B_MATCH_H_ -#define F2B_MATCH_H_ - -typedef struct { - struct f2b_match_t *next; - char ip[40]; /* 8 x "ffff" + 7 x ":" + '\0' */ - time_t seen; -} f2b_match_t; - -#endif /* F2B_MATCH_H_ */