to configure my FTP server for user authentication using Active Directory users.
In my environment, I am using Windows Server 2019 to run the FTP server.
The first issue I faced was that apparently (according to the output of the code obtained via the
troubleshooting guide) the custom provider was not able to read the provided configuration options (i.e. ldapServer and ldapPartition) from applicationHost.config file.
I then tried to provide the options by hardcoding them, but still I get a message saying: "FtpLdapAuthentication: The server could not be contacted.". Though there is no connection attempt seen in the output of "netstat -an 2" command.
Did you enable the port of FTP LDAP Authentication in firewall? If the port is disable, request or connection will be refused.
By the way, the first link of Robert McMurray guide to create an FTP LDAP authentication provider has been deleted.
Best regards,
Brucz
.NET forums are moving to a new home on Microsoft Q&A, we encourage you to go to Microsoft Q&A for .NET for posting new questions and get involved today.
For sure I did define the required LDAP port between the FTP server and Active Directory domain controller (i.e. 389) and have tested its connectivity using telnet command.
I then tried to provide the options by hardcoding them, but still I get a message saying: "FtpLdapAuthentication: The server could not be contacted.". Though there is no connection attempt seen in the output of "netstat -an 2" command.
It may also be caused by a firewall, you can try to disable the firewall and try again.
Best regards,
Sam
IIS.NET forums are moving to a new home on Microsoft Q&A, we encourage you to go to Microsoft Q&A for .NET for posting new questions and get involved today. Learn more >
2 Posts
Need help for FTP LDAP Authentication
Mar 07, 2021 05:59 AM|goftari|LINK
Hello everyone,
I am trying to use the Robert McMurray guide to create an FTP LDAP authentication provider
to configure my FTP server for user authentication using Active Directory users.
In my environment, I am using Windows Server 2019 to run the FTP server.
The first issue I faced was that apparently (according to the output of the code obtained via the troubleshooting guide) the custom provider was not able to read the provided configuration options (i.e. ldapServer and ldapPartition) from applicationHost.config file.
I then tried to provide the options by hardcoding them, but still I get a message saying: "FtpLdapAuthentication: The server could not be contacted.". Though there is no connection attempt seen in the output of "netstat -an 2" command.
Please help me get over this issue.
Regards, Alireza
232 Posts
Re: Need help for FTP LDAP Authentication
Mar 08, 2021 06:15 AM|Brucz|LINK
Hi goftari,
Did you enable the port of FTP LDAP Authentication in firewall? If the port is disable, request or connection will be refused.
By the way, the first link of Robert McMurray guide to create an FTP LDAP authentication provider has been deleted.
Best regards,
Brucz
2 Posts
Re: Need help for FTP LDAP Authentication
Mar 08, 2021 06:36 AM|goftari|LINK
Hi Brucz,
Thanks for your reply,
I mistakenly linked to the wrong URL, which is now corrected and is:
https://blogs.iis.net/robert_mcmurray/ftp-and-ldap-part-1-how-to-use-managed-code-c-to-create-an-ftp-authentication-provider-that-uses-an-ldap-server
For sure I did define the required LDAP port between the FTP server and Active Directory domain controller (i.e. 389) and have tested its connectivity using telnet command.
288 Posts
Re: Need help for FTP LDAP Authentication
Mar 25, 2021 08:54 AM|samwu|LINK
Hi goftari,
It may also be caused by a firewall, you can try to disable the firewall and try again.
Best regards,
Sam