Hi there. I've had Samba running fo a while now on a machine that we use as a shared file store. Not everyone who uses it has an account on the linux machine, so it's setup with "security = share" to allow guest access to some of the shares. But I've now attached a printer that I dont want guest access to. This might be something really simple that I'm missing, but I can seem to stop the guest account from using the printer! Is it something obvious? I had thought that doing a "guest ok = no" in the printer share would stop it, but I dont get asked for a password, and print jobs are logged (by CUPS) as user nobody. Anyone got any ideas? It's driving me MaAaAaD! Tim. Packages: Samba 2.2.12 CUPS 1.1.22 Samba config: [global] workgroup = FOO server string = File server security = share hosts allow = 127.0.0.1 192.168.0.0/16 interfaces = eth0 lo bind interfaces only = yes log file = /var/log/samba/log.%m log level = 2 syslog = 0 invalid users = root bin daemon adm sync shutdown halt mail news \ uucp operator gopher socket options = SO_KEEPALIVE IPTOS_LOWDELAY TCP_NODELAY veto files = /*.eml/*.nws/riched20.dll/*.{*}/ directory mask = 0755 create mask = 0644 character set = ISO8859-15 client code page = 437 domain master = yes preferred master = yes wins support = yes dns proxy = no username map = /etc/samba/smbusers encrypt passwords = yes load printers = yes printing = cups printcap name = cups [store] comment = Shared File Repository path = /srv/samba/store writeable = yes guest ok = yes guest only = yes force group = samba # Create files read-only and let samba delete them create mask = 444 delete readonly = yes [temp] comment = Temporary Store path = /srv/samba/temp writable = yes guest ok = yes guest only = yes force group = samba [print$] comment = Printer Drivers path = /etc/samba/drivers browseable = yes guest ok = no read only = yes write list = root [LaserPrinter] printer = LaserPrinter comment = Lexmark Optra Color 1200 path = /var/spool/samba browseable = yes guest ok = no writable = no printable = yes
-----Original Message----- From: samba-bounces+andras=kende.com@lists.samba.org [mailto:samba-bounces+andras=kende.com@lists.samba.org] On Behalf Of Tim Sent: Saturday, December 04, 2004 6:43 AM To: samba@lists.samba.org Subject: [Samba] How do I stop the guest account printing? Hi there. I've had Samba running fo a while now on a machine that we use as a shared file store. Not everyone who uses it has an account on the linux machine, so it's setup with "security = share" to allow guest access to some of the shares. But I've now attached a printer that I dont want guest access to. This might be something really simple that I'm missing, but I can seem to stop the guest account from using the printer! Is it something obvious? I had thought that doing a "guest ok = no" in the printer share would stop it, but I dont get asked for a password, and print jobs are logged (by CUPS) as user nobody. Anyone got any ideas? It's driving me MaAaAaD! Tim. Packages: Samba 2.2.12 CUPS 1.1.22 Samba config: [global] workgroup = FOO server string = File server security = share hosts allow = 127.0.0.1 192.168.0.0/16 interfaces = eth0 lo bind interfaces only = yes log file = /var/log/samba/log.%m log level = 2 syslog = 0 invalid users = root bin daemon adm sync shutdown halt mail news \ uucp operator gopher socket options = SO_KEEPALIVE IPTOS_LOWDELAY TCP_NODELAY veto files = /*.eml/*.nws/riched20.dll/*.{*}/ directory mask = 0755 create mask = 0644 character set = ISO8859-15 client code page = 437 domain master = yes preferred master = yes wins support = yes dns proxy = no username map = /etc/samba/smbusers encrypt passwords = yes load printers = yes printing = cups printcap name = cups [store] comment = Shared File Repository path = /srv/samba/store writeable = yes guest ok = yes guest only = yes force group = samba # Create files read-only and let samba delete them create mask = 444 delete readonly = yes [temp] comment = Temporary Store path = /srv/samba/temp writable = yes guest ok = yes guest only = yes force group = samba [print$] comment = Printer Drivers path = /etc/samba/drivers browseable = yes guest ok = no read only = yes write list = root [LaserPrinter] printer = LaserPrinter comment = Lexmark Optra Color 1200 path = /var/spool/samba browseable = yes guest ok = no writable = no printable = yes -- To unsubscribe from this list go to the following URL and read the instructions: lists.samba.org/mailman/listinfo/samba Hello, You may create a [printers] section... You could regard this section as a general convenience shortcut to share all printers with minimal configuration. It is also a container for settings which should apply as default to all printers. Andras Kende kende.com
Thanks for the reply! I've tried it with a general [printers] share as well. Samba still doesn't ask for a username/password for the printer, and it still does the printing as "nobody", the guest user. Is it actually possible to stop guest access to a printer? Tim.
On 06.12.2004 4:20 am, Gerald (Jerry) Carter wrote:> > Tim wrote: > > | Is it actually possible to stop guest access to a printer? > > Use 'security = user' instead of share.Ah, I was hoping you weren't going to say that... The samba server is used by several people, not all of whom have accounts on the linux machine, so I'd much rather have "security = share". I'll give it a try though. At the cost of everyone having to log-on (some with the guest account), I'll gain some printer accounting I suppose! So is this a bug/feature in Samba or something ("guest ok = no" not working for printers when "security = share")? Or is it a flaw in the Windows SMB design? Tim.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 | The samba server is used by several people, not all of whom have ... | Windows SMB design? Tried this?: invalid users = guest Jim C. - -- - ----------------------------------------------------------------- | I can be reached on the following Instant Messenger services: | |---------------------------------------------------------------| | MSN: j_c_llings @ hotmail.com AIM: WyteLi0n ICQ: 123291844 | |---------------------------------------------------------------| | Y!: j_c_llings Jabber: jcllings @ njs.netlab.cz | - ----------------------------------------------------------------- -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (MingW32) Comment: Using GnuPG with Thunderbird - enigmail.mozdev.org iD8DBQFBtSsQ57L0B7uXm9oRAvapAJ0WuPS3qUILvToBlD1kjjHpNmG9pgCfYgUH qp0f1MyWxapTOFLgEMT8qaU=eaLc -----END PGP SIGNATURE-----