Bug #70569 JSON_VALID allows mixed case in the keyword names

Submitted: 9 Oct 2013 18:46 Modified: 30 Oct 2013 18:37
Reporter: Sveta Smirnova Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: JSON User-defined function ( UDF ) Severity:S3 (Non-critical)
Version:0.2 OS:Any
Assigned to: CPU Architecture:Any

[9 Oct 2013 18:46] Sveta Smirnova
Description:
JSON_VALID treats words null, true, false with mixed case as valid while http://www.ietf.org/rfc/rfc4627.txt?number=4627 clearly says they must be in the lower case.

How to repeat:
mysql> select json_valid('{"a":nuLL}');
+--------------------------+
| json_valid('{"a":nuLL}') |
+--------------------------+
|                        1 |
+--------------------------+
1 row in set (0.00 sec)

mysql> select json_valid('{"a":True}');
+--------------------------+
| json_valid('{"a":True}') |
+--------------------------+
|                        1 |
+--------------------------+
1 row in set (0.00 sec)

mysql> select json_valid('{"a":FaLSE}');
+---------------------------+
| json_valid('{"a":FaLSE}') |
+---------------------------+
|                         1 |
+---------------------------+
1 row in set (0.00 sec)
[30 Oct 2013 18:37] Sveta Smirnova
Fixed in versions 0.2.1 and 0.3.0

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.048 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.