Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 MASTER..XP_CMDSHELL PERMISSIONS QUE

Author  Topic 

bbasir
Yak Posting Veteran

76 Posts

Posted - 2008-03-24 : 18:31:46
EXEC MASTER..XP_CMDSHELL @cmd, NO_OUTPUT

I NEED TO RUN THE ABOVE COMMAND FROM A WEB APP, TO USE OPENROWSET TO GET SOME DATA I.E. INSERT INTO EXCEL FILE INTO MULTIPLE SHEETS.

HOW DOES ONE GIVE PERMISSIONS TO A WEB APP USER TO USE THE ABOVE EXTENDED SP?

THE WEB APP USER HAS AN APPLICATION SQL SERVER USER ID AS WELL.

OR DOES THE PERMISSIONS NEED TO BE GIVEN TO THE SP THAT CALLS THE ABOVE MENTIONED EXTENDED SP?

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-03-24 : 18:35:12
This is a really bad idea. But if you must do it, then check out xp_cmdshell in SQL Server Books Online as it will show you how to setup a proxy account so that you don't have to give out sysadmin to the user.

Also, you should not use all upper case in your posts. It is not proper netiquette as it is considered screaming, for whatever reason.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/
Go to Top of Page

bbasir
Yak Posting Veteran

76 Posts

Posted - 2008-03-24 : 19:03:50
quote:
Originally posted by tkizer

This is a really bad idea. But if you must do it, then check out xp_cmdshell in SQL Server Books Online as it will show you how to setup a proxy account so that you don't have to give out sysadmin to the user.

Thank you very much for your reply, I will check out the proxy account info on books on line. Just wrote in a hurry so caps lock remained on.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Go to Top of Page
   

- Advertisement -