path: root/include
diff options
authorFlorian Westphal <>2018-11-03 23:43:49 +0100
committerFlorian Westphal <>2018-11-07 20:08:15 +0100
commit7bd9febf65e98eb1f4b4d51afa2479c442066235 (patch)
tree016e65d6e7fc85cda5baa28837e8e0f2c2c93240 /include
parenta10eb8861c8fdc8894a8c2f6baf4dd791d5ab4f0 (diff)
libxtables: add and use mac print helpers
This changes ebtables-nft to consistently print mac address with two characters, i.e. 00:01:02:03:04:0a, not 0:1:2:3:4:a. Will require another bump of vcurrent/vage. Suggested-by: Pablo Neira Ayuso <> Signed-off-by: Florian Westphal <>
Diffstat (limited to 'include')
1 files changed, 3 insertions, 0 deletions
diff --git a/include/xtables.h b/include/xtables.h
index 8fb8843a..2bc190cd 100644
--- a/include/xtables.h
+++ b/include/xtables.h
@@ -556,6 +556,9 @@ extern void xtables_save_string(const char *value);
#define FMT(tab,notab) ((format) & FMT_NOTABLE ? (notab) : (tab))
extern void xtables_print_num(uint64_t number, unsigned int format);
+extern void xtables_print_mac(const unsigned char *macaddress);
+extern void xtables_print_mac_and_mask(const unsigned char *mac,
+ const unsigned char *mask);
extern void xtables_parse_val_mask(struct xt_option_call *cb,
unsigned int *val, unsigned int *mask,