php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #60594 mysqlnd exposes 160 lines of stats in phpinfo
Submitted: 2011-12-22 18:30 UTC Modified: 2017-10-24 04:14 UTC
Votes:3
Avg. Score:3.0 ± 1.6
Reproduced:2 of 2 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: jakoch at web dot de Assigned:
Status: Open Package: MySQL related
PHP Version: trunk-SVN-2011-12-22 (SVN) OS:
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2011-12-22 18:30 UTC] jakoch at web dot de
Description:
------------
hello,

this is a change request: i think that it is not appropriate, that the mysqlnd extension exposes a list of 160 statistical items when calling the phpinfo() function.

i'm suggesting

a) to remove the client statistics from the phpinfo screen,
because phpinfo's focus is a bit more on configuration directives and not so much on statistics; every other extension could expose it there, too;
it's way too long to scroll through that list of stats-items

b) to make these statistics available via an mysqlnd_stats() or mysqlnd_info() function. 

anyway, you got my intention :)

best, jens


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-03-29 16:22 UTC] rgagnon24 at gmail dot com
I have to agree with jakoch.  This is not a security problem, but a slippery-slope thing.  phpinfo() is not a place to just display random statistics from any module that might feel like doing so.

There are already stats functions within PHP that can be used for this as documented on http://www.php.net/manual/en/mysqlnd.stats.php

IE: 
mysqli_get_client_stats()
mysqli_get_connection_stats()
mysqli_get_cache_stats()
 [2017-10-24 04:14 UTC] kalle@php.net
-Package: mysqlnd_uh +Package: MySQL related
 [2023-04-27 06:43 UTC] mediabusin54 at gmail dot com
Dashrathbhai Atmaramdas Pa or have heard of him. More info to visit: (https://www.paramshanti.org)github.com
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Mar 19 06:01:30 2024 UTC