@@ -131,15 +131,15 @@ in
131131 type = with types; listOf (submodule {
132132 options = {
133133 sourcePort = mkOption {
134− type = types.int;
134+ type = types.either types.int (types.strMatching "[[:digit:]]+:[[:digit:]]+");
135135 example = 8080;
136− description = "Source port of the external interface";
136+ description = "Source port of the external interface; to specify a port range, use a string with a colon (e.g. \"60000:61000\")";
137137 };
138138
139139 destination = mkOption {
140140 type = types.str;
141141 example = "10.0.0.1:80";
142− description = "Forward connection to destination ip:port";
142+ description = "Forward connection to destination ip:port; to specify a port range, use ip:start-end";
143143 };
144144
145145 proto = mkOption {