Tailscale SSH Vulnerability: TS-2026-009 Root Access Bypass Explained

Tailscale SSH Vulnerability: TS-2026-009 Root Access Bypass Explained

A critical Tailscale SSH vulnerability (TS-2026-009) lets any user with SSH access to a Linux node escalate to root by connecting with a username starting with a dash. The flaw was disclosed today alongside five other Tailscale SSH vulnerabilities in version 1.98.9. If you use Tailscale SSH with autogroup:nonroot ACLs, you need to update immediately.

Vulnerability Details (CVE Pending)

Identifier: TS-2026-009 (CVE assignment pending) CVSS Score: Not yet assigned -- expected 8.8-9.8 (Privilege Escalation) Affected Versions: Tailscale < 1.98.9 on Linux Fixed Version: 1.98.9 (released July 14, 2026) Attack Vector: Local/Network (requires valid SSH access to a tailnet node) Impact: Full root shell access in violation of ACL policy

Root Cause: getent Argument Injection via Leading Dash

Tailscale SSH resolves usernames to system accounts by calling getent passwd <username> on the target host. The vulnerability stems from how Linux getent handles arguments that begin with a hyphen.

When a user connects via Tailscale SSH with the username -i, the following occurs:

  1. Tailscale passes -i directly to getent passwd -i
  2. The getent utility interprets -i as the flag --no-idn (disable Internationalized Domain Names)
  3. With this flag, getent prints the entire /etc/passwd file starting from the first entry
  4. The first entry in /etc/passwd is almost always root
  5. Tailscale reads this output, sees root as the resolved user, and spawns a root shell

This bypasses Tailscale ACLs entirely -- even if your policy restricts a user to autogroup:nonroot, the -i username tricks the resolver into returning root.

# Attacker runs this from their machine:
ssh [email protected]

# Result: Interactive root shell on target-node, despite ACLs saying otherwise

The fix in 1.98.9 is straightforward: Tailscale SSH now rejects any username that begins with a - character before passing it to getent.

Impact Assessment: What's at Risk

Who Is Affected

You are vulnerable if all of these are true:

  • You run Tailscale on Linux hosts
  • You use Tailscale SSH for remote access
  • Your ACLs rely on autogroup:nonroot to prevent root access
  • You have not upgraded to 1.98.9 or later

What an Attacker Gains

With a successful exploit, an attacker obtains:

  • Full root shell on the target Linux host
  • Ability to read/modify any file, install kernel modules, modify firewall rules
  • Persistence via SSH keys, cron jobs, or systemd services
  • Lateral movement to other tailnet nodes (if SSH keys or credentials are present)
  • Access to Tailscale's local API (/localapi/v0/) for tailnet manipulation

Real-World Exposure

Tailscale SSH is widely used for:

  • Developer access to production/staging servers
  • CI/CD runners connecting to build hosts
  • Homelab and self-hosted infrastructure management
  • Kubernetes node debugging via tailscale ssh

Any of these scenarios with autogroup:nonroot ACLs are at risk until patched.

Affected Systems: Who Needs to Act

EnvironmentAffected?Notes
Linux servers with Tailscale SSHYESPrimary target
macOS/Windows Tailscale SSHNogetent behavior differs
Tailscale SSH with autogroup:root allowedYESACL bypass still works, but root was already permitted
Tailscale SSH without autogroup:nonrootYESEscalation to root still possible
Containerized tailscaled (Docker/K8s)YESIf running on Linux host
Tailscale Funnel/Serve only (no SSH)NoDifferent vulns (TS-2026-005/007/008)

Check your version now:

tailscale version
# If output shows < 1.98.9, you are vulnerable

Mitigation & Patching: Step-by-Step Fix

Immediate Action (Do This First)

Upgrade to 1.98.9 or later on ALL Linux nodes running tailscaled:

# Debian/Ubuntu
curl -fsSL https://tailscale.com/install.sh | sh

# RHEL/Fedora/CentOS
dnf install -y tailscale
# or
yum install -y tailscale

# Arch Linux
pacman -S tailscale

# Docker (update image and restart containers)
docker pull tailscale/tailscale:latest
docker-compose up -d

# Kubernetes (update operator and node images)
# See: https://tailscale.com/docs/kubernetes-operator

Verify the fix:

tailscale version
# Should show 1.98.9 or higher

# Test that leading-dash usernames are rejected
ssh [email protected]
# Should fail with "permission denied" or "invalid username"

ACL Hardening (Defense in Depth)

Even after patching, review your ACLs:

// tailnet policy file (hujson)
// Explicitly deny root access for non-admin groups
{
  "acls": [
    {"action": "accept", "src": ["autogroup:admin"], "dst": ["*:22"]},
    {"action": "accept", "src": ["group:developers"], "dst": ["autogroup:nonroot:*:22"]},
    {"action": "deny", "src": ["*"], "dst": ["autogroup:root:*:22"]}
  ],
  "groups": {
    "group:developers": ["[email protected]", "[email protected]"]
  ],
  "autoGroups": {
    "nonroot": ["[email protected]", "[email protected]"],
    "root": ["[email protected]"]
  }
}

