]> git.ipfire.org Git - thirdparty/collectd.git/commit
collection3: Fix inappropriate usage of CGI:param
authorKentaro Hayashi <kenhys@gmail.com>
Mon, 8 Feb 2021 12:26:16 +0000 (21:26 +0900)
committerFlorian Forster <ff@octo.it>
Thu, 21 Dec 2023 20:13:37 +0000 (21:13 +0100)
commite085aa877717e4a1cb5b5a318daf72b3bdfde56c
tree3cbdcb740a1b106ffa16770f13d6236db790da51
parent4cc3426c90b8dd9eb294cf446a50289332e3605e
collection3: Fix inappropriate usage of CGI:param

When using collection3 as a CGI, the following error is sent to logs
repeatedly.

  FastCGI sent in stderr: "CGI::param called in list context from
  /usr/share/doc/collectd-core/examples/collection3/lib/Collectd/Graph/Common.pm
  line 529, this can lead to vulnerabilities. See the warning in
  "Fetching the value or values of a single named parameter" at
  /usr/share/perl5/CGI.pm line 412"

This is caused inappropriate usage of param(), it should be handled as
a scalar or should be treated by multi_param() explicitly.

Signed-off-by: Kentaro Hayashi <kenhys@gmail.com>
contrib/collection3/lib/Collectd/Graph/Common.pm