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

Fix path traversal check #623

Merged
merged 3 commits into from
Jul 23, 2024
Merged

Fix path traversal check #623

merged 3 commits into from
Jul 23, 2024

Conversation

Pouyanpi
Copy link
Collaborator

This PR includes three key fixes:

  1. Prevents path traversal in the _get_rails function by rejecting config_ids that contain dangerous characters or sequences.
  2. Removes an unnecessary path check in the _get_rails function, simplifies the code and reducing the chance of errors.
  3. Modifies the server command in the CLI to correctly expand user paths, allowing for paths starting with '~' to be used.

fixes [4706127]

@Pouyanpi Pouyanpi requested a review from drazvan July 11, 2024 10:10
Copy link
Collaborator

@drazvan drazvan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Once you fix the signature for the commits, we can merge.

@drazvan drazvan merged commit d9a6215 into develop Jul 23, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants