mirror of
https://github.com/discourse/discourse.git
synced 2024-12-15 06:43:40 +08:00
SECURITY: use strict JSON parsing when parsing backup metadata
This commit is contained in:
parent
ad7a13921f
commit
65831f4d3e
|
@ -220,7 +220,7 @@ module BackupRestore
|
|||
)
|
||||
end
|
||||
|
||||
data = Oj.load_file(@meta_filename)
|
||||
data = JSON.parse File.read(@meta_filename)
|
||||
raise "Failed to load metadata file." if !data
|
||||
data
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue
Block a user