|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #64539 FPM status page: query_string not properly JSON encoded
Submitted: 2013-03-28 13:03 UTC Modified: 2021-08-23 18:17 UTC
Avg. Score:3.9 ± 0.5
Reproduced:12 of 12 (100.0%)
Same Version:2 (16.7%)
Same OS:8 (66.7%)
From: benpro at benpro dot fr Assigned:
Status: Closed Package: FPM related
PHP Version: 7.4 OS: Debian 6.0.6
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: benpro at benpro dot fr
New email:
PHP Version: OS:


 [2013-03-28 13:03 UTC] benpro at benpro dot fr
Trying to set up a FPM status page using this one:;a=blob;f=sapi/fpm/;h=86492d73df0710d5dd0a0550292b3b48bbbfc302;hb=HEAD

I got "Error while parsing json: 'SyntaxError: JSON.parse: bad escaped character':

    "pool": "www",
    "process manager": "dynamic",
    "start time": 1364474757,
    "start since": 623,
    "accepted conn": 1998,
    "listen queue": 0,
    "max listen queue": 0,
    "listen queue len": 0,
    "idle processes": 135,
    "active processes": 2,
    "total processes": 137,
    "max active processes": 9,
    "max children reached": 0,
    "processes": [{
            "pid": 32124,
            "state": "Idle",
            "start time": 1364474757,
            "start since": 623,
            "requests": 15,
            "request duration": 2262,
            "request method": "GET",
            "request uri": "/hidden/timthumb.php?src=\'image+pour+le+moment", <<< Here is the bug?
            "content length": 0,
            "user": "-",
            "script": "/hidden/timthumb.php",
            "last request cpu": 0.00,
            "last request memory": 1310720
        }, OTHER....]

Sound like the JSON output of the status using "?json" in the query string is badly escaped?

Expected result:
Good parsing.

Actual result:
Parse error.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2013-03-31 11:58 UTC]
as the html says, "This is sample real-time status page for FPM. You can change it 
to better feet your needs."

maybe you need escape the backslash in request uri by yourself
 [2014-12-15 09:11 UTC] terry dot lee dot core at gmail dot com
Hi, could you explain what is the element "last request cpu": 0.00 unit. i have the data with the last request cpu:234, means use the cpu 234%?
 [2018-03-28 22:02 UTC]
-Package: Unknown/Other Function +Package: FPM related
 [2021-05-29 11:26 UTC] michiel at hazelhof dot nl
#66119 seems to be a duplicate but with a clearer description.

Because the output of status?json isn't properly encoded all kinds of status monitoring tools break when encountering unescaped characters.
 [2021-05-31 14:41 UTC] chris at kruining dot eu Here is a blogpost regarding this issue; The author of the post initially tried to work this out by encoding as well, but to no avail. And whichever piece of code that encodes to JSON -where-ever it may be- should -imo- be responsible for for properly encoding the contents.
 [2021-08-23 18:17 UTC]
-Summary: FPM status page: JSON parse error +Summary: FPM status page: query_string not properly JSON encoded -PHP Version: 5.3.23 +PHP Version: 7.4
 [2021-08-23 18:17 UTC]
Appears to be still unresolved.
 [2023-05-13 17:54 UTC]
Automatic comment on behalf of bukka
Log: Fix bug #64539: FPM status - query_string not properly JSON encoded
 [2023-05-13 17:54 UTC]
-Status: Open +Status: Closed
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Jul 24 19:01:28 2024 UTC