Hey there,
Looking for an app that will take unsuccessful login attempts to my internet facing RDP server and show pretty graphs and Geo IP location maps of IP addresses attempting to connect.
Thanks.
Did a little research and built the following query to display failed Remote Desktop Attempts by geo location on a map:
source=WinEventLog:Security sourcetype=WinEventLog:security Logon_Type=10 EventCode=4625 | eval Date=strftime(_time, "%Y/%m/%d") | rex "Failed:\s+.*\s+Account\sName:\s+(?\S+)\s" | stats count by Date, TargetAccount, Failure_Reason, Source_Network_Address| iplocation Source_Network_Address | geostats count by Source_Network_Address | sort -count
To view failed attempts by date, login, reason, and source ip I found the following query:
source=WinEventLog:Security sourcetype=WinEventLog:security Logon_Type=10 EventCode=4625 | eval Date=strftime(_time, "%Y/%m/%d") | rex "Failed:\s+.*\s+Account\sName:\s+(?\S+)\s" | stats count by Date, TargetAccount, Failure_Reason, Source_Network_Address
Did a little research and built the following query to display failed Remote Desktop Attempts by geo location on a map:
source=WinEventLog:Security sourcetype=WinEventLog:security Logon_Type=10 EventCode=4625 | eval Date=strftime(_time, "%Y/%m/%d") | rex "Failed:\s+.*\s+Account\sName:\s+(?\S+)\s" | stats count by Date, TargetAccount, Failure_Reason, Source_Network_Address| iplocation Source_Network_Address | geostats count by Source_Network_Address | sort -count
To view failed attempts by date, login, reason, and source ip I found the following query:
source=WinEventLog:Security sourcetype=WinEventLog:security Logon_Type=10 EventCode=4625 | eval Date=strftime(_time, "%Y/%m/%d") | rex "Failed:\s+.*\s+Account\sName:\s+(?\S+)\s" | stats count by Date, TargetAccount, Failure_Reason, Source_Network_Address
Quick question on scope of the question:
Do you already have the RDP session information in Splunk? Are the IP addresses those logs have "external" or are they through NATed addresses? If NATed, do you have the firewall logs to go with it so you can find out the external addresses?
Thanks,
Rich
Rich,
Yes, the RDP logs are in splunk and the IP addresses in those logs are not NATed but are external.
Thanks.
There is nothing out there, but this is quite straightforward to make assuming :
1) Firewall or security logs that identify SRC and DST for ips of your servers
2) Firewall or security logs that identify DST port traffic of your servers..
E.g., timestampofEvent allow TCP outsidehost:54000 TO TCP myrdpserver:3389 duration:50:00.00
Firewall logs are typically in that format. If you're logging in windows event logs, it will look different, but you're basically going to need the same information; src ip, port, dest ip, timestamp, duration.
If you have those, provide a sample and we can help you write a simple query that you can use to visualize.
Using windows event logs, below is a snippet of one of the logs, I appreciate it.
12/21/2015 04:04:20 PM
LogName=Security
SourceName=Microsoft Windows security auditing.
EventCode=4625
EventType=0
Type=Information
ComputerName=Server
TaskCategory=Logon
OpCode=Info
RecordNumber=2755
Keywords=Audit Failure
Message=An account failed to log on.
Subject:
Security ID: S-1-5-18
Account Name: SERVER$
Account Domain: WORKGROUP
Logon ID: 0x3E7
Logon Type: 10
Account For Which Logon Failed:
Security ID: S-1-0-0
Account Name: administrator
Account Domain: SERVER
Failure Information:
Failure Reason: Unknown user name or bad password.
Status: 0xC000006D
Sub Status: 0xC000006A
Process Information:
Caller Process ID: 0x188
Caller Process Name: C:\Windows\System32\svchost.exe
Network Information:
Workstation Name: SERVER
Source Network Address: 184.147.111.11
Source Port: 0
Detailed Authentication Information:
Logon Process: User32
Authentication Package: Negotiate
Transited Services: -
Package Name (NTLM only): -
Key Length: 0
This event is generated when a logon request fails. It is generated on the computer where access was attempted.
The Subject fields indicate the account on the local system which requested the logon. This is most commonly a service such as the Server service, or a local process such as Winlogon.exe or Services.exe.
The Logon Type field indicates the kind of logon that was requested. The most common types are 2 (interactive) and 3 (network).
The Process Information fields indicate which account and process on the system requested the logon.
The Network Information fields indicate where a remote logon request originated. Workstation name is not always available and may be left blank in some cases.
The authentication information fields provide detailed information about this specific logon request.
- Transited services indicate which intermediate services have participated in this logon request.
- Package name indicates which sub-protocol was used among the NTLM protocols.
- Key length indicates the length of the generated session key. This will be 0 if no session key was requested.
Collapse
Account_Domain = WORKGROUP Account_Domain = SERVER Account_Name = SERVER$ Account_Name = administrator Source_Network_Address = 184.147.111.11 source = WinEventLog:Security sourcetype = WinEventLog:Security