mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-09 15:40:18 +00:00
Improved support for reverse-proxy certificate loading.
This commit is contained in:
parent
bdd1a5b2e2
commit
f062c98aad
6 changed files with 127 additions and 88 deletions
|
@ -196,7 +196,6 @@ module.exports.CertificateOperations = function (parent) {
|
|||
|
||||
// Return the certificate of the remote HTTPS server
|
||||
obj.loadCertificate = function (url, hostname, tag, func) {
|
||||
console.log('loadCertificate', url, hostname);
|
||||
const u = require('url').parse(url);
|
||||
if (u.protocol == 'https:') {
|
||||
// Read the certificate from HTTPS
|
||||
|
@ -218,7 +217,7 @@ module.exports.CertificateOperations = function (parent) {
|
|||
func(url, data, hostname, tag);
|
||||
}
|
||||
});
|
||||
} else { func(url, null, tag); }
|
||||
} else { func(url, null, hostname, tag); }
|
||||
};
|
||||
|
||||
// Check if a configuration file exists
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue