mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2024-12-25 06:35:54 -05:00
parent
1b42b59807
commit
ad0b60a560
@ -175,7 +175,7 @@ module.exports.CertificateOperations = function (parent) {
|
||||
|
||||
if ((typeof acmconfig.certpfx == 'string') && (typeof acmconfig.certpfxpass == 'string')) {
|
||||
// P12 format, certpfx and certpfxpass
|
||||
try { r = obj.loadPfxCertificate(obj.parent.common.joinPath(obj.parent.datapath, acmconfig.certpfx), acmconfig.certpfxpass); } catch (ex) { console.log(ex); }
|
||||
try { r = obj.loadPfxCertificate(parent.common.joinPath(obj.parent.datapath, acmconfig.certpfx), acmconfig.certpfxpass); } catch (ex) { console.log(ex); }
|
||||
if ((r == null) || (r.certs == null) || (r.keys == null) || (r.certs.length < 2) || (r.keys.length != 1)) continue;
|
||||
} else if ((typeof acmconfig.certfiles == 'object') && (typeof acmconfig.keyfile == 'string')) {
|
||||
// PEM format, certfiles and keyfile
|
||||
|
@ -5916,7 +5916,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
||||
if ((typeof domain.authstrategies.saml.cert != 'string') || (typeof domain.authstrategies.saml.idpurl != 'string')) {
|
||||
console.log('ERROR: Missing SAML configuration.');
|
||||
} else {
|
||||
const certPath = common.joinPath(obj.parent.datapath, domain.authstrategies.saml.cert);
|
||||
const certPath = obj.common.joinPath(obj.parent.datapath, domain.authstrategies.saml.cert);
|
||||
var cert = obj.fs.readFileSync(certPath);
|
||||
if (cert == null) {
|
||||
console.log('ERROR: Unable to read SAML IdP certificate: ' + domain.authstrategies.saml.cert);
|
||||
@ -5999,7 +5999,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
||||
if ((typeof domain.authstrategies.jumpcloud.cert != 'string') || (typeof domain.authstrategies.jumpcloud.idpurl != 'string')) {
|
||||
console.log('ERROR: Missing JumpCloud SAML configuration.');
|
||||
} else {
|
||||
var cert = obj.fs.readFileSync(common.joinPath(obj.parent.datapath, domain.authstrategies.jumpcloud.cert));
|
||||
var cert = obj.fs.readFileSync(obj.common.joinPath(obj.parent.datapath, domain.authstrategies.jumpcloud.cert));
|
||||
if (cert == null) {
|
||||
console.log('ERROR: Unable to read JumpCloud IdP certificate: ' + domain.authstrategies.jumpcloud.cert);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user