What account is ASP.NET using?, it's not ASPNET!

Discussion in 'ASP .Net' started by dryer, Dec 12, 2003.

  1. dryer

    dryer Guest

    I have a web app that runs fine on my local machine (W2K pro), but when ran on
    Windows 2003 server there is a glitch. I have a function that writes an XML doc
    to a directory, but I can't figure out what account the 2003 server is using. I
    gave ASPNET write privilges to the directory, but get 'Access Denied' errors.
    When I gave permmisions to 'Authenticated Users' it works fine. So I went
    through the whole list of users and nothing would let the app run, only when I
    add one of the groups, ie 'Everybody', 'Users', 'Authenticated Users', etc. does
    it work. machine.config is set to use the ASPNET, any ideas on what's going
    on??

    Thanks.
    dryer, Dec 12, 2003
    #1
    1. Advertising

  2. dryer

    Hans Kesting Guest

    "dryer" <> wrote in message
    news:...
    > I have a web app that runs fine on my local machine (W2K pro), but when

    ran on
    > Windows 2003 server there is a glitch. I have a function that writes an

    XML doc
    > to a directory, but I can't figure out what account the 2003 server is

    using. I
    > gave ASPNET write privilges to the directory, but get 'Access Denied'

    errors.
    > When I gave permmisions to 'Authenticated Users' it works fine. So I went
    > through the whole list of users and nothing would let the app run, only

    when I
    > add one of the groups, ie 'Everybody', 'Users', 'Authenticated Users',

    etc. does
    > it work. machine.config is set to use the ASPNET, any ideas on what's

    going
    > on??
    >
    > Thanks.
    >


    IIRC: "network services"
    Hans Kesting, Dec 12, 2003
    #2
    1. Advertising

  3. Hi Dryer,

    Here's some code that should help you discover who you're dealing with on a
    given page:

    Private Sub Page_Load _
    (ByVal sender As System.Object, _
    ByVal e As System.EventArgs) _
    Handles MyBase.Load
    lblVersion.Text = _
    System.Reflection.Assembly.GetExecutingAssembly _
    ().GetName().Version.ToString
    ' Put the authenticated account and
    'database name at the bottom of the default page
    Dim wi As System.Security.Principal.WindowsIdentity = _
    WindowsIdentity.GetCurrent
    lblServer.Text = _
    Request.ServerVariables("SERVER_NAME")
    lblAuthenticatedUser.Text = wi.Name
    End Sub


    "dryer" <> wrote in message
    news:...
    > I have a web app that runs fine on my local machine (W2K pro), but when

    ran on
    > Windows 2003 server there is a glitch. I have a function that writes an

    XML doc
    > to a directory, but I can't figure out what account the 2003 server is

    using. I
    > gave ASPNET write privilges to the directory, but get 'Access Denied'

    errors.
    > When I gave permmisions to 'Authenticated Users' it works fine. So I went
    > through the whole list of users and nothing would let the app run, only

    when I
    > add one of the groups, ie 'Everybody', 'Users', 'Authenticated Users',

    etc. does
    > it work. machine.config is set to use the ASPNET, any ideas on what's

    going
    > on??
    >
    > Thanks.
    >
    Ken Cox [Microsoft MVP], Dec 12, 2003
    #3
  4. dryer

    dryer Guest

    Ken,

    Great code, thanks alot.

    dryer

    In article <>, Ken Cox [Microsoft MVP]"
    <> says...
    >
    >Hi Dryer,
    >
    >Here's some code that should help you discover who you're dealing with on a
    >given page:
    >
    > Private Sub Page_Load _
    > (ByVal sender As System.Object, _
    > ByVal e As System.EventArgs) _
    > Handles MyBase.Load
    > lblVersion.Text = _
    > System.Reflection.Assembly.GetExecutingAssembly _
    > ().GetName().Version.ToString
    > ' Put the authenticated account and
    > 'database name at the bottom of the default page
    > Dim wi As System.Security.Principal.WindowsIdentity = _
    > WindowsIdentity.GetCurrent
    > lblServer.Text = _
    > Request.ServerVariables("SERVER_NAME")
    > lblAuthenticatedUser.Text = wi.Name
    > End Sub
    >
    >
    >"dryer" <> wrote in message
    >news:...
    >> I have a web app that runs fine on my local machine (W2K pro), but when

    >ran on
    >> Windows 2003 server there is a glitch. I have a function that writes an

    >XML doc
    >> to a directory, but I can't figure out what account the 2003 server is

    >using. I
    >> gave ASPNET write privilges to the directory, but get 'Access Denied'

    >errors.
    >> When I gave permmisions to 'Authenticated Users' it works fine. So I went
    >> through the whole list of users and nothing would let the app run, only

    >when I
    >> add one of the groups, ie 'Everybody', 'Users', 'Authenticated Users',

    >etc. does
    >> it work. machine.config is set to use the ASPNET, any ideas on what's

    >going
    >> on??
    >>
    >> Thanks.
    >>

    >
    >
    dryer, Dec 16, 2003
    #4
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    7
    Views:
    613
    Juan T. Llibre
    Mar 23, 2007
  2. Bill Kellaway
    Replies:
    4
    Views:
    165
    Joe Kaplan \(MVP - ADSI\)
    Jan 20, 2004
  3. Giang Thanh via .NET 247
    Replies:
    0
    Views:
    102
    Giang Thanh via .NET 247
    May 6, 2004
  4. nilapenn
    Replies:
    3
    Views:
    601
    Joe Kaplan \(MVP - ADSI\)
    Feb 14, 2005
  5. Replies:
    4
    Views:
    619
    Paul Clement
    Sep 15, 2005
Loading...

Share This Page