possible rlinetd security issue
This is for your interest. A possible minor security bug that is shown (and solved) by SE Linux.
I have a Debian/woody machine that has all the latest security updates installed.
rlinetd is running and has the following file handles open (among many others):
rlinetd 508 root 10u IPv4 5316 TCP
X.X.121.50:discard->211.63.50.60:2286 (CLOSE_WAIT)
rlinetd 508 root 11u IPv4 5317 TCP
X.X.121.32:discard->211.63.50.60:2268 (CLOSE_WAIT)
Now I telnet in to the machine, and SE Linux logs the following messages:
Jan 2 03:01:13 XXX kernel: avc: denied { use } for pid=22617exe=/bin/login path=socket:[5316] dev=00:00 ino=5316 scontext=system_u:system_r:remote_login_t tcontext=system_u:system_r:inetd_t tclass=fd
Jan 2 03:01:13 XXX kernel: avc: denied { use } for pid=22617exe=/bin/login path=socket:[5317] dev=00:00 ino=5317 scontext=system_u:system_r:remote_login_t tcontext=system_u:system_r:inetd_t tclass=fd
This indicates that the file handles that were used for the discard service were not set to close-on-exec. They were not closed by rlinetd between fork() and exec() either. This is a bug in rlinetd. It does not have any immediate security implications, but if the rlinetd
rlinetd version 0.5.9
libc6 version 0.5.9
Linux version 2.4.19
I have not been able to duplicate this bug on Debian/unstable, and all the Woody machines running rlinetd that I run have SE Linux to solve the problem. So it's not something that overly concerns me.
Signature · 10 lines
http://www.coker.com.au/selinux/ My NSA Security Enhanced Linux packages http://www.coker.com.au/bonnie++/ Bonnie++ hard drive benchmark http://www.coker.com.au/postal/ Postal SMTP/POP benchmark http://www.coker.com.au/~russell/ My home page -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.