Key principles:

  • Use explicit autogroup:nonroot for developer access
  • Deny autogroup:root for all non-admin groups
  • Audit ssh grants in your policy regularly

Container/Kubernetes Specifics

If you run Tailscale in containers:

# Dockerfile - pin to fixed version
FROM tailscale/tailscale:v1.98.9
# ... rest of your Dockerfile

For Kubernetes Operator:

# Update operator
helm upgrade tailscale-operator tailscale/tailscale-operator   --namespace tailscale   --set operator.image.tag=v1.98.9

# Restart proxy pods to pick up new node image
kubectl rollout restart deployment -n tailscale

Detection: How to Tell If You Were Compromised

Check Authentication Logs

Look for SSH sessions with usernames starting with -:

# On the target node (as root)
grep 'sshd.*Accepted.*-.' /var/log/auth.log
# Or for systemd-journal systems:
journalctl -u sshd -g '-.' --since "2026-07-01"

Audit Tailscale SSH Sessions

Tailscale logs SSH connections to its own audit log:

# Via Tailscale CLI (requires admin)
tailscale audit-log --format=json | jq '.[] | select(.Type == "SSH")'

# Look for: "User": "-i" or any username starting with "-"

Check for Unexpected Root Sessions

# Recent root logins via SSH
last -i root | head -20

# Check for new SSH keys in root's authorized_keys
cat /root/.ssh/authorized_keys
ls -la /root/.ssh/

Indicators of Compromise

SignalLikelihood
SSH login with username -i, -u, --help, etc.Definite exploit attempt
New root SSH keys appearingHigh confidence
Unexpected sudo usage by non-admin usersMedium
Modified /etc/passwd, /etc/shadow, /etc/sudoersHigh
New systemd services or cron jobs as rootHigh

Frequently Asked Questions

Does this affect Tailscale on macOS or Windows?

No. The vulnerability is specific to Linux getent argument parsing. macOS and Windows use different user resolution mechanisms.

Is there a CVE number yet?

As of publication, CVE assignment is pending. Track Tailscale's security bulletins for updates.

Can this be exploited remotely without tailnet access?

No. The attacker must already have:

  1. A valid tailnet identity (authenticated to your tailnet)
  2. SSH access to at least one Linux node (granted via ACLs) This is a privilege escalation within the tailnet, not a remote unauthenticated RCE.

What if I don't use autogroup:nonroot?

You are still vulnerable. Any user with SSH access can escalate to root. The autogroup:nonroot restriction is what makes this a policy bypass -- without it, root access via SSH might be intended behavior for some users.

Are there other SSH-related vulns in this release?

Yes. TS-2026-009 is one of six Tailscale SSH vulnerabilities fixed in 1.98.9:

  • TS-2026-004: Unix socket forwarding symlink bypass
  • TS-2026-005: Non-root operator proxying privileged Unix sockets
  • TS-2026-006: Numeric UID 0 bypasses root restrictions
  • TS-2026-007: Services loopback port exposure
  • TS-2026-008: CPU pinning DoS via malformed HTTP paths
  • TS-2026-009: Leading-dash username to root (this article)

All are fixed in 1.98.9. Upgrade once, fix all six.

How do I know if my ACLs use autogroup:nonroot?

Check your tailnet policy file in the admin console (Settings -> Access Controls) or via CLI:

tailscale acl show

Search for autogroup:nonroot in the output.

Key Takeaways

  1. Update to 1.98.9 immediately -- This fixes TS-2026-009 plus five other SSH vulnerabilities
  2. The exploit is trivial -- ssh -i@node is all it takes; no special tools or payloads needed
  3. ACLs are bypassed -- autogroup:nonroot provides no protection on vulnerable versions
  4. Check your logs -- Search for usernames starting with - in SSH auth logs and Tailscale audit logs
  5. Harden ACLs -- Explicitly deny autogroup:root for non-admin groups as defense in depth
  6. All six SSH vulns ship together -- One upgrade fixes the entire class

Conclusion

TS-2026-009 is a textbook example of how a tiny input validation gap (accepting leading dashes in usernames) becomes a critical privilege escalation when combined with Unix command-line conventions (getent flag parsing). The fix is simple, but the window of exposure is significant -- any tailnet running Tailscale SSH on Linux before 1.98.9 should assume compromise is possible and audit accordingly.

Tailscale's disclosure is commendable: clear technical details, credit to reporters (Anthropic and Ada Logics), and a single version fixing six related issues. If you operate a tailnet, upgrade today.


Sources: Tailscale Security Bulletins | HN Discussion | Tailscale Changelog v1.98.9