RDP
Last updated
Last updated
Bitmap cache will cache still standing images of an RDP session so that they can be referenced instead of retransmitted. The purpose of this is to optimize RDP session.
We can leverage this artifact to collect what the TA saw during the RDP session. Useful for proving what a TA might've opened or actions they performed.
File Location:
C:\Users\USERNAME\AppData\Local\Microsoft\Terminal Server Client\Cache\*
Cache files are stored in .bin files.
Execute bmc-tools:
The output images will be saved to output folder.
We can then stitch together these image pieces using RDP Cache Sitcher.
Grab the compiled release version of the software and then open up the directory the image tiles are stored in. We can then stitch together tiles to make a complete image.
RDP credentials are stored in LSASS of the target computer. The plaintext passwords can be dumped from LSASS using mimikatz.
Introduced in Windows Server 2012 R2 and Windows 8.1, Restricted Admin mode provides additional security to remote logon scenarios. This mode of Remote Desktop causes the client application to perform a network logon challenge-response with the NT one-way function (NTOWF) or use a Kerberos service ticket when authenticating to the remote host. After the administrator is authenticated, the administrator does not have the respective account credentials in LSASS because they were not supplied to the remote host. Instead, the administrator has the computer account credentials for the session. Administrator credentials are not supplied to the remote host, so actions are performed as the computer account. Resources are also limited to the computer account, and the administrator cannot access resources with his own account.
Query svchost running Terminal Services.
Dump process or select-string for password in memory.
Look for .dmp files on the host.
Credential Manager Location:
C:\Users\username\AppData\Local\Microsoft\Credentials
Credentials are stored in Credential Manager, not in .rdp files.
.rdp files reference credential manager for creds.
Requires SYSTEM privs to accomplish.
Another method is to create a service that will connect selected session to ours.
Get all sessions information:
Create service which will hijack user's session:
Start service:
Event IDS4778
(logon) and4779
(logoff) events can be used to figure out which desktop sessions got disconnected/reconnected.
Tscon running as SYSTEM
Tscon executed as SYSTEM from persistence method scheduled task, service, WMI, etc.
.rdp files are plaintext config files.
Credentials are stored in Credential Manager, not in .rdp files.
.rdp files reference credential manager for creds