Forum Discussion
Log Analytics Query for computer last login/active date and time
Did you see this link?
https://docs.microsoft.com/en-us/azure/azure-monitor/log-query/joins
SecurityEvent
| where EventID == 4624 // sign-in events
| project Computer, Account, TargetLogonId, LogonTime=TimeGenerated
| join kind= inner (
SecurityEvent
| where EventID == 4634 // sign-out events
| project TargetLogonId, LogoffTime=TimeGenerated
) on TargetLogonId
| extend Duration = LogoffTime-LogonTime
| project-away TargetLogonId1
| top 10 by Duration desc
- CliveWatsonFeb 17, 2020Former Employee
Hello JamesvandenBerg
The issue is that he doesn't (yet) have that data source. yashsedani to on-board this data source, you will need to enable Azure Security Center - which needs the standard licence (31days eval is also available); so this would billable against you Azure enrollment (just like Log Analytics).
You can also get SecurityEvent from Azure Sentinel - with the Security Events data collector, again its billable.
https://azure.microsoft.com/en-us/pricing/details/security-center/
Thanks Clive