Skip to contentSkip to conversation

ftp: fix labels in /var/lock/subsys/

PATCH New Nicolas Iooss 2 participants 2 messages Jul 5, 2014 – Jul 8, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ftp: fix labels in /var/lock/subsys/

In the pattern "/var/lock/subsys/*.ftpd", the star is applied to the slash instead to the dot. This means that the pattern matches these files:

* "Xftpd" in "/var/lock/subsys/" (where X is whatever character)
* "subsysXftpd" in "/var/lock/" (where X is whatever character)

"/var/lock/subsys/vsftpd", which has been used by vsftpd, is therefore not matched by the pattern.

As "*." looks like a typo, this patch replaces it with ".*".

---
 ftp.fc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
ftp.fc +1 -1
index ddb75c1..fa132af 100644
@@ -19,7 +19,7 @@
 
 /usr/libexec/webmin/vsftpd/webalizer/xfer_log	--	gen_context(system_u:object_r:xferlog_t,s0)
 
-/var/lock/subsys/*.ftpd	--	gen_context(system_u:object_r:ftpd_lock_t,s0)
+/var/lock/subsys/.*ftpd	--	gen_context(system_u:object_r:ftpd_lock_t,s0)
 
 /var/log/muddleftpd\.log.*	--	gen_context(system_u:object_r:xferlog_t,s0)
 /var/log/proftpd(/.*)?	gen_context(system_u:object_r:xferlog_t,s0)
Signature · 1 line
2.0.1
#1 lore raw

PATCH 1/1 ftp: fix labels in /var/lock/subsys/

Quoted 11 lines · Nicolas Iooss

In the pattern "/var/lock/subsys/*.ftpd", the star is applied to the slash instead to the dot. This means that the pattern matches these files:

* "Xftpd" in "/var/lock/subsys/" (where X is whatever character)
* "subsysXftpd" in "/var/lock/" (where X is whatever character)

"/var/lock/subsys/vsftpd", which has been used by vsftpd, is therefore not matched by the pattern.

As "*." looks like a typo, this patch replaces it with ".*".

Merged.

Quoted 18 lines
---
 ftp.fc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
ftp.fc +1 -1
index ddb75c1..fa132af 100644
@@ -19,7 +19,7 @@
 
 /usr/libexec/webmin/vsftpd/webalizer/xfer_log	--	gen_context(system_u:object_r:xferlog_t,s0)
 
-/var/lock/subsys/*.ftpd	--	gen_context(system_u:object_r:ftpd_lock_t,s0)
+/var/lock/subsys/.*ftpd	--	gen_context(system_u:object_r:ftpd_lock_t,s0)
 
 /var/log/muddleftpd\.log.*	--	gen_context(system_u:object_r:xferlog_t,s0)
 /var/log/proftpd(/.*)?	gen_context(system_u:object_r:xferlog_t,s0)
Signature · 3 lines
Chris PeBenito
Tresys Technology, LLC
www.tresys.com | oss.tresys.com