ASPNET (NETWORK SERVICE) identity cannot run SP that drop table

  • Thread starter pedestrian via DotNetMonster.com
  • Start date
P

pedestrian via DotNetMonster.com

I've created an asp.net 1.1 page for development machine running on IIS 5.0
(deployment machine running IIS 6.0).

The page use ADO.NET (OLE DB) to call a stored procedure in the SQL Server
2005 that drop a table and recreate it.

The issue now is that the default ASPNET identity for asp.net doesn't have
the permission to drop the table using the mentioned stored procedure. Is
there any way to assign the permission?

Thank you.
 
J

Just Me

the permissions on the SQL Database will be set by the SQL Administrator. If
you are that person, you can assign permissions for the NETWORK SERVICE to
perform this action.

However, this is normally not a good idea, I would advise that you create a
domain account for use with this application and set up and application pool
for your application which uses that account, then you can be sure that no
one can access your sql data by simply writing code to access that database.

Alternatively, you could use SQL security with is simply a username and
password, but this is normally frowned upon these days as a securty issue.
 
J

Juan T. Llibre

re:
!> The issue now is that the default ASPNET identity for asp.net doesn't have
!> the permission to drop the table using the mentioned stored procedure. Is
!> there any way to assign the permission?

Sure.

Use SQL Server's 2005 User Manager...and assign
the needed permission to the account's login user.

Since, apparently, the account has access to the database, but not
to the specific stored procedure, you don't have to create the login.

Right-click the user and select "All Tasks" and then "Manage Permissions".
Scroll down to the stored procedure...and check the "EXEC" option.




Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
======================================
 
P

pedestrian via DotNetMonster.com

Hi Juan. Thanks for replying....

I'm using SQL Server Express 2005. It seems that I cannot find the User
manager...
Is it included in the Express version, anyone please?

Thanks.
re:
!> The issue now is that the default ASPNET identity for asp.net doesn't have
!> the permission to drop the table using the mentioned stored procedure. Is
!> there any way to assign the permission?

Sure.

Use SQL Server's 2005 User Manager...and assign
the needed permission to the account's login user.

Since, apparently, the account has access to the database, but not
to the specific stored procedure, you don't have to create the login.

Right-click the user and select "All Tasks" and then "Manage Permissions".
Scroll down to the stored procedure...and check the "EXEC" option.

Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
======================================
I've created an asp.net 1.1 page for development machine running on IIS 5.0
(deployment machine running IIS 6.0).
[quoted text clipped - 7 lines]
Thank you.

--
Regards,
Pedestrian, Penang.

Message posted via DotNetMonster.com
http://www.dotnetmonster.com/Uwe/Forums.aspx/asp-net/200709/1
 
J

Just Me

There is a version of the SQL Management Studi shipped with the express
version.

http://download.microsoft.com/downl...560-8269-e8fe906ea675/SQLExpressdatasheet.pdf


pedestrian via DotNetMonster.com said:
Hi Juan. Thanks for replying....

I'm using SQL Server Express 2005. It seems that I cannot find the User
manager...
Is it included in the Express version, anyone please?

Thanks.
re:
!> The issue now is that the default ASPNET identity for asp.net doesn't
have
!> the permission to drop the table using the mentioned stored procedure.
Is
!> there any way to assign the permission?

Sure.

Use SQL Server's 2005 User Manager...and assign
the needed permission to the account's login user.

Since, apparently, the account has access to the database, but not
to the specific stored procedure, you don't have to create the login.

Right-click the user and select "All Tasks" and then "Manage Permissions".
Scroll down to the stored procedure...and check the "EXEC" option.

Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
======================================
I've created an asp.net 1.1 page for development machine running on IIS
5.0
(deployment machine running IIS 6.0).
[quoted text clipped - 7 lines]
Thank you.

--
Regards,
Pedestrian, Penang.

Message posted via DotNetMonster.com
http://www.dotnetmonster.com/Uwe/Forums.aspx/asp-net/200709/1
 
J

Juan T. Llibre

re:
!> Is it included in the Express version, anyone please?

There's a version of SQL Server Express 2005 which includes
SQL Server Management Studio Express (SSMSE).

It's called "SQL Server 2005 Express Edition with Advanced Services".

You can download it, and also the stand-alone version of SSMSE, at :

http://msdn2.microsoft.com/en-us/express/bb410792.aspx




Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
======================================
pedestrian via DotNetMonster.com said:
Hi Juan. Thanks for replying....

I'm using SQL Server Express 2005. It seems that I cannot find the User
manager...
Is it included in the Express version, anyone please?

Thanks.
re:
!> The issue now is that the default ASPNET identity for asp.net doesn't have
!> the permission to drop the table using the mentioned stored procedure. Is
!> there any way to assign the permission?

Sure.

Use SQL Server's 2005 User Manager...and assign
the needed permission to the account's login user.

Since, apparently, the account has access to the database, but not
to the specific stored procedure, you don't have to create the login.

Right-click the user and select "All Tasks" and then "Manage Permissions".
Scroll down to the stored procedure...and check the "EXEC" option.

Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
======================================
I've created an asp.net 1.1 page for development machine running on IIS 5.0
(deployment machine running IIS 6.0).
[quoted text clipped - 7 lines]
Thank you.

--
Regards,
Pedestrian, Penang.

Message posted via DotNetMonster.com
http://www.dotnetmonster.com/Uwe/Forums.aspx/asp-net/200709/1
 
P

pedestrian via DotNetMonster.com

Thanks for both of you.
re:
!> Is it included in the Express version, anyone please?

There's a version of SQL Server Express 2005 which includes
SQL Server Management Studio Express (SSMSE).

It's called "SQL Server 2005 Express Edition with Advanced Services".

You can download it, and also the stand-alone version of SSMSE, at :

http://msdn2.microsoft.com/en-us/express/bb410792.aspx

Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
======================================
Hi Juan. Thanks for replying....
[quoted text clipped - 29 lines]

--
Regards,
Pedestrian, Penang.

Message posted via DotNetMonster.com
http://www.dotnetmonster.com/Uwe/Forums.aspx/asp-net/200709/1
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top