From 7f0c823d1ec0dcb1967a568c204ca238529a3921 Mon Sep 17 00:00:00 2001 From: Christoph Neukirch Date: Wed, 18 Sep 2024 12:52:23 +0200 Subject: [PATCH 1/2] reworked field regex to: * work with - in field name * work with IPv6 addresses starting after \s --- colourfiles/conf.whois | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/colourfiles/conf.whois b/colourfiles/conf.whois index 89f3d0c..93de62b 100644 --- a/colourfiles/conf.whois +++ b/colourfiles/conf.whois @@ -1,5 +1,5 @@ # field -regexp=^([\w\s])*: +regexp=^\s*([\w\s-])*:(?=\s|$) colours=bold white ======= # data From 3af8d5d9129f3ff1289c25cc4c0afd4e041d00b6 Mon Sep 17 00:00:00 2001 From: Christoph Neukirch Date: Wed, 18 Sep 2024 14:10:13 +0200 Subject: [PATCH 2/2] add support for IPv4 and IPv6 --- colourfiles/conf.whois | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/colourfiles/conf.whois b/colourfiles/conf.whois index 93de62b..aa59c48 100644 --- a/colourfiles/conf.whois +++ b/colourfiles/conf.whois @@ -18,6 +18,14 @@ colours=yellow regexp=(([\w\d]([\w\d-])+\.){1,})([\w\d-]{2,}) colours=green ======= +# IPv4 +regexp=\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3} +colours=green +======= +# IPv6 +regexp=[0-9a-fA-F]{0,4}(\:\:?[0-9a-fA-F]{0,4})+? +colours=green +======= # url regexp=http[s]?://(([\w\d]([\w\d-])+\.){1,})([\w\d-]{2,})(/[\w\d\S\s]*)* colours=bold green