Script to create IIS 7.0 FTP User with Manager Authentication

Posted on 2009-02-17
Last Modified: 2013-12-02
I have just finished installing and configuring the new FTP services for IIS 7.0.  The biggest benefit I get from this new version is the capability to provide non-windows based user authentication using the new IIS Manager Authentication.  I have successfully set this functionality up by following the steps provided at the site below:
So basically, I am allowing users that I create from within IIS (without having to create a Windows account), to login to their specific folder on my server via IIS.  The problem is that for every user that needs to be created (e.g. a user named jdoe), here are the steps I have to perform&
1)      Through Windows Explorer, create a folder under the ftproot\localuser directory named jdoe
2)      Go into IIS Manager, select the server root, double-click on IIS Manager Users and add a new user
3)      Go to the FTP site node, click on IIS Manager Permissions and then add an allow rule for the user that was created.
This works fine, but its very cumbersome and click intensive.  What I want to do is to create a script (probably a PowerShell script), that will automate this process.  Basically, the script would prompt me for a name and password and would then perform steps 1-3 above automatically.  My problem is that I dont know the proper PowerShell commands needed to perform those actions.  Any help on creating the script or pointers to references on these commands would be greatly appreciated.
Question by:bmccleary
    LVL 22

    Accepted Solution

    Take a look at this ...

    You could also use AutoIT scripting to create your own script to do this ...

    Author Comment

    Thanks for the information.  The poshcode site is almost perfect.  The only thing I need to change is instead of creating a user through windows, I would like to create the user in the IIS Manager Authentication section.  Do you know where I could fine the references to swap out the code to replace lines 23-44 of the sample code with code to create IIS Manager Users?
    LVL 22

    Expert Comment


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    Debug Tools to analyse IIS process: This article focus on taking memory dumps from IIS to determine which code is taking more time and to analyse which calls hangs/causes more CPU usage. To take dumps,download the following. Install1: To st…
    Introduction People like FTP.  It's a solid, stable, robust protocol for quickly transferring files between two hosts using TCP/IP.  In most cases it's much faster than SMB or CIFS, and certainly much easier to set up between organizations.  This…
    After creating this article (, I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
    After creating this article (, I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    10 Experts available now in Live!

    Get 1:1 Help Now