From b1d59d3eda7ee4f09b30f807d72aac2af58409ac Mon Sep 17 00:00:00 2001 From: Daniel Borkmann Date: Tue, 4 Jun 2013 11:58:51 +0200 Subject: stun: add header file Add a header file for stun functions. Signed-off-by: Daniel Borkmann --- curvetun.c | 3 +-- stun.c | 9 +-------- stun.h | 6 ++++++ 3 files changed, 8 insertions(+), 10 deletions(-) create mode 100644 stun.h diff --git a/curvetun.c b/curvetun.c index eb8bcde..00fcd2e 100644 --- a/curvetun.c +++ b/curvetun.c @@ -28,6 +28,7 @@ #include "die.h" #include "str.h" #include "sig.h" +#include "stun.h" #include "cookie.h" #include "ioexact.h" #include "xmalloc.h" @@ -44,8 +45,6 @@ #define CURVETUN_ENTROPY_SOURCE "/dev/random" -extern void print_stun_probe(char *server, uint16_t sport, uint16_t tunport); - enum working_mode { MODE_UNKNOW, MODE_KEYGEN, diff --git a/stun.c b/stun.c index 2389145..4ea4eac 100644 --- a/stun.c +++ b/stun.c @@ -1,9 +1,3 @@ -/* - * netsniff-ng - the packet sniffing beast - * Copyright 2011 Daniel Borkmann. - * Subject to the GPL, version 2. - */ - #include #include #include @@ -21,8 +15,7 @@ #include "xmalloc.h" #include "die.h" #include "sock.h" - -extern int print_stun_probe(char *server, int sport, int tport); +#include "stun.h" #define BINDING_REQUEST 0x0001 #define BINDING_RESPONSE 0x0101 diff --git a/stun.h b/stun.h new file mode 100644 index 0000000..e16c3e7 --- /dev/null +++ b/stun.h @@ -0,0 +1,6 @@ +#ifndef STUN_H +#define STUN_H + +extern int print_stun_probe(char *server, int sport, int tport); + +#endif /* STUN_H */ -- cgit v1.2.3-54-g00ecf