add sync events for user login/logout

This commit is contained in:
sbwalker
2024-12-09 10:55:40 -05:00
parent 2c721ad5dd
commit 13e4267c11
4 changed files with 11 additions and 1 deletions

View File

@ -645,6 +645,9 @@ namespace Oqtane.Extensions
}
}
var _syncManager = httpContext.RequestServices.GetRequiredService<ISyncManager>();
_syncManager.AddSyncEvent(alias, EntityNames.User, user.UserId, "Login");
_logger.Log(LogLevel.Information, "ExternalLogin", Enums.LogFunction.Security, "External User Login Successful For {Username} From IP Address {IPAddress} Using Provider {Provider}", user.Username, httpContext.Connection.RemoteIpAddress.ToString(), providerName);
}
}