Here is the php code:
$str='{"key":"'.chr(1).'"}';
$json=json_decode($str);
json_decode return null. So how should I process the $str in order to decode. (P.S. $str here is just a example, it may include chr(2), chr(10) and so on).
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Only characters in the range U+0020-U+0021, U+0023-U+005B, U+005D-U+10FFFF may appear unescaped in strings. Any other character must be escaped using the Unicode escape sequence. In your case use
\u0001instead.