From owner-freebsd-bugs@FreeBSD.ORG Fri Nov 26 16:00:57 2004 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4D5DD16A597 for ; Fri, 26 Nov 2004 16:00:57 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2BAC043D66 for ; Fri, 26 Nov 2004 16:00:57 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.1/8.13.1) with ESMTP id iAQG0uBl006059 for ; Fri, 26 Nov 2004 16:00:56 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.1/8.13.1/Submit) id iAQG0u6d006044; Fri, 26 Nov 2004 16:00:56 GMT (envelope-from gnats) Resent-Date: Fri, 26 Nov 2004 16:00:56 GMT Resent-Message-Id: <200411261600.iAQG0u6d006044@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Ted Mittelstaedt Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8510216A4CE for ; Fri, 26 Nov 2004 15:56:28 +0000 (GMT) Received: from nat-rtr.freebsd-corp-net-guide.com (nat-rtr.freebsd-corp-net-guide.com [65.75.197.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2536E43D60 for ; Fri, 26 Nov 2004 15:56:28 +0000 (GMT) (envelope-from tedm@nat-rtr.freebsd-corp-net-guide.com) Received: from nat-rtr.freebsd-corp-net-guide.com (localhost.freebsd-corp-net-guide.com [127.0.0.1])iAQFuRq9042549 for ; Fri, 26 Nov 2004 07:56:27 -0800 (PST) (envelope-from tedm@nat-rtr.freebsd-corp-net-guide.com) Received: (from root@localhost)iAQFuQ2A042548; Fri, 26 Nov 2004 07:56:26 -0800 (PST) (envelope-from tedm) Message-Id: <200411261556.iAQFuQ2A042548@nat-rtr.freebsd-corp-net-guide.com> Date: Fri, 26 Nov 2004 07:56:26 -0800 (PST) From: Ted Mittelstaedt To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: bin/74418: lpd creates lock file with bad permissions under remote LPR X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Ted Mittelstaedt List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 26 Nov 2004 16:00:57 -0000 >Number: 74418 >Category: bin >Synopsis: lpd creates lock file with bad permissions under remote LPR >Confidential: no >Severity: critical >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Nov 26 16:00:56 GMT 2004 >Closed-Date: >Last-Modified: >Originator: Ted Mittelstaedt >Release: FreeBSD 4.9-RELEASE i386 >Organization: >Environment: System: FreeBSD nat-rtr.freebsd-corp-net-guide.com 4.9-RELEASE FreeBSD 4.9-RELEASE #3: Fri Dec 5 00:52:56 PST 2003 tedm@nat-rtr.freebsd-corp-net-guide.com:/usr/src/sys/compile/MAIL i386 >Description: When a brand new print queue is defined for lpd, (ie: /var/spool/output/new-lp) it does not contain a .seq, lock or status file. These files are automatically created by the lpd daemon when it gets it's first job and are reused by subsequent jobs. If the job originates locally, the files are created as follows: -rw-r----x 1 root daemon 4 Nov 26 07:39 .seq -rw-rw-r-- 1 root daemon 30 Nov 26 07:40 lock -rw-rw-r-- 1 root daemon 24 Nov 26 07:40 status If the job is a remote job that is sent via the lpr protocol to the system, the lock file is created as such: ------xr-- 1 root daemon 30 Nov 26 07:41 lock Because lpd cannot modify the lock file this stops future jobs to the queue. If permissions are manually modified to the lock file, chmod 664, then everything works fine. The problem will not recurr unless the lock file is manually deleted and recreated by lpd with a lpr job. The remote system sending to the FreeBSD system in this case was a Solaris 2.5.1 system, I don't know if that has any bearing on it or not. >How-To-Repeat: >Fix: workaround is when creating a new queue, to run a local job through it first. Or fix the lock file permissions manually. >Release-Note: >Audit-Trail: >Unformatted: