Add support for extension user files#3433
Merged
Alkarex merged 1 commit intoFreshRSS:masterfrom Feb 26, 2021
Merged
Conversation
Extension user files can be stored easily in the user folder instead of the static folder.
Member
Author
|
Please let me know if something is missing. |
Alkarex
reviewed
Feb 14, 2021
|
|
||
| // File to serve must be under a `ext_dir/static/` directory. | ||
| // User files do not need further validations | ||
| if (!$isStatic) { |
Member
There was a problem hiding this comment.
We should not allow arbitrary paths in the filesystem, so $path needs to be constrained somehow, at least preventing things such as ../
Member
Author
There was a problem hiding this comment.
This validation is skipped only for files generated by the extension configuration in the user folder. And the validation specifies that it must be in the user folder.
I am confused why we should be testing static for those files. Because in the event of the use of ../, it has to be contained in the user folder. So I guess the risks are really low.
Alkarex
added a commit
to Alkarex/FreshRSS
that referenced
this pull request
Dec 8, 2022
Details later. Due to FreshRSS#3433 (1.18.0)
Alkarex
added a commit
that referenced
this pull request
Dec 8, 2022
Details later. Due to #3433 (1.18.0)
Member
Member
Alkarex
added a commit
that referenced
this pull request
Dec 8, 2022
Details later. Due to #3433 (1.18.0)
Member
|
Taking advantage of this PR: #6267 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1709 (possibly)
Changes proposed in this pull request:
How to test the feature manually:
Pull request checklist:
Additional information can be found in the documentation.
Extension user files can be stored easily in the user folder instead of the
static folder.