Unusual Windows Remote User

A machine learning job detected an unusual remote desktop protocol (RDP) username, which can indicate account takeover or credentialed persistence using compromised accounts. RDP attacks, such as BlueKeep, also tend to use unusual usernames.

Elastic rule (View on GitHub)

  1[metadata]
  2creation_date = "2020/03/25"
  3integration = ["endpoint", "windows"]
  4maturity = "production"
  5updated_date = "2024/06/18"
  6
  7[rule]
  8anomaly_threshold = 50
  9author = ["Elastic"]
 10description = """
 11A machine learning job detected an unusual remote desktop protocol (RDP) username, which can indicate account takeover
 12or credentialed persistence using compromised accounts. RDP attacks, such as BlueKeep, also tend to use unusual
 13usernames.
 14"""
 15false_positives = [
 16    """
 17    Uncommon username activity can be due to an engineer logging onto a server instance in order to perform manual
 18    troubleshooting or reconfiguration.
 19    """,
 20]
 21from = "now-45m"
 22interval = "15m"
 23license = "Elastic License v2"
 24machine_learning_job_id = ["v3_windows_rare_user_type10_remote_login"]
 25name = "Unusual Windows Remote User"
 26setup = """## Setup
 27
 28This rule requires the installation of associated Machine Learning jobs, as well as data coming in from one of the following integrations:
 29- Elastic Defend
 30- Windows
 31
 32### Anomaly Detection Setup
 33
 34Once the rule is enabled, the associated Machine Learning job will start automatically. You can view the Machine Learning job linked under the "Definition" panel of the detection rule. If the job does not start due to an error, the issue must be resolved for the job to commence successfully. For more details on setting up anomaly detection jobs, refer to the [helper guide](https://www.elastic.co/guide/en/kibana/current/xpack-ml-anomalies.html).
 35
 36### Elastic Defend Integration Setup
 37Elastic Defend is integrated into the Elastic Agent using Fleet. Upon configuration, the integration allows the Elastic Agent to monitor events on your host and send data to the Elastic Security app.
 38
 39#### Prerequisite Requirements:
 40- Fleet is required for Elastic Defend.
 41- To configure Fleet Server refer to the [documentation](https://www.elastic.co/guide/en/fleet/current/fleet-server.html).
 42
 43#### The following steps should be executed in order to add the Elastic Defend integration to your system:
 44- Go to the Kibana home page and click "Add integrations".
 45- In the query bar, search for "Elastic Defend" and select the integration to see more details about it.
 46- Click "Add Elastic Defend".
 47- Configure the integration name and optionally add a description.
 48- Select the type of environment you want to protect, either "Traditional Endpoints" or "Cloud Workloads".
 49- Select a configuration preset. Each preset comes with different default settings for Elastic Agent, you can further customize these later by configuring the Elastic Defend integration policy. [Helper guide](https://www.elastic.co/guide/en/security/current/configure-endpoint-integration-policy.html).
 50- We suggest selecting "Complete EDR (Endpoint Detection and Response)" as a configuration setting, that provides "All events; all preventions"
 51- Enter a name for the agent policy in "New agent policy name". If other agent policies already exist, you can click the "Existing hosts" tab and select an existing policy instead.
 52For more details on Elastic Agent configuration settings, refer to the [helper guide](https://www.elastic.co/guide/en/fleet/current/agent-policy.html).
 53- Click "Save and Continue".
 54- To complete the integration, select "Add Elastic Agent to your hosts" and continue to the next section to install the Elastic Agent on your hosts.
 55For more details on Elastic Defend refer to the [helper guide](https://www.elastic.co/guide/en/security/current/install-endpoint.html).
 56
 57### Windows Integration Setup
 58The Windows integration allows you to monitor the Windows OS, services, applications, and more.
 59
 60#### The following steps should be executed in order to add the Elastic Agent System integration "windows" to your system:
 61- Go to the Kibana home page and click “Add integrations”.
 62- In the query bar, search for “Windows” and select the integration to see more details about it.
 63- Click “Add Windows”.
 64- Configure the integration name and optionally add a description.
 65- Review optional and advanced settings accordingly.
 66- Add the newly installed “windows” to an existing or a new agent policy, and deploy the agent on your system from which windows log files are desirable.
 67- Click “Save and Continue”.
 68- For more details on the integration refer to the [helper guide](https://docs.elastic.co/integrations/windows).
 69"""
 70note = """## Triage and analysis
 71
 72### Investigating an Unusual Windows User
 73Detection alerts from this rule indicate activity for a rare and unusual Windows RDP (remote desktop) user. Here are some possible avenues of investigation:
 74- Consider the user as identified by the username field. Is the user part of a group who normally logs into Windows hosts using RDP (remote desktop protocol)? Is this logon activity part of an expected workflow for the user?
 75- Consider the source of the login. If the source is remote, could this be related to occasional troubleshooting or support activity by a vendor or an employee working remotely?"""
 76references = ["https://www.elastic.co/guide/en/security/current/prebuilt-ml-jobs.html"]
 77risk_score = 21
 78rule_id = "1781d055-5c66-4adf-9e93-fc0fa69550c9"
 79severity = "low"
 80tags = [
 81    "Domain: Endpoint",
 82    "OS: Windows",
 83    "Use Case: Threat Detection",
 84    "Rule Type: ML",
 85    "Rule Type: Machine Learning",
 86    "Tactic: Initial Access",
 87]
 88type = "machine_learning"
 89[[rule.threat]]
 90framework = "MITRE ATT&CK"
 91[[rule.threat.technique]]
 92id = "T1078"
 93name = "Valid Accounts"
 94reference = "https://attack.mitre.org/techniques/T1078/"
 95
 96
 97[rule.threat.tactic]
 98id = "TA0001"
 99name = "Initial Access"
100reference = "https://attack.mitre.org/tactics/TA0001/"

Triage and analysis

Investigating an Unusual Windows User

Detection alerts from this rule indicate activity for a rare and unusual Windows RDP (remote desktop) user. Here are some possible avenues of investigation:

  • Consider the user as identified by the username field. Is the user part of a group who normally logs into Windows hosts using RDP (remote desktop protocol)? Is this logon activity part of an expected workflow for the user?
  • Consider the source of the login. If the source is remote, could this be related to occasional troubleshooting or support activity by a vendor or an employee working remotely?

References

Related rules

to-top