Updated MeshCommander with 802.1x dialog fixes.

This commit is contained in:
Ylian Saint-Hilaire 2022-04-02 16:03:13 -07:00
parent 8e5c71cea2
commit 61b01f77fb
2 changed files with 21 additions and 18 deletions

View File

@ -417,6 +417,7 @@ module.exports.CreateAmtManager = function (parent) {
var devices = obj.amtDevices[event.nodeid], devFound = null;
if (devices != null) { for (var i in devices) { if (devices[i].netAuthSatReqId == event.reqid) { devFound = devices[i]; } } }
if (devFound == null) return; // Unable to find a device for this 802.1x profile
const netAuthSatReqId = devFound.netAuthSatReqId;
delete devFound.netAuthSatReqId;
if (devFound.netAuthSatReqTimer != null) { clearTimeout(devFound.netAuthSatReqTimer); delete devFound.netAuthSatReqTimer; }
if ((event.response == null) || (typeof event.response != 'object') || (typeof event.response.authProtocol != 'number')) {
@ -432,6 +433,7 @@ module.exports.CreateAmtManager = function (parent) {
devFound.netAuthCredentials[event.response.authProtocol] = event.response;
devFound.consoleMsg("Setting MeshCentral Satellite 802.1x profile...");
if (netAuthSatReqId.startsWith("wired-")) {
// Set the 802.1x wired profile in the device
var devNetAuthProfile = devFound.netAuthSatReqDev;
var srvNetAuthProfile = devFound.netAuthSatReqSrv;
@ -439,6 +441,7 @@ module.exports.CreateAmtManager = function (parent) {
delete devFound.netAuthSatReqSrv;
attempt8021xSyncEx(devFound, devNetAuthProfile, srvNetAuthProfile);
}
}
break;
}
}

File diff suppressed because one or more lines are too long