[cups.general] Get snmp backend output in "lpinfo -v" output?

Johannes Meixner jsmeix at suse.de
Wed Nov 26 23:43:48 PST 2008


Hello,

On Nov 26 14:34 Michael R Sweet wrote:
> Johannes Meixner wrote:
>> I run CUPS version 1.3.7.
>>
>> When I run the snmp backend, it finds some network printers
>> but it seems this info cannot be made available via "lpinfo -v".
>>
>> Is there a way (preferably a comand line option) that
>> "lpinfo -l -v" has also the snmp backend output included?
>
> If you mean the debug output, no.

I.e. you mean the usual stdout output of the snmp backend
should appear in the "lpinfo -l -v" output.
Many Thanks!
This helped me to find out why it does not work for me:

On my system I have (long lines wrapped here):
-------------------------------------------------------------
root at host# /usr/lib/cups/backend/snmp
network socket://10.10.100.225 "HP Color LaserJet CP3505"
  "HP Color LaserJet CP3505 10.10.100.225" ""
network socket://10.10.129.192 "FS-1700+"
  "FS-1700+ 10.10.129.192" ""
network socket://10.10.222.4 "HP LaserJet 4050 Series "
  "HP LaserJet 4050 Series  10.10.222.4" ""
-------------------------------------------------------------
root at host# lpinfo -v
network socket
network beh
direct hal
direct hpfax
direct parallel:/dev/lp0
direct hp:/par/HP_LaserJet_1220?device=/dev/parport0
direct usb://HP/LaserJet%201220
direct hp:/usb/HP_LaserJet_1220?serial=00XXXXXXXXXX
network http
network ipp
network lpd
network novell
file pipe
direct scsi
network smb
-------------------------------------------------------------

This is the content of my snmp.conf file
-------------------------------------------------------------
# egrep -v "^#|^$" /etc/cups/snmp.conf
Address @LOCAL
Community public
-------------------------------------------------------------

Now the reason why it fails on my system:
-------------------------------------------------------------
root at host# su - lp
lp at host$ /usr/lib/cups/backend/snmp
DEBUG: No address specified and no Address line
in /etc/cups/snmp.conf...
-------------------------------------------------------------
root at host# ls -l /etc/cups/snmp.conf
-rw-r----- 1 root root ... /etc/cups/snmp.conf
-------------------------------------------------------------

After
chown root:lp /etc/cups/snmp.conf
it works.

According to
http://www.cups.org/documentation.php/doc-1.4/ref-snmp-conf.html
there are no secrets in /etc/cups/snmp.conf
so that I think it does not make sense to have
its access permissions so restrictive.

Are there possible security issues when snmp.conf
can be read by "lp"?


Kind Regards
Johannes Meixner
-- 
SUSE LINUX Products GmbH, Maxfeldstrasse 5, 90409 Nuernberg, Germany
AG Nuernberg, HRB 16746, GF: Markus Rex





More information about the cups mailing list