# GHSA-rhq6-9rgh-v45c: Pterodactyl Wings: Chmod operation can be used to change permissions of files outside of the server container

> An attacker with low privileges can change permissions of files outside the server container via symlink manipulation, potentially leading to privilege escalation.

- **Severity:** Not scored
- **Exploited in the wild:** Not known
- **Login needed:** Any signed-in user
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 26 Jun 2026
- **Also known as:** GO-2026-5814

## What is GHSA-rhq6-9rgh-v45c?

GHSA-rhq6-9rgh-v45c is a path traversal vulnerability in github.com/pterodactyl/wings, published on 26 Jun 2026. Any signed-in user can exploit it over the network, with no action from the victim.

### Official description

In `wings/internal/ufs/fs_unix.go` (line 92-94), this function is defined and is used to change permissions of files in the server:

```go
func (fs *UnixFS) fchmodat(op string, dirfd int, name string, mode FileMode) error {
   return ensurePathError(unix.Fchmodat(dirfd, name, uint32(mode), 0), op, name)
}
```

This call to the unix function `fchmodat(int fd, char* name, mode_t mode, int flags)`  does not have the flag `AT_SYMLINK_NOFOLLOW` set, and Wings neither checks or validate if the target file is a symlink. This allows one to change permissions of files or folders outside of the server container by making symlinks to existing files in the host and then chmoding it.

## Which versions are affected by GHSA-rhq6-9rgh-v45c?

3 open source packages ship an affected version, including github.com/pterodactyl/wings.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `github.com/pterodactyl/wings` | Go | From 1.11.9 | 1.12.2 |
| `github.com/pterodactyl/wings` | Go | From 1.11.9 | 1.12.2 |
| `github.com/pterodactyl/wings` | Go | From 1.11.9 | 1.12.2 |

## How do I fix GHSA-rhq6-9rgh-v45c?

Upgrade github.com/pterodactyl/wings to 1.12.2 or later.

## Is GHSA-rhq6-9rgh-v45c being exploited?

There is no known exploitation of GHSA-rhq6-9rgh-v45c in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for GHSA-rhq6-9rgh-v45c and fix it if it is affected.

What it is: GHSA-rhq6-9rgh-v45c is a path traversal vulnerability in github.com/pterodactyl/wings, published on 26 Jun 2026. Any signed-in user can exploit it over the network, with no action from the victim.
Exploitation: There is no known exploitation of GHSA-rhq6-9rgh-v45c in the wild and no public exploit code.

Affected packages and fixed versions:
- github.com/pterodactyl/wings (Go): affected from 1.11.9; fixed in 1.12.2
- github.com/pterodactyl/wings (Go): affected from 1.11.9; fixed in 1.12.2
- github.com/pterodactyl/wings (Go): affected from 1.11.9; fixed in 1.12.2

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/GHSA-rhq6-9rgh-v45c/ (Markdown: https://insights.sbomify.com/GHSA-rhq6-9rgh-v45c/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/GHSA-rhq6-9rgh-v45c

---
From sbomify Insights: https://insights.sbomify.com/GHSA-rhq6-9rgh-v45c/
Summaries are generated and may contain mistakes; the official description above is the record.
