projects
/
project
/
luci.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
web: Relax hostname validation for length
[project/luci.git]
/
libs
/
web
/
luasrc
/
cbi
/
datatypes.lua
diff --git
a/libs/web/luasrc/cbi/datatypes.lua
b/libs/web/luasrc/cbi/datatypes.lua
index
d1ac8f4
..
58b54de
100644
(file)
--- a/
libs/web/luasrc/cbi/datatypes.lua
+++ b/
libs/web/luasrc/cbi/datatypes.lua
@@
-127,7
+127,7
@@
function macaddr(val)
end
function hostname(val)
- if val and (#val < 25) and val.match(val, "^[a-zA-Z0-9][a-zA-Z0-9%-%.]*[a-zA-Z0-9]$") then
+ if val and (#val < 25
4
) and val.match(val, "^[a-zA-Z0-9][a-zA-Z0-9%-%.]*[a-zA-Z0-9]$") then
return true
end
return false