Thursday, May 22, 2025
Homecyber securityHackers Exploiting Linux SSH Services to Deploy Malware

Hackers Exploiting Linux SSH Services to Deploy Malware

Published on

SIEM as a Service

Follow Us on Google News

SSH and RDP provide remote access to server machines (Linux and Windows respectively) for administration. Both protocols are vulnerable to brute-force attacks if solid passwords and access controls are not implemented.

Exposed SSH ports (default 22) are scanned by attackers who attempt unauthorized logins to gain control of the server.

Once in, they can deploy malware or steal data, while attackers can also use SSH to move laterally within a compromised network. 

- Advertisement - Google News
 The ID and password list used in a past Tsunami DDoS bot attack campaign
 The ID and password list used in a past Tsunami DDoS bot attack campaign

Attackers scan for open port 22 (SSH) and use dictionary attacks to gain access to Linux systems by first identifying potential targets with port scanners and banner grabbers, then leveraging SSH dictionary attack tools to try username and password combinations from a wordlist. 

Analyze any MaliciousURL, Files & Emails & Configuration With ANY RUN Start your Analysis

Successful logins allow them to steal configuration data and potentially install malware to find more vulnerable systems, as researchers identify these attacks by detecting multiple login failures.  

Detection logs upon multiple login failures
Detection logs upon multiple login failures

Attackers exploit weak SSH configurations to gain access to systems, and after compromising an initial server, some malware like Kinsing can self-propagate by using the stolen credentials to launch scans and dictionary attacks on other vulnerable machines. 

Kinsing’s propagation commands
Kinsing’s propagation commands

This process allows attackers to expand their reach and potentially build a network of infected devices for further malicious activities.

Security solutions can monitor suspicious commands issued through SSH connections to help administrators identify and stop such attacks before they spread. 

 The script responsible for SSH propagation
 The script responsible for SSH propagation

Kinsing malware leverages SSH key-based authentication for lateral movement. The malware’s “spre.sh” script extracts hostnames, ports, usernames, and key file locations from SSH configuration files and credential caches on infected systems. 

It then iterates through this data, attempting SSH logins with each key-user combination, and upon successful login, the script utilizes curl or wget to download and execute a malicious downloader script, further propagating Kinsing across the network. 

Detection logs of the behavior of reading a history file to obtain the user input record
Detection logs of the behavior of reading a history file to obtain the user input record

ASEC outlines a data collection strategy for identifying potential SSH propagation points, which focuses on system files and processes that might contain usernames, SSH hostnames, and public key locations. 

The collector will search for SSH configuration files (*/.ssh/config), bash history (*/.bash_history), system hosts file (*/etc/hosts), known SSH hosts (*/.ssh/known_hosts), and processes connected to port 22. 

To identify users, it will look for private keys (*/id_rsa and */.bash_history) and public keys (*/.ssh/config, */.bash_history, and *.pem), which aims to gather evidence of established SSH connections and credentials that could be leveraged to spread access across a network. 

They identify malicious lateral movement attempts by monitoring file access behavior. Specifically, it detects instances where a file attempts to read both a system log file and an SSH key file. 

The combination suggests the file might be malware trying to gather user login credentials from logs and then leverage SSH keys to spread to other machines on the network.

Looking for Full Data Breach Protection? Try Cynet's All-in-One Cybersecurity Platform for MSPs: Try Free Demo

Aman Mishra
Aman Mishra
Aman Mishra is a Security and privacy Reporter covering various data breach, cyber crime, malware, & vulnerability.

Latest articles

Versa Concerto 0-Day Flaw Enables Remote Code Execution by Bypassing Authentication

Security researchers have uncovered multiple critical vulnerabilities in Versa Concerto, a widely deployed network...

Hackers Targets Coinbase Users Targeted in Advanced Social Engineering Hack

Coinbase users have become the prime targets of an intricate social engineering campaign since...

Hackers Exploit PyBitmessage Library to Evade Antivirus and Network Security Detection

The AhnLab Security Intelligence Center (ASEC) has uncovered a new strain of backdoor malware...

Several GitLab Vulnerabilities Enable Attackers to Launch DoS Attacks

GitLab has issued critical security patches addressing 11 vulnerabilities across its Community Edition (CE)...

Resilience at Scale

Why Application Security is Non-Negotiable

The resilience of your digital infrastructure directly impacts your ability to scale. And yet, application security remains a critical weak link for most organizations.

Application Security is no longer just a defensive play—it’s the cornerstone of cyber resilience and sustainable growth. In this webinar, Karthik Krishnamoorthy (CTO of Indusface) and Phani Deepak Akella (VP of Marketing – Indusface), will share how AI-powered application security can help organizations build resilience by

Discussion points


Protecting at internet scale using AI and behavioral-based DDoS & bot mitigation.
Autonomously discovering external assets and remediating vulnerabilities within 72 hours, enabling secure, confident scaling.
Ensuring 100% application availability through platforms architected for failure resilience.
Eliminating silos with real-time correlation between attack surface and active threats for rapid, accurate mitigation

More like this

Versa Concerto 0-Day Flaw Enables Remote Code Execution by Bypassing Authentication

Security researchers have uncovered multiple critical vulnerabilities in Versa Concerto, a widely deployed network...

Hackers Targets Coinbase Users Targeted in Advanced Social Engineering Hack

Coinbase users have become the prime targets of an intricate social engineering campaign since...

Hackers Exploit PyBitmessage Library to Evade Antivirus and Network Security Detection

The AhnLab Security Intelligence Center (ASEC) has uncovered a new strain of backdoor malware...