how enable basic authentication for an ftp site using powershell [Answered]RSS

1 reply

Last post Jan 09, 2011 09:55 PM by toenuff

  • how enable basic authentication for an ftp site using powershell

    Jan 08, 2011 04:43 PM|lersey|LINK

    Hi,
    I'm trying to enable basic authentication for an ftp site using powershell.
    I navigate to the location
      --  PS IIS:\> Set-Location IIS:\Sites\FTP
      --  PS IIS:\Sites\FTP>
    request the basicAuthentication value
      --   $winauth = Get-WebConfiguration ftpServer/security/authentication/basicAuthentication

    but $winauth is empty, nothing is returned from the Get-WebConfiguration,
    I was expecting to receive an value like true or false for "$winauth.enabled"
    once the value is returned I would like to alter the value to "true" and update the configuration using Set-WebConfiguration

    Any help appreciated

    Thomas

    IIS Powershell powerShell IIS7 FTP IIS 7.5 IIS 7.5 - powershell

  • Re: how enable basic authentication for an ftp site using powershell

    Jan 09, 2011 09:55 PM|toenuff|LINK

    You do not need to go into the webconfiguration cmdlets for this. It is provided to you by the WebAdministration provider. You can view the value with this:
    Get-ItemProperty IIS:\Sites\FTP -Name ftpServer.security.authentication.basicAuthentication.enabled |select value
    You can enable it with this:
    Set-ItemProperty IIS:\Sites\FTP -Name ftpServer.security.authentication.basicAuthentication.enabled -Value $true