Skip to content
Snippets Groups Projects
Unverified Commit 532b5701 authored by Matthias Schiffer's avatar Matthias Schiffer
Browse files

gluon-core, gluon-client-bridge: allow 0-character ESSIDs/mesh IDs

parent dda1b2a1
No related branches found
No related tags found
No related merge requests found
...@@ -9,7 +9,7 @@ need_string_match(in_domain({'next_node', 'ip6'}), '^[%x:]+$', false) ...@@ -9,7 +9,7 @@ need_string_match(in_domain({'next_node', 'ip6'}), '^[%x:]+$', false)
for _, config in ipairs({'wifi24', 'wifi5'}) do for _, config in ipairs({'wifi24', 'wifi5'}) do
if need_table({config, 'ap'}, nil, false) then if need_table({config, 'ap'}, nil, false) then
need_string_match(in_domain({config, 'ap', 'ssid'}), '^.' .. ('.?'):rep(31) .. '$') need_string_match(in_domain({config, 'ap', 'ssid'}), '^' .. ('.?'):rep(32) .. '$')
need_boolean({config, 'ap', 'disabled'}, false) need_boolean({config, 'ap', 'disabled'}, false)
end end
end end
...@@ -48,7 +48,7 @@ for _, config in ipairs({'wifi24', 'wifi5'}) do ...@@ -48,7 +48,7 @@ for _, config in ipairs({'wifi24', 'wifi5'}) do
need_array_of({config, 'basic_rate'}, supported_rates or rates, supported_rates ~= nil) need_array_of({config, 'basic_rate'}, supported_rates or rates, supported_rates ~= nil)
if need_table({config, 'ibss'}, nil, false) then if need_table({config, 'ibss'}, nil, false) then
need_string_match(in_domain({config, 'ibss', 'ssid'}), '^.' .. ('.?'):rep(31) .. '$') need_string_match(in_domain({config, 'ibss', 'ssid'}), '^' .. ('.?'):rep(32) .. '$')
need_string_match(in_domain({config, 'ibss', 'bssid'}), '^%x[02468aAcCeE]:%x%x:%x%x:%x%x:%x%x:%x%x$') need_string_match(in_domain({config, 'ibss', 'bssid'}), '^%x[02468aAcCeE]:%x%x:%x%x:%x%x:%x%x:%x%x$')
need_one_of({config, 'ibss', 'mcast_rate'}, supported_rates or rates, false) need_one_of({config, 'ibss', 'mcast_rate'}, supported_rates or rates, false)
need_number({config, 'ibss', 'vlan'}, false) need_number({config, 'ibss', 'vlan'}, false)
...@@ -56,7 +56,7 @@ for _, config in ipairs({'wifi24', 'wifi5'}) do ...@@ -56,7 +56,7 @@ for _, config in ipairs({'wifi24', 'wifi5'}) do
end end
if need_table({config, 'mesh'}, nil, false) then if need_table({config, 'mesh'}, nil, false) then
need_string_match(in_domain({config, 'mesh', 'id'}), '^.' .. ('.?'):rep(31) .. '$') need_string_match(in_domain({config, 'mesh', 'id'}), '^' .. ('.?'):rep(32) .. '$')
need_one_of({config, 'mesh', 'mcast_rate'}, supported_rates or rates, false) need_one_of({config, 'mesh', 'mcast_rate'}, supported_rates or rates, false)
need_boolean({config, 'mesh', 'disabled'}, false) need_boolean({config, 'mesh', 'disabled'}, false)
end end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment