Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3497714
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T12:24:15+00:00 2026-05-18T12:24:15+00:00

I am learning ASP.NET MVC 3 from many sources on the internet. I am

  • 0

I am learning ASP.NET MVC 3 from many sources on the internet. I am worrying whether my settings based on the mixed information contains unnecessary things leading to security risks.

In this topic, I need your suggestion or comment pertaining to my settings explained below. I will assign a number to each step to make it easier to be referenced in your comment or suggestion.


STEP 1: Enabling IIS

alt text


STEP 2: Installing .NET 4

No image 🙂


STEP 3: Installing SQL-Server 2008R2

No image 🙂


STEP 4: Installing Visual Studio 2010

No image 🙂


STEP 5: Make a project, e.g., NerdDinner

I put my project file (including NerdDinner.mdb) under C:\

NerdDinner.mdb is already populated with dummy data.

alt text


STEP 6: Configuring Global Application Pool

alt text


STEP 7: Make Virtual Directory using Visual Studio 2010

alt text

Shown in IIS Manager, NerdDinner is an application under the default web site.

alt text


STEP 8: Configuring Application Pool for NerdDinner web app

alt text


STEP 9: Attaching and Configuring NerdDinner.mdb using Sql-Server Management Studio

alt text


STEP 10: Configuring Connection String

 <add name="NerdDinnerEntities"   

  connectionString="metadata=res://*/Models.NerdDinner.csdl|res://*/Models.NerdDinner.ssdl|res://*/Models.NerdDinner.msl;provider=System.Data.SqlClient;provider connection string=&quot;
     Data Source=.\sqlexpress;
     Initial Catalog=NerdDinner;
     Integrated Security=True;
     MultipleActiveResultSets=True
     &quot;"
     providerName="System.Data.EntityClient" />

Testing

Everything works well, but I am not sure whether or not these steps contains security issues.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T12:24:15+00:00Added an answer on May 18, 2026 at 12:24 pm

    This is more of a production environment tip, but you should practice it on your development machine as well.

    IIS7.x by default will create a separate application pool for your website named after the name you give the website.

    Instead of running the application pool and the site/application under NETWORK SERVICE, run both the site and the pool as ApplicationPoolIdentity.

    In the website or application features pane open the Authentication feature select Anonymous Authentication and do right-click Edit:

    alt text

    Next, ensure your website is running in its own application pool. Sub applications may benefit from their own application pool, but we tend to put them in the same pool as the parent site unless there is a need for a different runtime configuration such as a different version of ASP.NET or Pipeline mode.

    alt text

    When you have configured this grant the requisite permissions to the pool identity on your web folders by doing:

    ICACLS c:\dynamic\NerdDinner\NerdDinner /grant "IIS AppPool\site1":(CI)(OI)(M)

    Or you can apply these permissions via explorer:
    alt text

    Click Check Names then OK:
    alt text

    In SQL Server the same thing applies, instead of giving permissions on your database to NETWORK SERVICE, give permissions to the ApplicationPoolIdentity instead. As with NETWORK SERVICE this will only work if the SQL database is on the same machine as the web server if you’re running a standalone server.

    For example:
    alt text

    In the dialogue shown above, don’t search and Check Names because this will replace the IIS AppPool\ portion of the username with your machine name. When you click OK SQL will complain that it can’t locate [MACHINENAME]\NerdDinner.

    Next set the add as a login to the NerdDinner database:
    alt text

    I’m setting as DB Owner here but you can choose the role you see fit for your needs. If this is your development machine then DBO will be fine because you can then do DDL from within Visual Studio. Most shared host production environments will make the first login (which is usually all you get) DBO anyway because many apps such as DotNetNuke etc need full control over their databases.

    The connection string you’ve provided in your example should work as-is without any changes.

    For more information on this topic:

    Application Pool Identities (IIS.NET)
    New in IIS 7 – App Pool Isolation (Ken Schaefer)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm learning ASP.NET MVC Framework, From some articles like this , it seems that
I came from PHP language(codeigniter), but now I learning ASP.Net MVC :) In PHP
I am learning ASP.NET MVC and many concepts of ASP.NET like authentication, authorization, session
I have a simple ASP.NET MVC 3 dummy app (just learning MVC coming from
I am learning MVC 3 from asp.net site. My MVC 3 application already has
I am learning ASP.NET MVC and Entity Framework. After I learning from this web
I'm learning ASP.NET MVC and bugged by one issue. In the HomeController, the Index
I'm just learning asp.net mvc and I'm trying to figure out how to move
I am learning ASP.NET MVC now a days and I have found that most
I am playing with learning ASP.NET MVC as a non-web developer. I am trying

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.