summaryrefslogtreecommitdiffstats
path: root/krebs/4lib
diff options
context:
space:
mode:
Diffstat (limited to 'krebs/4lib')
-rw-r--r--krebs/4lib/types.nix9
1 files changed, 8 insertions, 1 deletions
diff --git a/krebs/4lib/types.nix b/krebs/4lib/types.nix
index 6396927dd..f46491801 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;