1
0
Fork 0
mirror of https://github.com/Ylianst/MeshCentral.git synced 2025-03-09 15:40:18 +00:00

Improved certificate checking.

This commit is contained in:
Ylian Saint-Hilaire 2020-11-08 13:29:37 -08:00
parent c24c8821fe
commit 8b9a437ed7
3 changed files with 18 additions and 2 deletions

View file

@ -1328,6 +1328,10 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use
if (url.query.p == '1') { requiredNonRights = MESHRIGHT_NOTERMINAL; }
else if ((url.query.p == '4') || (url.query.p == '5')) { requiredNonRights = MESHRIGHT_NOFILES; }
// Add server TLS cert hash
const tlsCertHash = parent.webCertificateHashs[domain.id];
if (tlsCertHash != null) { command.servertlshash = Buffer.from(tlsCertHash, 'binary').toString('hex'); }
// Add user consent messages
command.soptions = {};
if (typeof domain.consentmessages == 'object') {