Jump to content

[SOLVED] Beta PHP Script


sawade

Recommended Posts

Hello. 

 

I am testing a script to make sure it is capturing user IP addresses correctly, please use my email address in the email field (dontuwish2105 [at] yahoo [dot] com).

 

https://www.medsolutionservices.com/secureforms/forms/demo/hipaaprivacy.php

 

Is the form.

 

The ownership file is on the main home page in the footer.

 

OR - https://www.medsolutionservices.com/secureforms/phpfreaks.txt

 

Thanks!

Link to comment
Share on other sites

Microsoft IIs5 NTLM authentication:

 

a remote attacker could bypass this.

Fix: upgrade IISv5 to IISV6

WebDav|TRACE|TRACK Enabled:

attackers may use these methods to gain remote access to a script.

 

FIx: disable these methods via server

 

 

Link to comment
Share on other sites

think i may have tested the wrong site LOL you are running unix not Windows  >:(

 

anyhow this is what i got

 

Outdated Apache SSL:

Fix: Update to SSL  2.8.19 or greater

 

Cross Site Scripting(XSS):

 

User can attack the script remotely and byass it completely or gain access.

 

Unfiltered variables: fname,lname,ssn,mname,email,dobyr

Fix: use strip_tags(), trim() to filter vars.

Link to comment
Share on other sites

I don't know how I would update the ssl, it's not mine. Co-worker bought it.

 

Fixed variables.

 

For the XSS:  When the site is finished and is moved, all form php files will be moved off of the public_html directory.  Will that fix this?

Link to comment
Share on other sites

also rechecked your cross site scripting its getting alot better.

 

went from 600 attacks to 200. so it isnt getting all of it. >:(

 

Check out: XSS function

 

this might pick up the left over attacks.

 

 

 

 

Made some more updates.  My list of these updates to make to my other forms is growing.  LOL

 

That's the point of all this though right.  Trial and error.  Getting it wrong is how we learn.  ::):P

Link to comment
Share on other sites

its all been fixed except for:

Cross Site Scripting in URI:

 

Affected file: demo.php

Unfiltered variable(s): PHP_SELF,REQUEST_URI,SCRIPT_URL,SCRIPT_URI

 

FIx: filter the variable

 

Email Adress Found(3):

 

Affected Files: demo.php,demo2.php,hipaaprivacy.php

 

 

 

 

Link to comment
Share on other sites

its all been fixed except for:

Cross Site Scripting in URI:

 

Affected file: demo.php

Unfiltered variable(s): PHP_SELF,REQUEST_URI,SCRIPT_URL,SCRIPT_URI

 

FIx: filter the variable

 

Email Adress Found(3):

 

Affected Files: demo.php,demo2.php,hipaaprivacy.php

 

Phew.  That was a lot of code to go through.  But it's all done.  All variables filtered and all email addresses removed.

Link to comment
Share on other sites

its all been fixed except for:

Cross Site Scripting in URI:

 

Affected file: demo.php

Unfiltered variable(s): PHP_SELF,REQUEST_URI,SCRIPT_URL,SCRIPT_URI

 

FIx: filter the variable

 

Email Adress Found(3):

 

Affected Files: demo.php,demo2.php,hipaaprivacy.php

 

OKay, the only thing I could think of was that it is able to find the file where the email address were kept.  SO - I moved the files with email addresses out of the public_html area and into a non accessible area.

 

Ran my tests, and the forms still work fine.

 

*fingers crossed*

Link to comment
Share on other sites

Backup Files:

 

Backup files may contain script or resources attackers can use to prepare attacks with.

Affected file: demo2.php

Fix: Remove the backup file

 

Broken Link:

 

Causes the url to error.

 

Affected: demo/function.implode

 

Fix: remove link to this file or make it accessible.

 

 

as for the email thing it got worse.

 

i think rewriting  spambots to your .htaccess file would help ward off this low level spam attack.

 

Click here for example

Link to comment
Share on other sites

that didnt work

 

however using a robots.txt file might work if you want to read up on how to implement it into your script

 

but the following code will stop a directory from being accessed and stop bots.

 

User-agent:  *
Disallow: /secureforms/forms/demo 
User-agent: Googlebot
Disallow: /
User-agent: googlebot-image
Disallow: /
User-agent: googlebot-mobile
Disallow: /
User-agent: MSNBot
Disallow: /
User-agent: Slurp
Disallow: /
User-agent: Teoma
Disallow: /
User-agent: twiceler
Disallow: /
User-agent: Gigabot
Disallow: /
User-agent: Scrubby
Disallow: /
User-agent: Robozilla
Disallow: /
User-agent: Nutch
Disallow: /
User-agent: ia_archiver
Disallow: /
User-agent: baiduspider
Disallow: /
User-agent: naverbot
Disallow: /
User-agent: yeti
Disallow: /
User-agent: yahoo-mmcrawler
Disallow: /
User-agent: psbot
Disallow: /
User-agent: asterias
Disallow: /
User-agent: yahoo-blogs/v3.9
Disallow: /
User-agent: *
Disallow: /
Disallow: /cgi-bin/

Link to comment
Share on other sites

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.