diff --git a/renderer/templates/interface/ssid.uc b/renderer/templates/interface/ssid.uc index 3906011..99f9cac 100644 --- a/renderer/templates/interface/ssid.uc +++ b/renderer/templates/interface/ssid.uc @@ -310,7 +310,7 @@ set wireless.{{ section }}.iw_venue_type='{{ ssid.pass_point.venue_type }}' add_list wireless.{{ section }}.iw_venue_url={{ s((n + 1) + ":" +url) }} {% endfor %} set wireless.{{ section }}.iw_network_auth_type='{{ match_hs20_auth_type(ssid.pass_point.auth_type) }}' -set wireless.{{ section }}.iw_domain_name={{ s(ssid.pass_point.domain_name) }} +set wireless.{{ section }}.iw_domain_name={{ s(join(":", ssid.pass_point.domain_name)) }} {% for (let realm in ssid.pass_point.nai_realm): %} add_list wireless.{{ section }}.iw_nai_realm='{{ realm }}' {% endfor %} diff --git a/schema/interface.ssid.pass-point.yml b/schema/interface.ssid.pass-point.yml index bd17a7e..45667e0 100644 --- a/schema/interface.ssid.pass-point.yml +++ b/schema/interface.ssid.pass-point.yml @@ -55,8 +55,10 @@ properties: domain-name: description: The IEEE 802.11u Domain Name. - type: string - format: hostname + type: array + items: + type: string + format: hostname nai-realm: description: NAI Realm information diff --git a/schemareader.uc b/schemareader.uc index 668a7a8..33bf1fb 100644 --- a/schemareader.uc +++ b/schemareader.uc @@ -2844,14 +2844,25 @@ function instantiateInterfaceSsidPassPoint(location, value, errors) { } function parseDomainName(location, value, errors) { - if (type(value) == "string") { - if (!matchHostname(value)) - push(errors, [ location, "must be a valid hostname" ]); + if (type(value) == "array") { + function parseItem(location, value, errors) { + if (type(value) == "string") { + if (!matchHostname(value)) + push(errors, [ location, "must be a valid hostname" ]); + } + + if (type(value) != "string") + push(errors, [ location, "must be of type string" ]); + + return value; + } + + return map(value, (item, i) => parseItem(location + "/" + i, item, errors)); } - if (type(value) != "string") - push(errors, [ location, "must be of type string" ]); + if (type(value) != "array") + push(errors, [ location, "must be of type array" ]); return value; } diff --git a/ucentral.schema.json b/ucentral.schema.json index 62e3456..47935ad 100644 --- a/ucentral.schema.json +++ b/ucentral.schema.json @@ -1126,8 +1126,11 @@ "maxLength": 2 }, "domain-name": { - "type": "string", - "format": "hostname" + "type": "array", + "items": { + "type": "string", + "format": "hostname" + } }, "nai-realm": { "type": "array",