mirror of
https://github.com/discourse/discourse.git
synced 2025-01-31 15:17:14 +08:00
SECURITY: Disallow symlinks when restoring uploads.
This commit is contained in:
parent
566f367fc3
commit
b49bf889f6
|
@ -380,7 +380,7 @@ module BackupRestore
|
|||
current_db_name = RailsMultisite::ConnectionManagement.current_db
|
||||
|
||||
execute_command(
|
||||
'rsync', '-avp', "#{tmp_uploads_path}/", "uploads/#{current_db_name}/",
|
||||
'rsync', '-avp', '--safe-links', "#{tmp_uploads_path}/", "uploads/#{current_db_name}/",
|
||||
failure_message: "Failed to restore uploads."
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user