Allow TLS config node to provide just CA cert

Fixes #2297
This commit is contained in:
Nick O'Leary 2019-10-04 11:01:15 +01:00
parent 3cb00ce4e0
commit e35f6d9e35
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 1 additions and 1 deletions

View File

@ -27,7 +27,7 @@ module.exports = function(RED) {
var caPath = n.ca.trim();
this.servername = (n.servername||"").trim();
if ((certPath.length > 0) || (keyPath.length > 0)) {
if ((certPath.length > 0) || (keyPath.length > 0) || (caPath.length > 0)) {
if ( (certPath.length > 0) !== (keyPath.length > 0)) {
this.valid = false;