High

TShock Security Escalation Exploit

  • Disclosed: 18.12.2024
  • Updated: 11.10.2026 11:23

Impact

An issue with the way OTAPI manages client connections results in stale UUIDs remaining on RemoteClient instances after a player disconnects.

Because of this, if the following conditions are met a player may assume the login state of a previously connected player:

  1. The server has UUID login enabled
  2. An authenticated player disconnects
  3. A subsequent player connects with a modified client that does not send the ClientUUID#68 packet during connection
  4. The server assigns the same RemoteClient object that belonged to the originally authenticated player to the newly connected player

Patches

TShock 5.2.1 hotfixes this issue. A more robust fix will be made to OTAPI itself.

Workarounds

Implement a RemoteClient reset event handler in a plugin like so:

csharp
public override void Initialize()
{
        On.Terraria.RemoteClient.Reset += RemoteClient_Reset;
}

private static void RemoteClient_Reset(On.Terraria.RemoteClient.orig_Reset orig, RemoteClient client)
{
	client.ClientUUID = null;
        orig(client);
}

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
.NET (NuGet) TShock >= 4.3.21, < 5.2.1 5.2.1

References

CVSS score -
CVSS vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:L/SI:H/SA:H
Weakness (CWE)
CWE-305, CWE-613, CWE-863
Platform
.NET (NuGet)
Package
TShock
Disclosed
18.12.2024
Updated
11.10.2026 11:23

Sources and licenses

OSV / GitHub Advisory Database - GHSA-hvm9-wc8j-mgrc - CC BY 4.0

Vulnerability history: TShock

All published vulnerabilities of this package (.NET (NuGet)), newest first. Shows whether this is a one-off slip or a package that needs watching.

Total entries
2
First → latest
12.2024 02.2025
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • High 1
  • Medium 1

Disclosures per year

  1. 2024: 1
  2. 2025: 1
  3. 2026: 0
  1. TShock Security Escalation Exploit this entry
    High ghsa-hvm9-wc8j-mgrc >= 4.3.21, < 5.2.1 5.2.1

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.