summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bpf.h6
-rw-r--r--built_in.h9
-rw-r--r--colorize.h8
-rw-r--r--colors.h5
-rw-r--r--csum.h6
-rw-r--r--ct_servmgmt.h6
-rw-r--r--ct_usermgmt.h6
-rw-r--r--curvetun.h6
-rw-r--r--geoip.h6
-rw-r--r--hash.h8
-rw-r--r--ipv4.h7
-rw-r--r--ipv6.h7
-rw-r--r--locking.h6
-rw-r--r--mac80211.h6
-rw-r--r--oui.h6
-rw-r--r--protos.h6
-rw-r--r--tprintf.h11
-rw-r--r--trafgen_conf.h6
-rw-r--r--xmalloc.h6
19 files changed, 12 insertions, 115 deletions
diff --git a/bpf.h b/bpf.h
index 942f54e..4e5fd31 100644
--- a/bpf.h
+++ b/bpf.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2009, 2010 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef BPF_I_H
#define BPF_I_H
diff --git a/built_in.h b/built_in.h
index ea81257..1cca2d7 100644
--- a/built_in.h
+++ b/built_in.h
@@ -1,13 +1,8 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2009-2012 Daniel Borkmann.
- * Parts taken from the Linux kernel, GPL, version 2.
- * Subject to the GPL, version 2.
- */
-
#ifndef BUILT_IN_H
#define BUILT_IN_H
+/* Parts taken from the Linux kernel, GPL, version 2. */
+
#include <linux/if_packet.h>
#include <assert.h>
#include <endian.h>
diff --git a/colorize.h b/colorize.h
new file mode 100644
index 0000000..928deb2
--- /dev/null
+++ b/colorize.h
@@ -0,0 +1,8 @@
+#ifndef COLORIZE_H
+#define COLORIZE_H
+
+#define colorize_start(fore) "\033[" __##fore "m"
+#define colorize_start_full(fore, back) "\033[" __##fore ";" __on_##back "m"
+#define colorize_end() "\033[" __reset "m"
+
+#endif /* COLORIZE_H */
diff --git a/colors.h b/colors.h
index 7675583..ee4cd12 100644
--- a/colors.h
+++ b/colors.h
@@ -1,8 +1,3 @@
-/* netsniff-ng - the packet sniffing beast
- * Copyright 2009, 2010 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef COLORS_H
#define COLORS_H
diff --git a/csum.h b/csum.h
index fceef2c..cf4599a 100644
--- a/csum.h
+++ b/csum.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2010 Emmanuel Roullit.
- * Subject to the GPL, version 2.
- */
-
#ifndef CSUM_H
#define CSUM_H
diff --git a/ct_servmgmt.h b/ct_servmgmt.h
index 228a08a..9c5cd84 100644
--- a/ct_servmgmt.h
+++ b/ct_servmgmt.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2011 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef CT_SERVMGMT_H
#define CT_SERVMGMT_H
diff --git a/ct_usermgmt.h b/ct_usermgmt.h
index d7caae0..ff9d601 100644
--- a/ct_usermgmt.h
+++ b/ct_usermgmt.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2011 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef CT_USERMGMT_H
#define CT_USERMGMT_H
diff --git a/curvetun.h b/curvetun.h
index 76b2a8f..46a3d4b 100644
--- a/curvetun.h
+++ b/curvetun.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2011 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef CURVETUN_H
#define CURVETUN_H
diff --git a/geoip.h b/geoip.h
index 2098ef8..b6884e7 100644
--- a/geoip.h
+++ b/geoip.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2013 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef GEOIPH_H
#define GEOIPH_H
diff --git a/hash.h b/hash.h
index 8e26174..84c222a 100644
--- a/hash.h
+++ b/hash.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2009, 2010 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef HASH_H
#define HASH_H
@@ -83,4 +77,4 @@ static inline unsigned int hash_name(const char *name, int namelen)
return hash;
}
-#endif
+#endif /* HASH_H */
diff --git a/ipv4.h b/ipv4.h
index 98a1703..7004813 100644
--- a/ipv4.h
+++ b/ipv4.h
@@ -1,10 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright (C) 2009, 2010 Daniel Borkmann
- * Copyright (C) 2012 Christoph Jaeger <christoph@netsniff-ng.org>
- * Subject to the GPL, version 2.
- */
-
#ifndef IPV4_H
#define IPV4_H
diff --git a/ipv6.h b/ipv6.h
index a55a565..29e86a0 100644
--- a/ipv6.h
+++ b/ipv6.h
@@ -1,10 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright (C) 2009, 2010 Daniel Borkmann
- * Copyright (C) 2012 Christoph Jaeger <christoph@netsniff-ng.org>
- * Subject to the GPL, version 2.
- */
-
#ifndef IPV6_H
#define IPV6_H
diff --git a/locking.h b/locking.h
index 3d27939..95f1341 100644
--- a/locking.h
+++ b/locking.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2011 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef LOCKING_H
#define LOCKING_H
diff --git a/mac80211.h b/mac80211.h
index 9d340ac..7803625 100644
--- a/mac80211.h
+++ b/mac80211.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2012 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef MAC80211_H
#define MAC80211_H
diff --git a/oui.h b/oui.h
index 4ad616e..564e4a1 100644
--- a/oui.h
+++ b/oui.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2012 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef OUI_H
#define OUI_H
diff --git a/protos.h b/protos.h
index 127e1d3..23bf744 100644
--- a/protos.h
+++ b/protos.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2009, 2010 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef PROTOS_H
#define PROTOS_H
diff --git a/tprintf.h b/tprintf.h
index dc4349a..b2ca69e 100644
--- a/tprintf.h
+++ b/tprintf.h
@@ -1,14 +1,9 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2009, 2010 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef TPRINTF_H
#define TPRINTF_H
#include "built_in.h"
#include "colors.h"
+#include "colorize.h"
extern void tprintf_init(void);
extern void tprintf(char *msg, ...) __check_format_printf(1, 2);
@@ -18,10 +13,6 @@ extern void tprintf_cleanup(void);
extern void tputchar_safe(int c);
extern void tputs_safe(const char *str, size_t len);
-#define colorize_start(fore) "\033[" __##fore "m"
-#define colorize_start_full(fore, back) "\033[" __##fore ";" __on_##back "m"
-#define colorize_end() "\033[" __reset "m"
-
#define DEFAULT_TTY_SIZE 80
#endif /* TPRINTF_H */
diff --git a/trafgen_conf.h b/trafgen_conf.h
index 7281b59..f92e14c 100644
--- a/trafgen_conf.h
+++ b/trafgen_conf.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2009, 2010 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef TRAFGEN_CONF
#define TRAFGEN_CONF
diff --git a/xmalloc.h b/xmalloc.h
index 3285eb3..21ce84d 100644
--- a/xmalloc.h
+++ b/xmalloc.h
@@ -1,9 +1,3 @@
-/*
- * netsniff-ng - the packet sniffing beast
- * Copyright 2009, 2010 Daniel Borkmann.
- * Subject to the GPL, version 2.
- */
-
#ifndef XMALLOC_H
#define XMALLOC_H