Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FilesystemStore is vulnerable to directory traversal attacks #275

Closed
1 task done
neild opened this issue Apr 17, 2024 · 2 comments
Closed
1 task done

FilesystemStore is vulnerable to directory traversal attacks #275

neild opened this issue Apr 17, 2024 · 2 comments
Labels

Comments

@neild
Copy link

neild commented Apr 17, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

I'm filing this a public issue, since it has already been disclosed elsewhere.

FilesystemStore uses an unsanitized Session.ID when constructing filenames. The documentation for Session states that ID "should not be used for user data", but I don't see anything in the documentation stating that IDs must not contain path traversal characters.

Path traversal in FilesystemStore is a component of CVE-2024-3400 in Palo Alto VPN (https://unit42.paloaltonetworks.com/cve-2024-3400/), an actively-exploited remote code execution attack. While this presumably stems from a misuse of the Session API, in which attacker-controlled data was used as a Session.ID, this demonstrates that lack of sanitization is quite hazardous.

The Go Vulnerability Database has assigned this the ID https://pkg.go.dev/vuln/GO-2024-2730.

Expected Behavior

No response

Steps To Reproduce

No response

Anything else?

No response

@neild neild added the bug label Apr 17, 2024
@mlec1
Copy link

mlec1 commented Apr 18, 2024

I think it has been fixed in this MR

#274

@jaitaiwan
Copy link

That's correc thanks @mlec1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants