-
Notifications
You must be signed in to change notification settings - Fork 1
Convert ValidateReadsetFilesAction and ImportReferenceSequencesAction to use FileLike #350
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
Conversation
| public static class DownloadTempImageAction extends ExportAction<TempImageAction> | ||
| { | ||
| @Override | ||
| public void export(TempImageAction form, HttpServletResponse response, BindException errors) throws Exception |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bbimber - Can you please provide a usage scenario for this action. Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are you asking for a way to test it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So I believe both DownloadTempImageAction and ConvertTextToFileAction are really old code that I dont see used anywhere. Rather than refactor them, those classes and the associated form classes could be removed. Let me know if you want to do this or have me do it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well was wondering how that action gets called and how the values for directory and filename gets set.
But sounds good, if they are not being used, then I can remove them as part of this PR.
…sociated form classes.
| for (String fn : form.getFileNames()) | ||
| { | ||
| File f = new File(baseDir, fn); | ||
| File f = FileSystemLike.toFile(baseDir.resolveChild(fn)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to convert back to File here. FileLike.exists() should work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nevermind I see that this gets passed to the job. That's a future story.
Merge discvr-25.3 to discvr-25.7
Rationale
Secure controller action/API endpoints that might allow unauthorized access to the files on the server by using FileLike instead of File (String, String) pattern.
Related Pull Requests
Changes