ThreatBeaconXSubscribe
HighMalware · 19 min read

When Tor Exits Turn Hostile: SSH Trust and Ebury

The October 2026 Tor exit-relay incident exposed the difference between encrypted connections, verified server identities and trustworthy endpoints. This analysis explains the SSH interception, the evidence linking two examined servers to Ebury, the meaning of the different relay counts, and the actions users and administrators should take. It also examines why relay removal, password changes and clean package checks are not enough by themselves.

Written by Sai Geethika·Published Oct 23, 2026

In early October 2026, attackers used compromised Tor relay infrastructure to redirect SSH connections toward intermediary servers. For users who accepted an incorrect server identity and entered a password, an encrypted session could become a credential-theft channel. Researcher kaba discovered the behavior after encountering an SSH host-key warning. 

The Tor Project subsequently warned Linux relay operators about compromised hosts and unauthorized changes to relay configurations. A separate operator investigation confirmed Ebury 1.8.3, an OpenSSH backdoor and credential stealer, on two examined servers.

This was not evidence that Tor’s encryption or SSH’s cryptography had been broken. It exposed three different security questions:

Was the network path manipulated? Was the correct server authenticated? Was the server itself trustworthy? 

What Readers Need to Know First

SSH, or Secure Shell, is commonly used to administer a remote computer. The SSH client is the user’s application, and the SSH server is the computer they intend to reach. Root means the highest administrative privilege on a typical Linux system. 

The most urgent case is a person who used password-authenticated SSH through Tor during the reported October 1–5 activity window, accepted an unfamiliar or changed host key, and continued the session. That password should be treated as potentially exposed, and the destination server should be reviewed for follow-on access. 

An SSH user who stopped at the warning did not disclose a password through that attempted login. A person who merely had Tor Browser installed is not automatically affected: other applications need to be configured separately to use Tor. 

For relay operators, the concern is different. A compromised host may remain infected even after its relay is excluded from Tor’s usable network.

Network containment and host recovery are separate tasks. 

The Numbers Describe Different Kinds of Evidence

The incident has several headline figures, but they are not interchangeable.

The consensus is the shared network directory Tor clients use when selecting relays. Consensus weight helps guide that selection. 

FindingWhat it establishesWhat it does not establish
333 relays directing SSH through 12 intermediary serversRedirection observed in kaba’s October 2 testing.That every connection was actively intercepted or every user lost a password.
377 relays matching suspicious policiesA broader set identified through public Tor directory records.Forensic proof of Ebury on every host.
59 operator/contact groupingsThe grouping method used by the directory analyst.Exactly 59 independently verified people.
7.46% peak usable-exit consensus-weight shareA time-specific infrastructure measurement.The percentage of all users, sessions or passwords compromised.
Two servers with confirmed EburyDetailed host evidence from one operator.A network-wide malware infection count.

Kaba’s network test, the operator’s host investigation and the directory reconstruction answer different questions. Their findings are complementary, but one should not be substituted for another. 

How Tor and SSH Protect Different Things

A typical connection from Tor to a public internet service passes through an entry relay, a middle relay and an exit relay. The exit makes the final connection to the destination. An onion-service connection is different and does not use a public exit relay.

Typical public-internet route:

SSH Client → Tor Entry → Middle Relay → Exit Relay → Destination Server

Tor helps separate a user’s network origin from the destination. SSH adds application-level protection: it authenticates the server, establishes encryption and then authenticates the user. 

Think of Tor as protecting the route and SSH as checking the identity of the person at the other end. A private route does not make an impostor trustworthy.

An exit can interfere with traffic passing through it, but merely occupying that position does not reveal properly authenticated SSH plaintext. The attack had to cross another boundary: convincing the client to communicate with an attacker-controlled SSH endpoint. 

What Changed in the SSH Connection

Kaba’s investigation found two behaviors. Some tested connections received a substitute SSH host key. Others passed through the same intermediary infrastructure without changing the observed key.

Redirection therefore did not always mean active decryption in that particular test. 

When an intermediary terminated the SSH connection and its key was accepted, the user was speaking securely to the intermediary—not securely to the intended server. The intermediary could receive a password and establish a separate session with the genuine destination.

Client → Encrypted Session A → Intermediary → Encrypted Session B → Real Server

The presence of encryption on both links does not protect the contents from the system between them. That system is an endpoint of both sessions.

This is why a working terminal and successful-looking login are not proof that the original server identity was verified. 

Kaba’s honeypot recorded privilege checks and an attempted installer execution following interception. This supports attempted follow-on compromise. It does not establish successful Ebury installation on every destination reached through an affected relay. 

Host Keys and Login Keys Are Not the Same

An SSH host key identifies the server. A user authentication key helps prove that the person connecting is allowed to log in.

Confusing these two roles can lead to a dangerous conclusion:

“I use keys, so any server presenting a key must be safe.”

That is not how SSH authentication works. 

There are two important host-trust situations.

An existing server presents a different key.
This can indicate interception, but a legitimate rebuild or planned rotation can also change a key. Stop and verify through an independent trusted channel before changing the saved record.

A server is contacted for the first time.
There may be no changed-key warning because no previous key is known. Blindly accepting the initial key can establish trust in an impostor. 

The practical rule is verify before authenticating. Do not treat deleting a known_hosts entry as a security fix.

OpenSSH’s StrictHostKeyChecking yes rejects changed keys and requires new keys to be provisioned rather than accepted automatically. Deploy it with a reliable way to distribute trusted keys or host certificates; otherwise legitimate work may be interrupted. 

Why Public-Key Authentication Helps—and Where It Stops

A password is a reusable secret. A malicious endpoint that receives it may try it against the real server.

SSH public-key authentication instead signs data that includes the session identifier. A signature generated for the intermediary’s session cannot simply authenticate a different session with the real server. That blocks the straightforward password-relay path. 

However, it does not make the intermediary trustworthy. A fake endpoint could still present a fake shell and receive commands or secrets the user enters. Nor does public-key authentication clean an already infected client or server.

Agent forwarding creates another boundary. OpenSSH warns that a remote host with access to a forwarded agent may use it for authentication without obtaining the private key itself. Avoid forwarding agents into untrusted environments. 

The stronger combination is verified host identity, appropriate user authentication and healthy endpoints—not any single setting.

Independent Verification Must Be Genuinely Independent

A fingerprint obtained through the same suspicious route is not an independent check.

OpenSSH’s ssh-keyscan collects keys, but it does not establish that they belong to the intended server. Its documentation explicitly warns about accepting scanned keys without verification. 

For an organization, a practical approach is to distribute trusted host identities through an authenticated inventory or a managed host-certificate system. For an individual administrator, a known management console or an already established trusted contact can provide a separate verification route.

Changing Tor circuits and seeing a different result may be an investigative clue. It does not replace independent authentication, and it does not undo a password disclosure that already occurred.

Timeline: Preparation, Interception and Disclosure

DateObservation and limitation
August 28, 2026One operator’s management server was accessed using an already-known password. Ebury was installed on that server and another examined system. This is not the proven start date for every affected host.
October 1–4Public directory records showed the suspicious policy changes.
October 2Kaba detected an unexpected SSH key, tested exit behavior and contacted Tor’s network-health team.
October 4Relay restrictions began entering authority votes and the consensus.
October 5, 17:00 UTCThe directory reconstruction found no relay still advertising either suspicious policy in the consensus.
October 7–9The operator’s findings, researcher follow-up and directory analysis were published.
October 20–21Kaba’s account and wider reporting brought the incident to broader attention.

This combines the sources without extending one operator’s August timeline to the whole incident.

The directory reconstruction’s follow-up observations run through October 9; they are not a live guarantee about today’s relay population. 

What an Exit-Policy Change Actually Does

An exit policy states which destination ports a relay permits. Changing that policy changes the types of connections for which the relay is eligible.

The public reconstruction found that the suspicious changes opened SSH on 342 relays that previously did not permit it. It also identified 24 previous non-exits that became exits. These findings support a coordinated change in traffic eligibility, but do not reveal the initial intrusion method. 

The analytical implication is important: modifying an existing trusted operator’s infrastructure can change its security role without introducing a visibly new relay operator.

Defenders should therefore monitor changes from an approved baseline, not only whether a relay has existed for a long time. A long history is not evidence that a server remains uncompromised.

Why the Mail Changes Did Not Automatically Break TLS

The suspicious policies rejected encrypted mail ports and, in one variant, permitted plaintext-capable POP3 and IMAP ports. Some source wording describes this as leaving only unencrypted mail. The protocol distinction needs care. 

Tor selects an eligible exit for the requested destination port. Blocking IMAPS on port 993 does not itself convert the request into IMAP on port 143. The connection may use a different eligible exit or fail. 

Additionally, ports 110 and 143 can support a TLS upgrade. Whether data remains readable depends on the mail client’s configuration, certificate checks and fallback behavior—not on the port number alone. 

The evidence supports changed traffic selection and potential opportunities to capture insecure traffic. It does not prove universal email decryption or an automatic TLS downgrade.

For users, the practical response is to require encrypted mail access and valid certificates, and not accept insecure fallback merely because a connection fails. RFC 8314 recommends moving away from cleartext email submission and access. 

