I am planning on implementing an export-import functionality in Ruby on Rails.
Now since JSON can include JavaScript, I wonder if anyone could inject malicious code that can be run when I ask ruby to convert the JSON to a hash.
I am planning on implementing an export-import functionality in Ruby on Rails. Now since
Share
No, JSON can not include javascript code*. It is more strict version of Javascript object literal synthax.
http://json.org/
*- actually, javascript code could be included in JSON in string, but it won’t be parsed.