Number: AL20-017
Date: 3 June 2020
AUDIENCE
This Alert is intended for IT professionals and managers of notified organizations.
PURPOSE
An Alert is used to raise awareness of a recently identified cyber threat that may impact cyber information assets, and to provide additional detection and mitigation advice to recipients. The Canadian Centre for Cyber Security ("Cyber Centre") is also available to provide additional assistance regarding the content of this Alert to recipients as requested.
ASSESSMENT
The Cyber Centre is aware of continued exploitation of the Exim vulnerability (CVE-2019-10149), described in Alert AL19-012, published on 14 June 2019. Activity as recent as May 2020 has reportedly resulted in the compromise of Canadian victims.
Exploitation is initiated when a local or remote actor sends a command within a specially crafted email to a vulnerable Exim mail server. If successful, the injected command will execute as the message transfer agent (MTA) process owner (in most instances this is the system root account).
Successful exploitation of the vulnerability could result in the compromise of additional Exim servers, the installation of malware such as crypto mining software [Reference 1] or further infiltration of an organization’s network. The malicious commands may also attempt to gain persistence on the affected server by weakening security controls and adding additional user accounts to allow the actor remote access.
RECOMMENDED ACTIONS
The Cyber Centre recommends investigating potentially vulnerable systems to identify any changes that could indicate a successful compromise such as:
- Examine system logs for unusual or unauthorized activity.
- Examine all cron jobs for any unauthorized entries.
- If SSH is enabled on the server, ensure that the SSH server configuration file has not been edited to include unknown or suspicious changes and examine locally installed RSA authentication keys for any unauthorised additions.
- Monitor for any unusual SSH connections to the server.
- Check for recently added users with elevated privileges.
- Ensure there are no new privileged database user accounts.
- Ensure that firewall rules have not been modified in an effort to weaken security controls.
MITIGATION and MONITORING
The Cyber Centre recommends the following actions to defend and detect exploitation attempts of potentially vulnerable systems:
- Retrieve the latest patches for vulnerable versions of Exim and upgrade to the latest supported version. [Reference 2]
- Inspect mail logs to identify suspicious records within the “RCPT TO or MAIL FROM” fields. An example of patterns which would indicate attempts to compromise would resemble the following examples: [Reference 3 and 4]
- MAIL FROM:<${run{
- RCPT TO:<${run{
- ProofPoint Emerging Threats released a detection rule (SID: 2027442) for Suricata Intrusion Detection Systems (IDS) on 21 June 2019 to assist the detection of malicious activity matching the RCPT TO pattern. [Reference 5]
- Review IOCs originally provided in CCCS Alert AL19-012 [Reference 6] and alternate methods of detection and mitigation included in referenced NSA publication. [Reference 4]
REFERENCES
[Reference 1] Reported compromise for the purpose of crypto-currency mining:
https://www.cybereason.com/blog/new-pervasive-worm-exploiting-linux-exim-server-vulnerability
[Reference 2] To download the latest Exim updates:
https://exim.org/mirrors.html
[Reference 3] Early reporting of CVE-2019-10149
https://www.qualys.com/2019/06/05/cve-2019-10149/return-wizard-rce-exim.txt
[Reference 4] National Security Agency (US) Report describing CVE-2019-10149:
https://media.defense.gov/2020/May/28/2002306626/-1/-1/0/CSA%20Sandworm%20Actors%20Exploiting%20Vulnerability%20in%20Exim%20Transfer%20Agent%2020200528.pdf
[Reference 5] Emerging Threats Suricata signature for CVE-2019-10149:
https://doc.emergingthreats.net/bin/view/Main/2027442
[Reference 6] CCCS Alert AL19-012 on Exim vulnerability:
https://www.cyber.gc.ca/en/alerts/active-exploitation-exim-vulnerability-observed-wild
NOTE TO READERS
The Canadian Centre for Cyber Security (Cyber Centre) operates as part of the Communications Security Establishment. We are Canada's national authority on cyber security and we lead the government's response to cyber security events. As Canada's national computer security incident response team, the Cyber Centre works in close collaboration with government departments, critical infrastructure, Canadian businesses and international partners to prepare for, respond to, mitigate, and recover from cyber events. We do this by providing authoritative advice and support, and coordinating information sharing and incident response. The Cyber Centre is outward-facing, welcoming partnerships that help build a stronger, more resilient cyber space in Canada.
The Cyber Centre can be contacted at:
Email: contact@cyber.gc.ca
Toll Free: 1-833-CYBER-88 (1-833-292-3788)