gluon-client-bridge: check AP SSID length to be in range of 1-32 characters

This commit is contained in:
Jan-Tarek Butt 2018-03-17 15:14:14 +01:00 committed by Matthias Schiffer
parent 9a9024843b
commit dda1b2a127
No known key found for this signature in database
GPG Key ID: 16EF3F64CB201D9C

View File

@ -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(in_domain({config, 'ap', 'ssid'})) need_string_match(in_domain({config, 'ap', 'ssid'}), '^.' .. ('.?'):rep(31) .. '$')
need_boolean({config, 'ap', 'disabled'}, false) need_boolean({config, 'ap', 'disabled'}, false)
end end
end end