Re: Injected, whats next



You should be able to use SELECT ... INTO OUTFILE to write the results
of a SELECT statement out to a file on the server's filesystem. Since
you can SELECT things that don't actually reference any table, this
should let you write arbitrary data to the filesystem with the
permissions of the database user.

Since it uses PHP, I would try to find a writable, web-accessible
directory on the server and do something like

SELECT '<?php some_evil_php_code ?>' INTO OUTFILE '/var/www/accessible_by_db/';

Have fun :)

-Brendan

On 8/17/06, DokFLeed <dokfleed@xxxxxxxxxxxx> wrote:
I am testing a web application, I can run UPDATE & SELECT
Does anyone know a way to upload a file to a server through MySQL !
does it allow running system commands or a way to dump a file from the
database to the server?
its LAMP , Linux, Apache, MySQL, PHP
any ideas!!

Dok
smoke dope, eat soap, fly home in a bubble


------------------------------------------------------------------------
This List Sponsored by: Cenzic

Need to secure your web apps?
Cenzic Hailstorm finds vulnerabilities fast.
Click the link to buy it, try it or download Hailstorm for FREE.
http://www.cenzic.com/products_services/download_hailstorm.php
------------------------------------------------------------------------



------------------------------------------------------------------------
This List Sponsored by: Cenzic

Need to secure your web apps?
Cenzic Hailstorm finds vulnerabilities fast.
Click the link to buy it, try it or download Hailstorm for FREE.
http://www.cenzic.com/products_services/download_hailstorm.php
------------------------------------------------------------------------



Relevant Pages

  • Re: reverse proxy identification
    ... I pretty sure that is MS IIS web server (probably multiple versions)... ... However I dont think that for each IP adress there is a physical server, but perhaps a multiplexing device that also does application firewalling. ... Cenzic Hailstorm finds vulnerabilities fast. ... Click the link to buy it, try it or download Hailstorm for FREE. ...
    (Pen-Test)
  • Re: Injected, whats next
    ... Does anyone know a way to upload a file to a server through MySQL! ... Cenzic Hailstorm finds vulnerabilities fast. ... Click the link to buy it, try it or download Hailstorm for FREE. ...
    (Pen-Test)
  • Re: windows 2003 server
    ... How does one dump the passwords from the SAM file. ... Subject: windows 2003 server ... password policy and _not_ how to break into the win2003 server, ... Cenzic Hailstorm finds vulnerabilities fast. ...
    (Pen-Test)
  • Re: CIFS / Kerberos question
    ... Packet sniffing from a connected hub (for server, ... > I am trying to achieve PKI authentication and SMB access to Windows ... > - Filesystem relies on SSPI-KerberosV to provide security services. ... What exactly does Kerberos do in the server? ...
    (microsoft.public.win2000.security)
  • Re: OT: why no file copy() libc/syscall ??
    ... the mounted filesystem. ... message over the network directly to the server. ... > the remote server implementing the file copy. ...
    (Linux-Kernel)