From e74f4ddf8182067ca4f44d8d4ed91a8c5fc65147 Mon Sep 17 00:00:00 2001 From: tv Date: Fri, 8 Apr 2016 04:41:30 +0200 Subject: krebs types.addr6: str -> IPv6 address* --- krebs/4lib/types.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'krebs/4lib') diff --git a/krebs/4lib/types.nix b/krebs/4lib/types.nix index 6396927d..f4649180 100644 --- a/krebs/4lib/types.nix +++ b/krebs/4lib/types.nix @@ -223,7 +223,14 @@ types // rec { in x: match IPv4address x != null; merge = mergeOneOption; }; - addr6 = str; # TODO + addr6 = mkOptionType { + name = "IPv6 address"; + check = let + # TODO check IPv6 address harder + IPv6address = "[0-9a-f.:]+"; + in x: match IPv6address x != null; + merge = mergeOneOption; + }; pgp-pubkey = str; -- cgit v1.2.3