Run ASP.NET Scripts as different User

Discussion in 'ASP General' started by William, Apr 5, 2004.

  1. William

    William Guest

    I have this ASP.NET script that i use for creating tables
    of files in a folder for users. The problem is that if
    the user changes the username to create the list of files
    for, they can see the files but now download them (NTFS
    permissions). I noticed that the Network Service account
    requires list directory access so it gets round my
    permissions. How do i get the script to run as the user
    logged on via the site (Windows Authentication) instead
    of the network service account?
    William, Apr 5, 2004
    #1
    1. Advertising

  2. William

    Roland Hall Guest

    "William" wrote in message news:1874801c41ad9$52ee9790$...
    : I have this ASP.NET script that i use for creating tables
    : of files in a folder for users. The problem is that if
    : the user changes the username to create the list of files
    : for, they can see the files but now download them (NTFS
    : permissions). I noticed that the Network Service account
    : requires list directory access so it gets round my
    : permissions. How do i get the script to run as the user
    : logged on via the site (Windows Authentication) instead
    : of the network service account?

    Hi William...

    The topic here is Classic ASP. All .NET NGs have dotnet in their name.

    --
    Roland Hall
    /* This information is distributed in the hope that it will be useful, but
    without any warranty; without even the implied warranty of merchantability
    or fitness for a particular purpose. */
    Technet Script Center - http://www.microsoft.com/technet/scriptcenter/
    WSH 5.6 Documentation - http://msdn.microsoft.com/downloads/list/webdev.asp
    MSDN Library - http://msdn.microsoft.com/library/default.asp
    Roland Hall, Apr 5, 2004
    #2
    1. Advertising

  3. William

    William Guest

    Sorry about that, i didn't know, i was just looking in
    IIS because i thought it was an IIS problem and ASP and
    this seemed to be the closest match. Can you link me
    where i'd get the help i need please?

    >-----Original Message-----
    >"William" wrote in message news:1874801c41ad9$52ee9790

    $...
    >: I have this ASP.NET script that i use for creating

    tables
    >: of files in a folder for users. The problem is that if
    >: the user changes the username to create the list of

    files
    >: for, they can see the files but now download them (NTFS
    >: permissions). I noticed that the Network Service

    account
    >: requires list directory access so it gets round my
    >: permissions. How do i get the script to run as the user
    >: logged on via the site (Windows Authentication) instead
    >: of the network service account?
    >
    >Hi William...
    >
    >The topic here is Classic ASP. All .NET NGs have dotnet

    in their name.
    >
    >--
    >Roland Hall
    >/* This information is distributed in the hope that it

    will be useful, but
    >without any warranty; without even the implied warranty

    of merchantability
    >or fitness for a particular purpose. */
    >Technet Script Center -

    http://www.microsoft.com/technet/scriptcenter/
    >WSH 5.6 Documentation -

    http://msdn.microsoft.com/downloads/list/webdev.asp
    >MSDN Library -

    http://msdn.microsoft.com/library/default.asp
    >
    >
    >.
    >
    William, Apr 6, 2004
    #3
  4. William

    Roland Hall Guest

    "William" wrote in message news:18a9d01c41b9f$86ee9830$...
    : Sorry about that, i didn't know, i was just looking in
    : IIS because i thought it was an IIS problem and ASP and
    : this seemed to be the closest match. Can you link me
    : where i'd get the help i need please?

    Try...

    microsoft.public.dotnet.framework..aspnet
    microsoft.public.dotnet.framework..aspnet.security

    --
    Roland Hall
    /* This information is distributed in the hope that it will be useful, but
    without any warranty; without even the implied warranty of merchantability
    or fitness for a particular purpose. */
    Technet Script Center - http://www.microsoft.com/technet/scriptcenter/
    WSH 5.6 Documentation - http://msdn.microsoft.com/downloads/list/webdev.asp
    MSDN Library - http://msdn.microsoft.com/library/default.asp
    Roland Hall, Apr 6, 2004
    #4
  5. William

    William Guest

    Thanks for that but i fortunatly fixed my issue by just
    editing the script to check the logged in user.
    >-----Original Message-----
    >"William" wrote in message news:18a9d01c41b9f$86ee9830

    $...
    >: Sorry about that, i didn't know, i was just looking in
    >: IIS because i thought it was an IIS problem and ASP and
    >: this seemed to be the closest match. Can you link me
    >: where i'd get the help i need please?
    >
    >Try...
    >
    >microsoft.public.dotnet.framework..aspnet
    >microsoft.public.dotnet.framework..aspnet.security
    >
    >--
    >Roland Hall
    >/* This information is distributed in the hope that it

    will be useful, but
    >without any warranty; without even the implied warranty

    of merchantability
    >or fitness for a particular purpose. */
    >Technet Script Center -

    http://www.microsoft.com/technet/scriptcenter/
    >WSH 5.6 Documentation -

    http://msdn.microsoft.com/downloads/list/webdev.asp
    >MSDN Library -

    http://msdn.microsoft.com/library/default.asp
    >
    >
    >.
    >
    William, Apr 7, 2004
    #5
  6. William

    Roland Hall Guest

    "William" wrote in message news:194d601c41c75$c81e8050$...
    : Thanks for that but i fortunatly fixed my issue by just
    : editing the script to check the logged in user.

    Not a waste and glad you got it working. I posted the other NGs to help you
    get your answer quicker. It will still be relevant next time.

    --
    Roland Hall
    /* This information is distributed in the hope that it will be useful, but
    without any warranty; without even the implied warranty of merchantability
    or fitness for a particular purpose. */
    Technet Script Center - http://www.microsoft.com/technet/scriptcenter/
    WSH 5.6 Documentation - http://msdn.microsoft.com/downloads/list/webdev.asp
    MSDN Library - http://msdn.microsoft.com/library/default.asp
    Roland Hall, Apr 7, 2004
    #6
    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. Bernard Lebel
    Replies:
    8
    Views:
    439
    Mikael Olofsson
    May 31, 2006
  2. davidj411
    Replies:
    0
    Views:
    480
    davidj411
    Jun 27, 2008
  3. Gotch@
    Replies:
    1
    Views:
    382
    Adrienne Boswell
    Dec 12, 2008
  4. Fa Sidd
    Replies:
    12
    Views:
    200
    ara howard
    Jan 26, 2008
  5. Replies:
    13
    Views:
    513
    Anno Siegel
    Sep 10, 2007
Loading...

Share This Page