由 nethawk 在 12-29-2002 14:21 发表:
proftpd文件权限的问题
再请教大家一个问题,就是在 proftpd 中怎么设置一个目录可以分类上传而不可以下载,也就是可以自己上传文件夹和建立文件加而又不能下载,我在wu_ftp下没有实现,在 proftpd 下也没有成功,要么是只能传一个空的文件夹而不能在理面传文件,要么是可以上穿文件夹,但是可以下载。恳请高手们指教一下,真的很急用!!!谢谢!!
由 jamlee800 在 12-29-2002 15:28 发表:
看这个,登陆后可以上传,建目录:
proftpd.conf
#ServerName "GRC FTP Server"
ServerType standalone
DefaultServer on
Port 21 is the standard FTP port.
Port 21
1<limit login="">
2
3DenyAll
4
5</limit>
Umask 022
MaxInstances 30
Set the user and group under which the server will run.
User nobody
Group nobody
DefaultRoot ~
Normally, we want files to be overwriteable.
1<directory></directory>
AllowRetrieveRestart on
AllowOverwrite on ServerIdent Off
#Port 2001
#Umask 027
MaxLoginAttempts 3
A basic anonymous configuration, no upload directories.
1<anonymous book="" ~ftp="">
2<limit login="">
3
4AllowAll
5
6</limit>
7
8
9
10User ftp
11
12Group ftp
13
14
15
16# We want clients to be able to login with "anonymous" as well as "ftp"
17
18UserAlias anonymous ftp
19
20
21
22MaxClients 10
23
24
25
26DisplayLogin welcome.msg
27
28DisplayFirstChdir .message
29
30
31
32# Limit WRITE everywhere in the anonymous chroot
33
34<limit write="">
35
36DenyAll
37
38</limit>
39
40
41
42HideUser root
43
44HideGroup root
45
46
47
48</anonymous>
1<anonymous ftp="" home="" xxx=""> #用用户名、密码登陆后可以上传,加目录等
2
3User xxx
4
5Group xxx
6
7UserAlias xx xxx
8
9AnonRequirePassword on
10
11MaxClients 2
12
13DisplayLogin welcome.msg
14
15DisplayFirstChdir .message
16
17
18
19<limit login="">
20
21AllowGroup xxx
22
23DenyAll
24
25</limit>
26
27
28
29
30
31GroupOwner xxx
32
33Umask 007
34
35
36
37HideUser root
38
39HideGroup root
40
41
42
43</anonymous>
#xxx为登陆用户名。用户名和密码必须是linux有效的,目录必须是用户名和组有读写权限的。
由 jamlee800 在 12-29-2002 15:35 发表:
如果只许上,不许下,可以这样:
1<anonymous ftp="" home="" xxx=""> #用用户名、密码登陆后可以上传,加目录等
2
3User xxx
4
5Group xxx
6
7UserAlias xx xxx
8
9AnonRequirePassword on
10
11MaxClients 2
12
13DisplayLogin welcome.msg
14
15DisplayFirstChdir .message
16
17
18
19<limit login="">
20
21AllowGro</limit></anonymous>