luci-app-uhttpd: support 'organization' option
authorHannu Nyman <hannu.nyman@iki.fi>
Sat, 29 Jan 2022 14:58:08 +0000 (16:58 +0200)
committerHannu Nyman <hannu.nyman@iki.fi>
Sat, 29 Jan 2022 15:06:15 +0000 (17:06 +0200)
Support the organization option, added in 2020.
Mention in help text that a random/unique value is used in
certificate generation if the organization option is empty.

Re-order the certificate items to logical order.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
(cherry picked from commit e3fbfe99094cc27ea7ad551fea193bc67c201ef0)

applications/luci-app-uhttpd/luasrc/model/cbi/uhttpd/uhttpd.lua

index 20929036d729ae03ae9d0a57ed72d3b233c1144c..940f09873b2230927727dc40456b3b28a7c88522 100644 (file)
@@ -218,13 +218,15 @@ o.datatype = "min(1024)"
 o = s:option(Value, "commonname", translate("Server Hostname"), translate("a.k.a CommonName"))
 o.default = luci.sys.hostname()
 
-o = s:option(Value, "country", translate("Country"))
-o.default = "ZZ"
+o = s:option(Value, "organization", translate("Organization"), translate("If empty, a random/unique value is used in cert generation"))
 
-o = s:option(Value, "state", translate("State"))
+o = s:option(Value, "location", translate("Location"))
 o.default = "Unknown"
 
-o = s:option(Value, "location", translate("Location"))
+o = s:option(Value, "state", translate("State"))
 o.default = "Unknown"
 
+o = s:option(Value, "country", translate("Country"))
+o.default = "ZZ"
+
 return m