Skip to contentSkip to conversation

some missing printer devices

PATCH Carsten Grohmann 3 participants 3 messages Sep 15, 2002 – Sep 21, 2002 SELinux security module

lore
Share & tools
lore
#0 lore raw

Hi,

The attached patch add some missing printer devices lpd.fc.

Carsten

program/lpd.fc renamed from original/file_contexts/program/lpd.fc +4 -0
@@ -1,5 +1,9 @@
 # lpd
 /dev/printer			system_u:object_r:printer_t
+/dev/lp.*			system_u:object_r:printer_t
+/dev/ttyS.*			system_u:object_r:printer_t
+/dev/usb/lp.*			system_u:object_r:printer_t
+/dev/usblp.*			system_u:object_r:printer_t
 /usr/sbin/lpd			system_u:object_r:lpd_exec_t
 /usr/sbin/checkpc		system_u:object_r:checkpc_exec_t
 /var/spool/lpd(/.*)?		system_u:object_r:lpd_spool_t
#1 lore raw
Quoted 1 line · Carsten Grohmann

The attached patch add some missing printer devices lpd.fc.

/dev/usblp* is not in devices.txt so it's probably not suitable for distributing.

/dev/ttyS* is more commonly used for ppp, the next most common use is for serial port logins. The policy should reflect this, tty_device_t is the current type and it works well.

I can't recall ever seeing a serial printer, modern printers can't be serial because they use too much data transfer. Anyone who has a serial printer will have to do some customising of their policy.

Also when updating policy for /dev entries make sure you update the genfs entries for the devfs file system.

I've added /dev/lp* and /dev/usb/lp* to my policy tree with matching changes to the genfs_contexts file.

Signature · 3 lines
I do not get viruses because I do not use MS software.
If you use Outlook then please do not put my email address in your
address-book so that WHEN you get a virus it won't use my address in the
Quoted 1 line

From field.

--
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.

#2 lore raw
In reply to Carsten Grohmann
Quoted 1 line · Carsten Grohmann

The attached patch add some missing printer devices lpd.fc.

Thanks, merged, except for the cases noted by Russell.

--
Stephen D. Smalley, NAI Labs
[email protected]

--
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.