summaryrefslogtreecommitdiffhomepage
path: root/protocols/luci-proto-openconnect/htdocs/luci-static/resources
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2019-10-16 09:30:54 +0200
committerJo-Philipp Wich <jo@mein.io>2019-10-16 09:31:24 +0200
commit7a010b11781222622673c948a06acf0929b98d0a (patch)
tree3f21a434a5010673aac61ccd8f7d4d187f2a8578 /protocols/luci-proto-openconnect/htdocs/luci-static/resources
parent0321d47fe9fcaace3801b1c9586cbad76b673607 (diff)
luci-proto-openconnect: make PEM values optional
Fixes: #3191 Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'protocols/luci-proto-openconnect/htdocs/luci-static/resources')
-rw-r--r--protocols/luci-proto-openconnect/htdocs/luci-static/resources/protocol/openconnect.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/protocols/luci-proto-openconnect/htdocs/luci-static/resources/protocol/openconnect.js b/protocols/luci-proto-openconnect/htdocs/luci-static/resources/protocol/openconnect.js
index 14fc8f6d35..0490ceb5ea 100644
--- a/protocols/luci-proto-openconnect/htdocs/luci-static/resources/protocol/openconnect.js
+++ b/protocols/luci-proto-openconnect/htdocs/luci-static/resources/protocol/openconnect.js
@@ -43,6 +43,9 @@ function validateCert(priv, section_id, value) {
start = false,
i;
+ if (value === null || value === '')
+ return true;
+
for (i = 0; i < lines.length; i++) {
if (lines[i].match(beg))
start = true;