SUMMARY: CAP printing problem

From: Oscar D. Knight <odk_at_cs.cs.appstate.edu>
Date: Mon, 28 Jul 1997 16:27:38 -0400 (EDT)

Hello,

  Thanks to Bob Berrigan and Erik Persson for their quick responses.
In short it was a permission problem. I added write permission to
the group of the filter devices and made papif set-gid.

# cd /dev/pf
# chmod g+w *

# cd /usr/local/cap
# chmod g+s papif

Worked like a charm!

This group is GREAT!

--------------------------
Orig messages follow:

My query:

    I've installed cap60. I only want to use it for printing.

    It seems to ALMOST be working.

    The following error message is in the printer error message
    file, ie the one specified in printcap:
    <<
    open: tu0: Permission denied
    NBPInit: DDPOpenSocket error 13
    papif: Starting job for odk_at_sc.cs.appstate.edu at Fri Jul 25 19:33:20 1997
    on printer Math 2nd WR, LJ 4MV:LaserWriter_at_Ethernet
    NBP nbpFcn: nbpInit not called>>
    Filter 'f' terminated (sig=112,err=-1)

    HOWEVER, if I use papif directly it works, ie no lpr, just pipe a
    ps file to papif.

    Any help will be appreciated!!!!

    Thank,
    odk
-------------

Responses:

 From: Bob Berrigan
    From berrigan_at_kent.wednet.edu Sat Jul 26 09:42:41 1997
    Received: from OASIS.WSIPC.WEDNET.EDU (oasis.wsipc.wednet.edu )
            by cs.cs.appstate.edu (8.8.6/8.8.6) with SMTP id JAA00813
            for <odk_at_cs.appstate.edu>; Sat, 26 Jul 1997 09:42:40 -0400 (EDT)
    Received: from sun.kent.wednet.edu by OASIS.WSIPC.WEDNET.EDU via Pony
              Express SMTP with TCP (v9.5.0-moe002); Sat, 26 Jul 97 06:42:35
    Received: from [164.116.197.23] by sun.kent.wednet.edu;
              (5.65v3.0/1.1.8.2/13Dec95-1108AM) id AA11174; Sat,
              26 Jul 1997 06:42:36 -0700
    Date: Sat, 26 Jul 1997 06:42:36 -0700
    Message-Id: <9707261342.AA11174_at_sun.kent.wednet.edu>
    X-Sender: berrigan_at_mailhost
    X-Mailer: Windows Eudora Version 1.4.4
    Mime-Version: 1.0
    Content-Type: text/plain; charset="us-ascii"
    To: odk_at_cs.appstate.edu (Oscar Knight)
    From: berrigan_at_kent.wednet.edu (Bob Berrigan)
    Subject: Re: CAP printing problem
    Content-Length: 1065
    Status: RO

    Hi Oscar,

    I assume you've included the PACKETFILTER option and made the 'pfilt'
    devices. Check the permissions on the 'pfilt' devices. Mine are...

    # cd /dev/pf
    # ls -l
    crw-rw---- 1 root system 13, 0 Jul 26 06:31 pfilt0
    crw-rw---- 1 root system 13, 1 Jul 5 17:54 pfilt1
    crw-rw---- 1 root system 13, 10 Jul 15 16:29 pfilt10

    Also, make sure your queue device has the right permissions. Here's
    mine...

    # cd /dev
    # ls -l ch*
    -rw-rw---- 1 root daemon 0 Mar 1 17:12 ch.admin.p630

    Hope this helps,

    Bob Berrigan
    Kent School District

>The following error message is in the printer error message
>file, ie the one specified in printcap:
> <<
> open: tu0: Permission denied
> NBPInit: DDPOpenSocket error 13
> papif: Starting job for odk_at_sc.cs.appstate.edu at Fri Jul 25 19:33:20
> on printer Math 2nd WR, LJ 4MV:LaserWriter_at_Ethernet
> NBP nbpFcn: nbpInit not called>>
> Filter 'f' terminated (sig=112,err=-1)
>
>HOWEVER, if I use papif directly it works, ie no lpr, just pipe a
>ps file to papif.
-------------

 From: Erik Persson

     From erik_at_lysator.liu.se Sat Jul 26 08:54:45 1997
     Received: from lysander.lysator.liu.se (root_at_mailhost.lysator.liu.se)
             by cs.cs.appstate.edu (8.8.6/8.8.6) with ESMTP id IAA00671
             for <odk_at_cs.appstate.edu>; Sat, 26 Jul 1997 08:54:44 -0400 (EDT)
     Received: from tingeling.lysator.liu.se (erik_at_tingeling.lysator.liu.se )
             by lysander.lysator.liu.se (8.8.5/8.8.5) with ESMTP id OAA24655
             for <odk_at_cs.appstate.edu>; Sat, 26 Jul 1997 14:16:50 +0200
     Received: (from erik_at_localhost)
               by tingeling.lysator.liu.se (8.8.4/8.8.4)
               id OAA24940; Sat, 26 Jul 1997 14:16:45 +0200 (MET DST)
     To: odk_at_cs.appstate.edu (Oscar Knight)
     Subject: Re: CAP printing problem
     References: <9707252353.AA28800_at_cs.cs.appstate.edu>
     From: Erik Persson <erik_at_lysator.liu.se>
     Date: 26 Jul 1997 14:16:44 +0200
     In-Reply-To: odk_at_cs.appstate.edu's message of "Fri, 25 Jul 1997 19:53:56
     Message-ID: <jlvi1yvwib.fsf_at_tingeling.lysator.liu.se>
     Lines: 42
     X-Mailer: Gnus v5.4.59/Emacs 19.34
     Content-Length: 1299
     Status: RO

     odk_at_cs.appstate.edu (Oscar Knight) writes:

> Hello,
>
> I've installed cap60. I only want to use it for printing.
>
> It seems to ALMOST be working.
>
> The following error message is in the printer error message
> file, ie the one specified in printcap:
> <<
> open: tu0: Permission denied
> NBPInit: DDPOpenSocket error 13
> papif: Starting job for odk_at_sc.cs.appstate.edu at Fri Jul 25 19:33:20
> on printer Math 2nd WR, LJ 4MV:LaserWriter_at_Ethernet
> NBP nbpFcn: nbpInit not called>>
> Filter 'f' terminated (sig=112,err=-1)
>
> HOWEVER, if I use papif directly it works, ie no lpr, just pipe a
> ps file to papif.
>
> Any help will be appreciated!!!!
>
> Thank,
> odk
> --
> Oscar D. Knight | odk_at_cs.appstate.edu
>

     Your problem is that papif needs write permission for the packetfilter
     devices as it most often not is run with uid 0 when invoked by lpd.

     Your problem should go away if you either make papif setuid root or
     setgid system (the latter should provide somewhat better security but
     also requires you to change the permissions of /dev/pf/* to 664).

     /Erik

     --
     Erik Persson Home: +46 13 12 38 89
     Banergatan 9 Work: +46 13 28 24 64
     582 32 Linkoping, Sweden e-mail: erik_at_lysator.liu.se



Thanks Again!
odk
-- 
Oscar D. Knight                      |  odk_at_cs.appstate.edu
Received on Mon Jul 28 1997 - 22:38:06 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:36 NZDT