luci-app-fwknopd: add support for ENABLE_CMD_EXEC
authorPtilopsis Leucotis <PtilopsisLeucotis@yandex.com>
Tue, 13 Apr 2021 12:43:51 +0000 (15:43 +0300)
committerHannu Nyman <hannu.nyman@iki.fi>
Tue, 13 Apr 2021 14:10:12 +0000 (17:10 +0300)
Add support for execution commands on the fwknopd server.

Signed-off-by: Ptilopsis Leucotis <PtilopsisLeucotis@yandex.com>
applications/luci-app-fwknopd/htdocs/luci-static/resources/view/fwknopd.js

index d7a76e4404a9c37a03fe2b8c0f004ccf3175fa46..df368749a79bbbb2f61a728aa7f033330d2e5b53 100644 (file)
@@ -591,6 +591,9 @@ return view.extend({
                                                        This makes it impossible to use the -s command line argument on the fwknop client command line, so either -R \
                                                        has to be used to automatically resolve the external address (if the client behind a NAT) or the client must \
                                                        know the external IP and set it via the -a argument.'));
+               s:option(YNValue, 'ENABLE_CMD_EXEC', 'ENABLE_CMD_EXEC', _('This instructs fwknopd to accept complete commands that are contained within an authorization packet. \
+                                                       Any such command will be executed on the fwknopd server as the user specified by the “CMD_EXEC_USER” or as the user \
+                                                       that started fwknopd if that is not set.'));
 
                s = m.section(form.TypedSection, 'config', _('fwknopd.conf config options'));
                s.anonymous=true;