[Osquery_manager] Logged users artifact saved query #17008
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Logged In Users Artifact
The Logged In Users artifact provides comprehensive visibility into currently active user sessions across Windows, Linux, and macOS systems. This cross-platform query enables security teams to detect lateral movement, identify unauthorized access patterns, and perform user activity forensics by enumerating all authenticated sessions with detailed context including login timestamps, session types, and remote connection information.
Core Forensic Artifacts Coverage
Queries by Platform
🪟🍎🐧 Cross-Platform - Active Session Enumeration
Description
Enumerates all currently logged-in users across Windows, Linux, and macOS systems with comprehensive session details. The query retrieves login timestamps, usernames, logon types (console, remote, service), terminal/TTY information, remote host addresses for network sessions, and process IDs. On Windows, it additionally captures the user's Security Identifier (SID) and registry hive path for correlation with other forensic artifacts.
Detection Focus:
Result
Query results will show all active user sessions with the following information:
Platform
linux,darwin,windowsInterval
3600seconds (1 hour)Query ID
logged_in_users_elasticECS Field Mappings
event.category→["session"](static value)event.action→osquery.logged_in_users(static value)user.name→usernameuser.id→user_sidprocess.pid→pidsource.address→remote_hosttags→["osquery", "user_activity", "session"](static value)SQL Query
Platform-Specific Notes
Windows
Linux/macOS