Prosíme přihlašte se nebo zaregistrujte.

Přihlašte se svým uživatelským jménem a heslem.
Vaše pomoc je stále potřeba!

Autor Téma: ProFtpd  (Přečteno 1617 krát)

charlie2806

  • Aktivní člen
  • *
  • Příspěvků: 263
ProFtpd
« kdy: 23 Února 2009, 19:34:43 »
Poradil by nekdo na co se zamerit, kdyz v adresari serveru v /home/ftp vytvorim symlink na nejaky adresar a on potom sice uzivateli ftp videt je, ale nemuze do neho vstoupit?
3x PC

Kecik

  • Aktivní člen
  • *
  • Příspěvků: 106
  • nuqDaq yuch Dapol-where do you keep the chocolate?
    • Personal web page
Re: ProFtpd
« Odpověď #1 kdy: 25 Února 2009, 13:35:00 »
Citace
Filesystem Tricks
A typical scenario is one where "DefaultRoot ~" is used to restrict users to their home directories, and where the administrator would like to have a shared upload directory, say /var/ftp/incoming, in each user's home directory. Symbolic links would normally be used to provide an arrangement like this. As mentioned above, though, when chroot(2) is used (which is what the DefaultRoot directive does), symlinks that point outside the new root (the user's home directory in this case) will not work. To get around this apparent limitation, it is possible on modern operating systems to mount directories at several locations in the filesystem.

To have an exact duplicate of the /var/ftp/incoming directory available in /home/bob/incoming and /home/dave/incoming, use one of these commands:

    * Linux (as of the 2.4.0 kernel):

        mount --bind /var/ftp/incoming /home/bob/incoming
        mount --bind /var/ftp/incoming /home/dave/incoming

      or, alternatively:

        mount -o bind /var/ftp/incoming /home/bob/incoming
        mount -o bind /var/ftp/incoming /home/dave/incoming

The same technique can be used for <Anonymous> directories, which also operate in a chroot()ed environment. Also, it should be possible to mount specific files this way, in addition to directories, should you need to (a directory is just another file in Unix).

As usual, more information can be found by consulting the man pages for the appropriate command for your platform. The commands for other flavors of Unix will be added as needed.

In order to have these tricks persist, to survive a system reboot, the /etc/fstab (or /etc/vfstab) file may need to have these mounts added. Consult your local fstab(5) (or vfstab(4) for Solaris) man pages for more information.

Celý článek na http://www.castaglia.org/proftpd/doc/contrib/ProFTPD-mini-HOWTO-Chroot.html
The most important thing in the programming language is the name. A language will not succeed without a good name. I have recently invented a very good name and now I am looking for a suitable language.
D. E. Knuth, 1967

 

Provoz zaštiťuje spolek OpenAlt.