-extern char *hostlookup(unsigned long);
-extern ipv4_t str2address(char*);
-extern char *address2str(ipv4_t);
-
-#endif /* __TINC_NETUTL_H__ */
+extern bool hostnames;
+
+extern struct addrinfo *str2addrinfo(const char *, const char *, int);
+extern sockaddr_t str2sockaddr(const char *, const char *);
+extern void sockaddr2str(const sockaddr_t *, char **, char **);
+extern char *sockaddr2hostname(const sockaddr_t *);
+extern int sockaddrcmp(const sockaddr_t *, const sockaddr_t *);
+extern int sockaddrcmp_noport(const sockaddr_t *, const sockaddr_t *);
+extern void sockaddrunmap(sockaddr_t *);
+extern void sockaddrfree(sockaddr_t *);
+extern void sockaddrcpy(sockaddr_t *, const sockaddr_t *);
+extern void sockaddr_setport(sockaddr_t *, const char *);
+extern int maskcmp(const void *, const void *, int);
+extern void maskcpy(void *, const void *, int, int);
+extern void mask(void *, int, int);
+extern bool maskcheck(const void *, int, int);
+
+#endif /* __TINC_NETUTL_H__ */