Skip to content

Conversation

@bobvandevijver
Copy link
Member

Path calculation was broken after d007cf8. Instead, calculate the correct path earlier, and ensure path traversal is not possible.

Copilot AI review requested due to automatic review settings January 10, 2026 11:22
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes the thumbnail save location path calculation, which was broken after commit d007cf8. The fix calculates the correct thumbnail path earlier in the process and ensures path traversal attacks are prevented through proper canonicalization.

Changes:

  • Moved thumbnail path calculation to earlier in the thumbnail() method with proper canonicalization
  • Updated saveAsFile() method signature to accept pre-calculated thumbnail path instead of calculating it internally
  • Removed inline path construction in favor of the canonicalized path

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@bobvandevijver bobvandevijver changed the base branch from 6.0 to 5.2 January 10, 2026 11:28
Path calculation was broken after d007cf8.
Instead, calculate the correct path earlier, and ensure path traversal is not possible.
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