Why “Ten Percent of Exits” Is Not Your Personal Risk

Tor’s path selection is not an equal-probability draw from every relay. Eligibility, bandwidth weights and path constraints influence selection. 

The relevant question for an SSH connection is which relays were eligible for that destination at that time—not simply how many exits existed.

Credential exposure also required additional conditions: active interception, acceptance of the wrong identity and disclosure of a reusable secret. The published sources do not provide enough information to calculate a reliable probability for an individual user.

This makes the 7.46% figure a network measurement, not a password-theft rate. Treating it as a compromise percentage would hide the very controls that could stop the attack. 

Ebury Introduces a Second Credential-Theft Location

The malicious intermediary is one place a password can be stolen. An infected legitimate server is another.

Ebury is an OpenSSH backdoor and credential stealer that runs through shared-library manipulation. It can alter authentication behavior and conceal its activity as a user-space rootkit. 

Even a correctly encrypted, correctly host-authenticated connection must eventually deliver authentication information to the real server. Encryption cannot protect that information from malicious software operating inside the receiving system.

That distinction explains why host-key verification and server-integrity checks must both exist. One detects an impostor in the route; the other addresses a real destination that is no longer safe. 

What Went Wrong Around the Management Server

The operator’s post-mortem described password reuse across SSH, administrative elevation and an encrypted backup. A plaintext helper script also contained the password, and the backup held sensitive administrative and relay keys. The attacker already knew the login password; its original source remained unknown.

The analytical lesson is concentrated trust. A management server can connect many systems, hold privileged access and provide a familiar source address. Compromising it may make later connections resemble ordinary administration.

An encrypted backup is also not an independent safeguard when its decryption password is the same secret already exposed elsewhere. Keeping keys in such a backup on a reachable server does not make those keys genuinely offline.

This argues for separating recovery secrets, limiting management-host duties and reviewing downstream systems—not only rebuilding the first machine found infected.

How Clean File Checks Can Miss a Dirty Runtime

In the examined case, an added malicious libkeyutils library and a changed symbolic link affected what loaded, while packaged components still passed integrity checks.

A shared library supplies supporting code to a program. A symbolic link is a filesystem reference that can point to another file. Those relationships matter because an unchanged main executable can still load unexpected code. 

A package checksum answers a limited question:

Does this checked file match the expected package content?

It is not a complete statement about all additional files, symbolic-link destinations, runtime dependencies or process memory.

MITRE documents Ebury’s use of shared modules and dynamic-linker manipulation. This is why the scope of an investigation must include the software-loading relationship rather than only the main SSH executable. 

A useful inspection model is:

Expected Package → Actual Link Target → Loaded Library → Running Process → Externally Observed Behavior

The model is an investigative recommendation, not a claim that one tool automatically verifies every layer.

On a rootkit-compromised host, local tools may themselves receive misleading information. Trusted recovery or offline analysis provides a stronger basis for validation. 

Logs Can Be Incomplete Without the Attack Being Absent

The operator reported truncated logs, manipulated timestamps and reduced SSH logging. Such changes weaken attempts to reconstruct who logged in and what happened afterward.

MITRE describes log clearing and timestomping as ways to conceal activity. A quiet authentication log or an old-looking file date therefore cannot independently establish that a host is clean. 

For analysts, unexplained gaps should become questions rather than immediate verdicts. Compare off-host logs, management records, package changes and external relay observations. Also investigate legitimate explanations, such as automation or maintenance, before calling an anomaly malicious.

The objective is not to collect more logs indiscriminately. It is to retain independent evidence that a compromised host cannot rewrite by itself.

How the Investigation Combined Different Viewpoints

Kaba checked the server identity seen by the client and the source address observed by a controlled destination. The operator examined affected hosts. The directory analyst reconstructed public policy changes. 

Those viewpoints can disagree for legitimate reasons. A network test observes a particular moment, a descriptor records advertised behavior, and a disk image records surviving host artifacts. None is a complete substitute for the others.

This suggests a practical investigation table: record what each observation proves, its timestamp, its collection method and what it cannot prove. For example, an unexpected host key supports endpoint substitution; it does not count how many passwords were entered.

Testing should use authorized systems and synthetic traffic. Defenders should not collect unrelated Tor users’ credentials or session contents in the name of checking relay health.

What Earlier Incidents Add—and What They Do Not

The Tor Project’s 2020 advisory described malicious exits interfering with HTTP-to-HTTPS redirects on selected cryptocurrency sites. That exploited unauthenticated HTTP, not a mathematical break in HTTPS. 

ESET’s 2024 Ebury research documented SSH interception within data centers and hosting-provider compromises in earlier operations. It estimated roughly 400,000 historical server infections since 2009, including more than 100,000 still infected in late 2023. Those figures belong to the earlier research, not the 2026 Tor incident. 

This background shows that path manipulation, credential theft and server compromise can reinforce one another. It does not prove that the same infrastructure, initial-access method or complete actor set carried out every incident.

Similarly, hosting concentration in the 2026 directory analysis is a lead for investigation—not proof of a hosting-provider breach. 

Three Independent Checks for This Attack Class

The article’s added contribution is a practical synthesis of established controls. It is not a newly discovered exploitation technique.

CheckQuestion to answerEvidence to use
Route behaviorDoes the externally observed relay behavior match the approved configuration?Descriptors, consensus history and authorized test connections.
Server identityDoes the presented SSH key match an independently trusted identity?Managed host keys, host certificates and verified change records.
Endpoint integrityIs the actual authentication environment trustworthy?Trusted file and runtime analysis, off-host logs and forensic evidence.

The value comes from keeping the checks independent.

A familiar IP does not replace identity verification. A correct key does not replace host investigation. A clean package report does not replace checking what the process loaded.

The same reasoning applies beyond Tor to jump servers, VPN gateways, remote administration platforms and other systems that sit between users and important services.

A Practical Exposure Guide

The following is a triage aid, not a definitive diagnosis. It applies the reported interception conditions and SSH protocol properties. 

Your situationAppropriate response
You only used Tor Browser for ordinary HTTPS browsing.This SSH incident alone does not show that your passwords were stolen. Keep browser and certificate protections enabled.
You used SSH through Tor but stopped at an identity warning.Preserve the warning and verify the server identity before reconnecting.
You accepted an unfamiliar key and entered a password during the reported window.Treat the secret as potentially exposed; rotate it through a verified clean path and investigate destination access.
You used public-key authentication without accepting an incorrect identity.The described password-relay path does not establish exposure; review any separate anomalies.
You accepted a hostile identity, forwarded an agent or typed other secrets.Review those separate exposures even if no SSH password was used.
You administered a host suspected of Ebury infection.Escalate to host-compromise response; do not type recovery passwords into it.
You operate a relay with unexplained configuration changes.Contain it, preserve evidence and coordinate with Tor’s network-health team.

Detection That Is Useful Without Becoming Noisy

Relay configuration drift.
Compare approved exit policies and identities with externally published records. Review instance-specific configurations as well as included files. Tor’s advisory specifically calls for checking unexpected exit flags, policy changes and host-level changes. 

SSH identity anomalies.
Preserve unexpected host fingerprints, the intended destination and relevant timestamps. A saved key proves a trust record exists, not that a password was necessarily entered. Correlate it with available session or server evidence. 

Unexpected host behavior.
Investigate unusual library targets, unexplained processes, logging changes and outbound connections together. MITRE recommends correlating network or configuration anomalies with subsequent authentication behavior when investigating adversary-in-the-middle activity. 

False-positive control.
Routine SSH traffic, legitimate logging processes and planned key rotations are common. Escalate based on unauthorized changes and corroborating evidence, not a filename, port or Tor association alone.

No detection accuracy or false-positive rate is claimed here. These are evidence-driven hunting priorities that require local testing.

Host Artifacts to Preserve and Investigate

The operator published these observations from the examined systems. They are variant-specific investigative leads, not a universal Ebury signature set. 

ArtifactRelevant context
/usr/lib/x86_64-linux-gnu/libkeyutils.so.1.10.2Unexpected unpackaged library with setuid permissions.
libkeyutils.so.1Symbolic link resolving to the unexpected library.
@event-0YsOG9WSOEReported abstract UNIX socket.
/sbin/rsyslogdA masquerading process in an unexpected service context.

Do not delete genuine logging components merely because a name matches. Preserve evidence and establish the file’s provenance and process context.

The operator also reported installation-specific differences, so a single file hash would not identify every instance.

Recovery: Removing the Relay Is Only the First Step

A BadExit flag tells clients not to use a relay as an exit. MiddleOnly limits it to the middle position. Exclusion from the usable consensus is a different network state.

None of these measures establishes that the underlying host has been disinfected. A server may still be online and publishing information while clients no longer select it. 

Use three closure conditions in the response plan.

Network closure: The affected infrastructure no longer carries the relevant user traffic.

Host closure: Compromised machines are rebuilt or otherwise restored using a trusted recovery process, with their management path investigated.

Identity closure: Exposed passwords, user keys, host keys, relay identities and recovery secrets are reviewed and replaced where necessary.

This is a response model derived from the incident. Its purpose is to prevent a common mistake: declaring success because one indicator disappeared while stolen credentials or another infected host remained usable.

Actions for Users and Administrators

Users should stop at identity warnings.
Verify changes independently and avoid disabling checks to make a connection work. Rotate potentially exposed passwords from a clean device through an authenticated route. Review reused secrets and any sensitive material entered during a suspicious session. 

Administrators should prefer tested public-key authentication and suitable multifactor protection.
Review both password and keyboard-interactive settings; they are distinct mechanisms. Validate the effective configuration and maintain a tested recovery path before tightening access controls. 

Management infrastructure needs extra protection.
Limit reachable services, separate backup and recovery secrets from routine credentials, and review trust relationships between jump hosts and destination servers. Password reuse can permit movement between systems even when each individual login appears valid. 

Relay operators should follow the Tor Project’s recovery guidance.
Take suspected relays offline, preserve disk and logs, reinstall rather than clean in place, generate new relay identities and rotate credentials on the host. Coordinate through the project’s published reporting channel.

Responders should balance containment and evidence preservation.
Keep the system from exposing more users, but capture volatile evidence where feasible before a reboot destroys it. Do not reconnect restored servers with secrets still trusted by compromised systems. 

Evidence Worth Retaining

A useful case record includes the intended SSH destination, observed fingerprint, approximate session time, authentication method and whether any secret was entered.

For hosts, preserve relevant disk and memory evidence, logs, package records, library-link relationships and relay configuration history. 

Do not put real passwords into incident tickets. Record that a secret may be exposed and track its revocation separately.

Keep collection times and time zones explicit. Separate the date a compromise was observed from the date it was reported. This is especially important here because August host activity, October interception and later public reporting represent different phases.

Would a VPN or Onion Service Solve This?

A VPN can change the network route, but it does not turn an unverified SSH host key into a verified one, and it does not clean Ebury from an endpoint. This follows from the separation between transport protection, server authentication and endpoint security. 

An onion-service endpoint removes the public exit-relay leg when the service is accessed through its authentic onion address. It can therefore remove this particular interception position. It still requires trustworthy systems and appropriate application authentication. 

For ordinary browsing, retain Tor Browser’s HTTPS protections and respect certificate warnings. The Tor Project explains that proceeding to an HTTP site accepts the risk of unencrypted communication. 

These are complementary safeguards, not replacements for checking the actual server and its operating environment.

What Remains Unknown

The sources do not establish a single initial-access method across all operators, a complete victim count, successful malware installation after every interception, or Ebury infection on every policy-matching host. They also do not establish that a hosting provider was breached. 

The operator’s original password source remained unresolved. The absence of ordinary login records does not reconstruct every action, and historical directory records do not independently reveal a malware binary.

This article compares published observations and official technical documentation. It does not claim a new exit scan, independent disk examination or tested detection performance.

Threat Assessment and Conclusion

High severity is appropriate as an editorial assessment of the combined interception and confirmed host-compromise risk. A verified root-level infection demands urgent response regardless of the article’s category.

The incident illustrates three failures that must not be collapsed into one: a manipulated route, an accepted impostor identity and a compromised legitimate endpoint.

Tor’s privacy protections do not remove the need for SSH host verification. SSH encryption does not protect a password from the endpoint receiving it. Network removal does not revoke secrets already stolen.

The durable lesson is:

Verify the route’s behavior, authenticate the intended server and investigate the system behind that identity.

Recovery should restore all three—not merely make the warning disappear.

Indicators of Compromise

TypeValueNotes
IPv4185.225.226[.]62—
SHA-256SSH Fingerprints: 6baCZCPsl+AfQuujUS81fMEE/C7UeJ+AwjrImqmDB3E—
SHA-256SSH Fingerprints: dvACokMYcXJ2om4wuS+TvdtjrAgPK7rC7ZQHDgvBHzk—
SHA-256SSH Fingerprints: KlICz/B59619CpuQdGzgmmvzWBfTMUJ77EwihTYobuo—
SHA-256SSH Fingerprints: OfLY0uF9SwOW9xVjiMXZGDfk6Atmz6CbHy4epknLm8Y—

MITRE ATT&CK Mapping

T1557- Adversary-in-the-MiddleT1078.003- Valid Accounts: Local AccountsT1021.004- Remote Services: SSHT1556- Modify Authentication ProcessT1014- RootkitT1036.005- Masquerading: Match Legitimate Resource Name or LocationT1685.006- Disable or Modify Tools: Clear Linux or Mac System LogsT1070.006- Indicator Removal: Timestomp