If you are storing them to s3, you need to use temporary urls anyways so its already built in
File management in the Laravel application
Hi, In my Laravel application I want to implement for the first time file uploading and displaying for users.
To better explain, here's an example: A user submits a problem ticket through a form and attaches several files (e.g., two images, one video, and a PDF invoice). The text fields of the form are stored in the database, and the file names are also saved id DB. The actual files are stored on a configured server or cloud storage.
Later, users who have access to the ticket can view it along with all the attached media files.
For security reasons, I was considering generating Temporary URLs for these files. When a user visits the ticket, temporary links (valid for, say, one hour) would be generated and stored in the database or cache with an expiration time. All users accessing the ticket would use the same temporary URLs when needed.
Does this approach make sense? Or do you handle this differently in your applications? I would appreciate any advice.
Please or to participate in this conversation.