If this is your first visit, check our documentation. To post, register or login.
Forums / Business Issues / Other Business Topics / PCI failure: web program allows cross-site scripting in query string (/index.php)

PCI failure: web program allows cross-site scripting in query string (/index.php)

Started by rixstix on 1 Sep 2017, 1:27 PM · Views: 92

Results 1 to 6 of 6
1 Sep 2017, 1:27 PM
#1
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

PCI failure: web program allows cross-site scripting in query string (/index.php)

The scanner hasn't had a problem with this since zc154 was installed but some change to the scanner within the last 30 days has deemed this a "High" risk now.

Steps to mitigate or verbiage to submit to ignore as a false positive would be appreciated.

Thanks
Rick

ZC 154
PHP 5.6.31
mySQL: 5.6.37

Last month: No PCI vulnerabilities
Today: PCI failure. web program allows cross-site scripting in query string (/index.php)

Risk: High (3)
Port: 443/tcp
Protocol: tcp
Threat ID: web_prog_cgi_xssquerystring

Information From Target:
Service: https
Sent:
GET /index.php?main_page=gv_faq?><SCRIPT>alert('SAINT')</SCRIPT> HTTP/1.0
Host: chainweavers.com
User-Agent: Mozilla/4.0
Connection: Keep-alive
Cookie: zenid=b7bk80q020hg0l1mft6n8l6pa5

Received:
<div class="buttonRow back"><a href="https://chainweavers.com/index.php?main_page=index&><SCRIPT>alert('SAINT')</SCRIPT>="><span class="cssButton normal_button button button_back" onmouseover="this.className='cssButtonHover normal_button button button_back button_backHover'" onmouseout="this.className='cssButton normal_button button button_back'"> Back </span></a></div>

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com

1 Sep 2017, 4:52 PM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Re: PCI failure: web program allows cross-site scripting in query string (/index.php)

My current test environment won't allow that javascript hack through at all.

  1. With the HTTP\1.0 after it I get a 406-Not-Acceptable header response in the browser and a blank page.
  2. Without the HTTP\1.0 I get the page-not-found page, without any malicious javascript code in the page source.

On your site I get similar:
3. With the HTTP\1.0 in the URL, I get a blank page.
4. Without the HTTP\1.0 I get your site map, and no evidence of malicious javascript.

Either you're giving the scanner whitelisted access to bypass browser or other security protections, or they're mislabeling what's actually happening.
Or they're not providing enough information.

In cases like this I usually ask them to have a human do the test manually and have them explain why their robot flags it as something different than what the end-user or hacker actually experiences.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

2 Sep 2017, 12:02 AM
#3
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: PCI failure: web program allows cross-site scripting in query string (/index.php)

Thank you DrByte,

I will do that on Tuesday when they are back in the office.
Yes, their IP addresses are required to be whitelisted.

I'm gonna guess that if I provide them your explanation, they will automatically approve a false positive.

Hardly a month goes by without some new "Thing" to cause a failure. Usually it is something that requires the host to fix.

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com

8 Sep 2017, 4:20 PM
#4
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: PCI failure: web program allows cross-site scripting in query string (/index.php)

Thank you DrByte,

Pasting your comment was all it took to satisfy the vulnerability.
Actually, the vulnerability score was downgraded from HIGH to LOW based upon your comments.

SmartScan calculated its own CVSS score for this vulnerability because it was not found in the NVD.
Cross-site scripting is not PCI compliant
No execution of code on path/parameter.
Removing - AN

Coffee and cookies headed your way.

DrByte:

My current test environment won't allow that javascript hack through at all.

  1. With the HTTP\1.0 after it I get a 406-Not-Acceptable header response in the browser and a blank page.
  2. Without the HTTP\1.0 I get the page-not-found page, without any malicious javascript code in the page source.

On your site I get similar:
3. With the HTTP\1.0 in the URL, I get a blank page.
4. Without the HTTP\1.0 I get your site map, and no evidence of malicious javascript.

Either you're giving the scanner whitelisted access to bypass browser or other security protections, or they're mislabeling what's actually happening.
Or they're not providing enough information.

In cases like this I usually ask them to have a human do the test manually and have them explain why their robot flags it as something different than what the end-user or hacker actually experiences.

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com

8 Sep 2017, 9:14 PM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Re: PCI failure: web program allows cross-site scripting in query string (/index.php)

RixStix:

SmartScan calculated its own CVSS score for this vulnerability because it was not found in the NVD.
They should give you a rebate for the time they wasted for you by making you (and me) point out their laziness. "not found in the NVD" means they're adding things to the tests that they haven't vetted in the wild, and they're crowdsourcing the data for their database ... basically making their users give them the data, instead of actually figuring it out themselves.

I have half a mind to recommend: next time they report a failure, just reply and tell them to "prove it". Wait for them to research it before accepting any scan results. :)
Or maybe I just need to go consume the coffee and cookies you sent. Thanks :)

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

8 Sep 2017, 10:59 PM
#6
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: PCI failure: web program allows cross-site scripting in query string (/index.php)

DrByte:

Or maybe I just need to go consume the coffee and cookies you sent. Thanks :)

Or Friday Evening Adult Beverage.....
Thanks again.

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com