macos - OS X Yosemite 中的 FTP 服务

标签 macos ftp server osx-yosemite

-- OS X YOSEMITE 中的 FTP 服务 --

我已在 Yosemite 中使用以下命令启动了 FTP 服务:

 sudo -s launchctl load -w /System/Library/LaunchDaemons/ftp.plist

然后,我需要配置它。有人知道它是由哪个文件配置的吗?另外,如何将“chroot”设置为目录。

最佳答案

OS X ftp 守护进程由以下文件配置:

/etc/ftpd.conf
/etc/ftpchroot
/etc/ftpusers

示例文件:cat/usr/share/ftpd/examples/ftpd.conf

/private/etc/ftpusers

The ftpusers file provides user access control for tnftpd(8) by defining which users may login.

If the ftpusers file does not exist, all users are denied access.

示例文件:cat/usr/share/ftpd/examples/ftpusers

/private/etc/ftpchroot

The file /private/etc/ftpchroot is used to determine which users will have their session's root directory changed (using chroot(2)), either to the directory specified in the ftpd.conf(5) chroot directive (if set), or to the home directory of the user. If the file does not exist, the root directory change is not performed.

The syntax is similar to ftpusers, except that the class argument is ignored. If there's a positive match, the session's root directory is changed. No further comparisons are attempted after the first successful match. This syntax is backward-compatible with the old syntax.

示例文件:cat/usr/share/ftpd/examples/ftpchroot

chroot目录,(例如guest):

chroot guest /path/to/guest/accessable/ftp

更多信息:ftpd.conf , ftpusers/ftpchroot , chroot

关于macos - OS X Yosemite 中的 FTP 服务,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31093733/

相关文章:

android - opencv,链接C静态库../lib/armeabi-v7a/liblibjpeg.a

performance - 优化elasticsearch/JVM

java - 如何将 Java 应用程序捆绑到 Mac OS X *.app bundle ?

c# - 检索文件的创建日期 (FTP)

shell - 如何在任何时候恢复 ftp 下载? (shell 脚本,wget 选项)?

ftp - 基于 Web 的 FTP 客户端和代码编辑器

c - 使用 select() 在现有客户端或新客户端之间进行选择 (C)

node.js - 从我的代码连接到我的 redis 服务器时出错

swift - 登录成功后切换到另一个屏幕

swift - 如何在 MacOS 上实现 VoiceOver 可访问的 NSSlider?