Home Dissecting RDP Activity
Post
Cancel

Dissecting RDP Activity

rdp

β€œRDP is a double-edged sword β€” it offers seamless remote access, but in the wrong hands, it’s a doorway for attackers. In this post, we trace every footprint RDP leaves in your event logs.”


🧠 RDP in Forensics

Remote Desktop Protocol (RDP) is one of the most common entry points in Windows environments β€” both for system administrators and malicious actors. Understanding the chain of RDP-related Event IDs allows defenders to reconstruct session activity, identify unauthorized access, and correlate logins, re-connections, and logoffs.

This blog post breaks down key RDP events and presents a timeline-style visualization of an RDP session lifecycle.


πŸ” Successful Logon: The Forensic Breadcrumbs

When a valid RDP session is established, the following Event IDs are triggered:

Event IDDescriptionLog Source
1149User authentication succeededRemoteConnectionManager
4624 (Type 10/7)Logon successSecurity.evtx
21, 22Shell start / session logonLocalSessionManager

1 RDP Successful Logon

🧠 Tip: Always correlate 1149 + 4624 for RDP logon confirmation. Type 10 (RemoteInteractive) is your smoking gun.


🚫 Unsuccessful Logon Attempts

Threat actors love brute-force RDP attacks. Track failed logon attempts using:

Event IDDescriptionLog Source
1149Attempt made (still triggers!)RemoteConnectionManager
4625Account failed to log onSecurity.evtx

2_unsuccessfull_logon

πŸ” Watch for high-frequency 4625s followed by a successful 4624 β€” a sign of brute-force followed by success.


πŸ” RDP Session Reconnects & Disconnects

Sessions can disconnect due to idle timeouts or network blips. Here’s how to track them:

Event IDWhat HappenedSource
24, 40Session disconnectedLocalSessionManager
4634Account logged offSecurity.evtx
4779Session disconnected from Window StationSecurity.evtx
25Session reconnection succeededLSM
4778Session reconnectedSecurity.evtx

πŸ“Œ Reason codes in Event 40 can indicate whether the disconnect was manual, idle timeout, or network loss.

Session Disconnect through window close RDP Session Disconnect(Window Close)
Purposeful Disconnect via Start RDP Session Disconnect(Purposefull Disconnect via start)
RDP Session reconnect RDP Session Reconnect

β€”

🧾 RDP Logoff and Session End

The tail end of an RDP session logs final cleanup:

Event IDMeaningSource
23Logoff successLSM
4647User initiated logoffSecurity.evtx
9009Desktop Window Manager exitedSystem.evtx

πŸ“Ž Use Event 4647 to differentiate between user-initiated logoff vs. forced logoff. Session logoff RDP Session Logoff β€”

πŸ”§ Practical Use Case: Detecting Suspicious RDP Behavior

Let’s say you see the following sequence:

  1. Many 4625 failures for user admin
  2. One successful 1149 + 4624 (Type 10)
  3. A quick 4634 logoff

This could signal a brute-force attack followed by immediate reconnaissance and logoff.

Add contextual data like:

  • Login time outside business hours
  • Non-corporate IP address
  • Unusual hostnames or session durations

🎨 RDP Timeline Visualization

Here’s a conceptual timeline:

1
2
3
4
5
6
7
[00:00] -> Event 1149: Auth attempt  
[00:01] -> Event 4624: Success login (Type 10)  
[00:02] -> Event 21/22: Shell/session initiated  
[00:30] -> Event 40: Disconnected  
[00:31] -> Event 25: Reconnected  
[01:00] -> Event 4647: Logoff initiated  
[01:00] -> Event 9009: DWM closed  

🧭 Visual timelines like these help in threat hunting and post-incident investigations.


πŸ”š Final Thoughts

RDP event forensics isn’t just about detecting brute-force attacks β€” it’s about creating a narrative from logs. By correlating Event IDs across Security.evtx, System.evtx, and TerminalServices logs, you can reconstruct attacker behavior with high fidelity.


πŸ”— References & Credits

This post is licensed under CC BY 4.0 by the author.

Acquiring RAM Through Cooling Methods

-