mirror of
https://github.com/suitenumerique/meet.git
synced 2026-08-24 17:27:02 +00:00
🔒️(backend) prevnt file change post checks
Before this commit, post a file check, the policy could be reused to change the verified file. Now, files are uplaoded to a temporary location, then inside a transaction that prevents concurrent calls, the file is copied to its final destination and the checks are run on that one. A new file can still be updated with the policy but it will never be read, etc. As part of this change, all files in the new tmp directory on s3 should have an expiration policy.
This commit is contained in:
@@ -426,7 +426,7 @@ def generate_upload_policy(file):
|
||||
Originally taken from https://github.com/suitenumerique/drive/blob/564822d31f071c6dfacd112ef4b7146c73077cd9/src/backend/core/api/utils.py#L102 # pylint: disable=line-too-long
|
||||
"""
|
||||
|
||||
key = file.file_key
|
||||
key = file.temporary_file_key
|
||||
|
||||
# This settings should be used if the backend application and the frontend application
|
||||
# can't connect to the object storage with the same domain. This is the case in the
|
||||
|
||||
Reference in New Issue
Block a user