ProFTPD authentication failure & Apache directory index listing issue

5 posts / 0 new
Last post
#1 Sun, 07/19/2009 - 17:10
shuja_khan

ProFTPD authentication failure & Apache directory index listing issue

Guys @ Virtualmin Community

I have one question, I have read all the forum about that & their is only one topic raised about that

from our colleague mikelawford about 23rd of June 2009.

If I compare my server with his one based on info I had, my server is in pretty much advance state.

I am using LDAP for virtualmin, using following below article link written by -Bryan Petkus posted by andreychek, on 18th of May 2009, a very good article. http://www.virtualmin.com/documentation/id,centos_5_install

Now the problem is every thing is working fine, accept ftp, SSH is successful.

I have the same type of issue what mikelawford is facing, despite of all my efforts, but FAILED.

I have installed my server using following steps.

  1. Installed Cent OS 5.3 x64 the basic system bare minimum (only service run level 3).
  2. yum update to update all installed packages & the kernel.
  3. Restart server.
  4. Using wget downloaded the install.sh script (GPL version).
  5. Updated all VM packages from web interface.
  6. Configured my server for openLDAP following the above article.
  7. Change CentOS user Auth to openLDAP, using setup command.
  8. Using VM created a website successfully.
  9. Confirm in LDAP Users & Groups, user is created in LDAP & show in listing.
  10. Test newly created user associated with domain site for SSH & FTP, for SSH I have used putty.exe & for FTP I have used filezilla, SSH successfull, filezilla failed for FTP, but same filezilla is able to connect using SFTP the SSH protocol, I can upload, delete, rename, move whatever I like I can do based on that user credentials, I tried other ftp programmes as well, but failed.

  11. I tried on server, using ip address, using FQDN & localhost as well, but in all cases, failed, error is same, what mikelawford is facing.

  12. I stoped IPTABLES (SELINUX is not installed, but to make thing clear, I have issued the following to disable SELINUX i.e. "setenforce 0"), still failed.

  13. To confirm user Auth I am also using VPN to connect to this server, a local server is mounting this server file system as NFS & that local server had samba installed & samba is allowing LAN users to mount that share on windows, when ever a user on local LAN click on that share, username & password is asked, when provided correctly, user is able to connect & mount share to a drive letter, username & password is asked by remote Virtualmin Server via LDAP as back-end Auth mechanism (point 13 says that openLDAP is working fine).

  14. Just for the safe side I checked LDAP support for Pro-FTPd, it is not installed, so I installed support for LDAP on Pro-FTPd, using following command, yum install proftpd-ldap.x86_64

  15. I have consulted the following site for above setup, http://www.castaglia.org/proftpd/doc/README.LDAP.html

  16. I did all that is mentioned

  17. ProFTPd is a pain in a**, I am unable to sort it out.

pleaseeeeeeeeeeeeeeeeeeeeee help

Now the last bit.

I want to show directory listing on some directories, I have done following.

  1. Click VM.
  2. Select domain.
  3. Click on Services.
  4. Click on Configure Website.
  5. Under Per-Directory Options, I click on Directory /home/domain_name/public_html
  6. Click on Directory Indexing
  7. I click on Select Below under Directory Index Options.
  8. I click on Display fancy directory indexes
  9. I click on Save & again Save & again on Save.
  10. Check manually tail -f /var/log/messages
  11. But to confirm, I manually restart Apache demon with following # /etc/init.d/httpd restart

  12. When I check the result, two of the possible things may happen. 1st. Forbidden (most usual display on browser) 2nd, some times without any given reason CentOS default Apache Test page will pop-up. For this default Apache test page I have no definite answer, why at one point I am receiving Forbidden page, because absence of index.html page & why at another time I will be seeing default Apache page.

  13. I know if I put options +Index in httpd.conf file it will display the directory listing, but in case of VM, manually inserting this directive still doesn't serve the purpose.

  14. Next thing I need to know is why forbidden or default Apache page is displayed randomly.

kind regards

-shuja

Tue, 07/21/2009 - 05:22
shuja_khan

Is there any one who have an experience of this & share it.

Thanks

-shuja

Tue, 07/21/2009 - 05:23
shuja_khan

Apache had a strange issues as well, this is the only issue I am unable to resolve.

Can someone give some reference so that I can follow these reference to sort out this issue

Thanks

-shuja

Tue, 07/21/2009 - 10:13
andreychek

As far as ProFTP goes -- I'm not sure. We tend to recommend not using LDAP unless you really need it (ie, many thousands of users, or sharing users over multiple servers) -- as it's usage complicates setup and weird things can go wrong that become hard to troubleshoot :-)

I'd recommend reviewing your LDAP settings as compared to the document above. I might also take a look at this LDAP document here:

http://www.virtualmin.com/documentation/id,combining_virtualmin_and_ldap/

Beyond that, I'm really not familiar enough with LDAP to be much assistance :-)

As far as Apache goes -- you may want to check out "The Wrong Site Shows Up" in this document here:

http://www.virtualmin.com/documentation/web/troubleshooting

One of your VirtualHosts may not be setup correctly, and may have in them rather than .

As to why you get forbidden -- adding the "Indexes" option should solve that.

To edit that for all newly created Virtual Servers, you can set that up in System Settings -> Server Templates -> Default -> Apache Website -- and at the top there is "Directives and settings for new websites", and you can edit the options in it.

If you continue to get errors, you may want to look in the Apache error log for further clues, it's in $HOME/logs/error_log.

-Eric

Fri, 09/10/2010 - 13:30
jerico2day

I know this is old, but I'd like to point out that uncommenting the following line in the proftpd config file (webmin > ProFTPD Server > edit config file) fixes the issue:

# Uncomment this if you are using NIS or LDAP via NSS to retrieve passwords:
# PersistentPasswd off

After uncommenting this line, I was able to login to ftp

Topic locked