logo       


Simple PHP scanning ..: msg#00018

Subject: Simple PHP scanning ..
  There are three types of attack that come up often
 in the PHP world:

        * File inclusion erorrs.
        * XSS attacks.
        * SQL Injection attacks.

  The first and the last should be simple to detect
 via a simple script, just by looking for patterns
 such as:

        include( $ );

  and :

        mysql_query( $ .. );

  I've not seen anything like this around so far, but
 I've made a simple attempt at it with the attached Perl
 script.

  Ideally I real parser would be nice, but i've not found
 an appropriate grammer for the languae - any pointers would
 be appreciated.

  Sample output, searching within the package 'svnweb'
 (all false positives)

skx@lappy:~/tmp$ perl scan-php.pl
./websvn-1.61/wsvn.php ["$locwebsvnreal/form.php"] 
include("$locwebsvnreal/form.php");
./websvn-1.61/wsvn.php ["$locwebsvnreal/index.php"] 
include("$locwebsvnreal/index.php");
./websvn-1.61/wsvn.php ["$locwebsvnreal/$file"] include("$locwebsvnreal/$file");

   Format is 'filename' [what's included] 'complete matching line'

Steve
--
# The Debian Security Audit Project.
http://www.debian.org/security/audit

Attachment: scan-php.pl
Description: Perl program

Ruby Jobs
Java Jobs
Jobs in California
more...
what
job title, keywords
where
city, state, zip
jobs by job search
Search:
Java, servers, webhosting, windows, cisco ...
more...
<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
encryption.gpg....    ietf.rfc822/199...    freebsd.devel.i...    lang.haskell.li...    mail.squirrelma...    web.zope.plone....    yellowdog.gener...    text.xml.xalan....    recreation.phot...    kde.devel.educa...    hardware.bus.ca...    printing.ghosts...    voip.peering/20...    assembly/2006-0...    org.user-groups...    culture.interne...    network.i2p/200...    boot-loaders.ya...    xfree86.render/...    qnx.openqnx.dev...    jakarta.velocit...    user-groups.pal...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe