rfc1918Filter.default = rfc1918Filter.enabled;
rfc1918Filter.rmempty = false;
- cert_file = ucs.taboption('general', form.FileUpload, 'cert', _('HTTPS Certificate (DER or PEM format)'));
+ cert_file = ucs.taboption('general', form.FileUpload, 'cert', _('HTTPS Certificate (DER or PEM format)'), _('Files can only be uploaded and saved to the /etc/luci-uploads directory.'));
cert_file.root_directory = '/';
- cert_file.enable_delete = false;
+ cert_file.enable_remove = false;
- key_file = ucs.taboption('general', form.FileUpload, 'key', _('HTTPS Private Key (DER or PEM format)'));
+ key_file = ucs.taboption('general', form.FileUpload, 'key', _('HTTPS Private Key (DER or PEM format)'), _('Files can only be uploaded and saved to the /etc/luci-uploads directory.'));
key_file.root_directory = '/';
- key_file.enable_delete = false;
+ key_file.enable_remove = false;
var removeOld = ucs.taboption('general', form.Button, 'remove_old', _('Remove old certificate and key'), _('uHTTPd will generate a new self-signed certificate using the configuration shown below.'));
removeOld.inputstyle = 'remove';
"luci-app-uhttpd": {
"description": "Grant UCI access for luci-app-uhttpd",
"read": {
- "uci": [ "uhttpd" ],
+ "uci": ["uhttpd"],
"file": {
- "/*": ["read"]
+ "/*": ["read"],
+ "/etc/init.d/uhttpd restart": ["exec"]
}
},
"write": {
- "uci": [ "uhttpd" ],
+ "uci": ["uhttpd"],
"file": {
- "/*": ["write"],
- "/etc/init.d/uhttpd restart": ["exec"]
+ "/etc/luci-uploads/*": ["write"],
+ "/etc/uhttpd.key": ["write"],
+ "/etc/uhttpd.crt": ["write"]
}
}
}