Issue #12951 has been reported by Matthew Boedicker.

----------------------------------------
Bug #12951: JSON.parse allows invalid string escapes
https://bugs.ruby-lang.org/issues/12951

* Author: Matthew Boedicker
* Status: Open
* Priority: Normal
* Assignee: 
* ruby -v: ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-darwin15]
* Backport: 2.1: UNKNOWN, 2.2: UNKNOWN, 2.3: UNKNOWN
----------------------------------------
According to jq and jsonlint, the following JSON is invalid:

~~~
{"x":"\$"}
~~~

but JSON.parse will parse it without complaint:

~~~
irb(main):002:0> JSON.parse('{"x":"\$"}')
=> {"x"=>"$"}
~~~



-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>