close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

SQL Injection

Thread began 8/18/2010 12:44 pm by lorgain396837 | Last modified 9/15/2010 10:02 am by Jason Byrnes | 2638 views | 22 replies |

lorgain396837

SQL Injection

After running McAfee secure scan on my Powerstore I found a few security issues I need help fixing. The largest seems to be SQL injection. I read in other post on the forum that this shouldn't be an issue with PS. Any advice is much appreciated.

Sign in to reply to this post

Jason ByrnesWebAssist

What version of power store?


If it is PowerStore 3, go to your download center for power and look in the known issues section for the "PowerStore 3: Support Fix - Scripting Vulnerability" download. this should fix the problem.

If you still have an issue, please post the results of the mcaffee scan, this will hep us to identify where the problem is.

Sign in to reply to this post

lorgain396837

Cross site scripting

Thanks, that fixed the SQL injection but now the scan is finding a cross site scripting error. I have to make this PCI compliant before handing it over to the client. I have not changed or added to any of the php. The only changes I have made to the site have all been on the CSS files. Help please.

Sign in to reply to this post

Jason ByrnesWebAssist

can you post the scan report? this will help me determine what needs to be looked at.

Sign in to reply to this post

lorgain396837

Jason what format would you like me to paste it in? I have attached a screenshot of what it is telling me. Let me know if you need it in a different format or a different part of the scan.

Attached Files
PCIcomplianceTest.pdf
Sign in to reply to this post

Jason ByrnesWebAssist

hmmm, in the WA_ValidationToolkit/WAVT_ValidatedForm_PHP.php file, change line 20:

php:
return $retVal;



to:

php:
return str_replace("<","&lt;",str_replace(">","&gt;",str_replace('"',"&quot;",$retVal)));
Sign in to reply to this post

lorgain396837

Thanks, I have a few more problems with cross site scripting. I attached a pdf with a copy of the vulnerabilities.

Attached Files
VulnerabilityReport8-24.pdf
Sign in to reply to this post

Jason ByrnesWebAssist

on the admin/index.php page

change:

php:
<form id="form1" name="form1" method="post"  action="index.php?failed=1<?php echo(isset($_SERVER["QUERY_STRING"])?"&".($_SERVER["QUERY_STRING"]):""); ?>">




to:

php:
<form id="form1" name="form1" method="post"  action="index.php?failed=1">
Sign in to reply to this post

lorgain396837

Thanks Jason, I have one more and then the site should be PCI Compliant. I have attached the PDF with the vulnerability.

Attached Files
VulnerabilityReport8-25.pdf
Sign in to reply to this post

Jason ByrnesWebAssist

the report is complaining about the products results page, but the price fields should not have an issue there, they are validated to be numeric.

the issue should only be on the search page.


on the products search page, find the following two lines of code:


php:
<input type="text" name="S_ProductPrice" id="S_ProductPrice" value="<?php echo((isset($_GET["S_ProductPrice"]))?$_GET["S_ProductPrice"]:""?>" size="10" onblur="if (document.getElementById('priceRangeServerValidation')) document.getElementById('priceRangeServerValidation').style.display='none';" style="width: 114px;" />



and:

php:
<input name="S_ProductPrice2" type="text" id="S_ProductPrice2" onblur="if (document.getElementById('priceRangeServerValidation')) document.getElementById('priceRangeServerValidation').style.display='none';" value="<?php echo((isset($_GET["S_ProductPrice2"]))?$_GET["S_ProductPrice2"]:""?>" size="10" style="width: 114px;" />





and checnge them to:

php:
<input type="text" name="S_ProductPrice" id="S_ProductPrice" value="<?php echo((isset($_GET["S_ProductPrice"]))?str_replace("<","%3C",str_replace(">","%3E",str_replace('"',"%22"$_GET["S_ProductPrice"]))):""?>" size="10" onblur="if (document.getElementById('priceRangeServerValidation')) document.getElementById('priceRangeServerValidation').style.display='none';" style="width: 114px;" />



and:

php:
<input name="S_ProductPrice2" type="text" id="S_ProductPrice2" onblur="if (document.getElementById('priceRangeServerValidation')) document.getElementById('priceRangeServerValidation').style.display='none';" value="<?php echo((isset($_GET["S_ProductPrice2"]))?str_replace("<","%3C",str_replace(">","%3E",str_replace('"',"%22"$_GET["S_ProductPrice2"]))):""?>" size="10" style="width: 114px;" />
Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...