RE: LPRng: Problem with errors, notification of errors, and job saving...

2003-06-19 Thread Tim
That's the route we've followed in the past (in fact we've got a custom
module to do it), and what we're doing as an interim solution, but I was
hoping to be able to use LPRng's built-in facilities.

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of
Henrik Edlund
Sent: Wednesday, June 18, 2003 4:01 PM
To: [EMAIL PROTECTED]
Subject: Re: LPRng: Problem with errors, notification of errors, and job
saving...


On Wed, 18 Jun 2003, Tim Gaastra wrote:

TG B) Have the operator mailed that error

Do like I do, mail from within your scripts and leave LPRng out of any
mailing other than fatal errors (JREMOVE) to the operator.

Then you can still return JHOLD and still get a mail sent to the person that
handles held jobs.


-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST The
address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests or
lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.

-


-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


LPRng: problems with HP Laserjet 9000 DN...

2003-06-19 Thread Margrit Lottmann
I can't find this printer in the list of supported printers
(ifhp ... HOWTO...)

Which model type can I use ???

I have following problem:
::

Because I couldn't find the exact model type I had configured

a queue for the new printer using model type hp8100
(We are already using such printers successfull!)

printcap-entry:

queue_name
 :lp=xxx.xx.xx.xxx%9100
 :ifhp=model=hp8100,status,sync
 :sd=/var/spool/lpd/queue_name
 :if=/usr/libexec/filters/ifhp
 :bp=/usr/libexec/filters/pclbanner
 :lf=log
 :mx#0:ab


ifhp.conf-entry:

[hp8100]
pcl
ps
text
pjl

file_output_match = [
 *postscript*   ps
 *text* ps /usr/bin/a2ps -q --portrait --margin -1 -b \
   -j --center-title=\%s{f} -u [EMAIL PROTECTED] -M A4  -o-
]

For accounting we are using a modified version of the delivered
accounting.sh script.

The outputs of the printer are ok.
But the accounting values are often bad - getting (p) 0 but 
1 or 2 pages were printed...

I think I had this problem already had (??? with a printer HP4100 ???)

I believe the accounting.sh script gets the end of the job earlier than
the real end ... reading of pagecounter by the accounting filter gets than
 (p) 0 or less pages as really would be printed (?)

What can I do???
::

 getting status-,pagecount-infrmations by using snmp tools ???
 other possibilities ???
--
Mit freundlichen Gruessen  
M.Lottmann

 Otto - von - Guericke  Universitaet  __  __    _ _   __
   Magdeburg / / / /  / __ \__  // | / /
    / / / /  / /_/ / / / __ /  |/ /
   Margrit Lottmann/ /_/ /  / _, _/ / /___// /|  /
   Universitaetsrechenzentrum  \/  /_/ |_| // /_/ |_/
 Netze  Kommunikation


-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


Re: LPRng: problems with HP Laserjet 9000 DN...

2003-06-19 Thread Hans Peter Verne
Margrit Lottmann wrote:
 
 I can't find this printer in the list of supported printers
 (ifhp ... HOWTO...)

No, but you can include it in ifhp.conf yourself.
 
 a queue for the new printer using model type hp8100
 (We are already using such printers successfull!)

I have added it in ifhp.conf thus:

  # PRINTER % - HP Laserjet 8000 Series, {/hp(.*)/HP$1/}
  
  [ hp8000 hp8100 hp8150 hp9000 ]
 ^^

*and* -- because I use the waitend_byjobname patch -- I have
an extra entry like this, a bit furter down:

  #!End of [ hp8000 ]
  
  # PRINTER hp9000
  # New entry, we try this trick here too...
  [ hp9000 ]
  # to fix waitend
  pjl_waitend_byjobname
  
  #!End of [ hp9000 ]

As I understand this, it makes the 9000 inherit whatever 
properties ifhp assumes about the 8000 etc., with the addition 
of pjl_waitend_byjobname.

 For accounting we are using a modified version of the delivered
 accounting.sh script.
 
 The outputs of the printer are ok.
 But the accounting values are often bad - getting (p) 0 but
 1 or 2 pages were printed...
 
 I think I had this problem already had (??? with a printer HP4100 ???)
 
 I believe the accounting.sh script gets the end of the job earlier than
 the real end ... reading of pagecounter by the accounting filter gets than
  (p) 0 or less pages as really would be printed (?)

Yup, both these printers count pages like a dream with the 
above-mentioned patch.  Get it before they are sold out, at 

  http://www.groundsouth.com/patches/ifhp/

Our 2 HP9000's lost the pagecount (ie. counted 0 pages) for only 15 
out of 8210 jobs last month (May).  Our 75 HP4100's missed only 211 jobs,
out of 61514 jobs in the same period.  A miss-rate of less then 0.5%
is very good, I think.


regards,
-- 
Hans Peter   (Usit/Unix-drift,Utskrift)Ni!

Utskrift FAQ: http://www.usit.uio.no/it/utskrift/faq.html
Utskrift Feilsøking:  http://www.usit.uio.no/it/utskrift/feilsok.html

-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


LPRng: Bug in src/common/lpd_status.c

2003-06-19 Thread Henrik Edlund
Concerning handling of force_lpq_status.

On line 132 you can today read this:

Split(l,t,Value_sep,0,0,0,0,0,0);

If I understand this correctly, and look at other examples of calls to
Match_ipaddr_valus, the use of Value_sep here is wrong, as you want to be
able to enumerate IP adresses/masks with comma, and hence need to split on
comma and not on for example an equal sign (=). For this to happen you
should probably use File_sep which is used elsewhere. Problem is of course
that in also contains semicolon, but we have already split on that earlier
to it should be safe to use. But I must again repeat my earlier note that
the relaxed use of separators is biting our ass right here. I would
replace line 132 with

Split(l,t,File_sep,0,0,0,0,0,0);

for the time being, while thinking about redoing the entire separator
scheme in LPRng.

Because I presume that you mean that one should be able to put a
comma-separated list there, I quote the HOWTO:

The entry has the format KEY=list;KEY=list... where KEY is s for short
and l for long format, and list is a list of hosts or IP addresses.

If you use the former (current) version of that line (with Value_sep) you
would have to use the format:

   KEY=ip1=ip2=ip3;KEY=ip4=ip5=ip6

So either the documenation or code is wrong.

Best regards,

   Henrik

-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


LPRng: Re: Rewrite the control file hostname with real requesting hostname

2003-06-19 Thread Henrik Edlund
And yet another fix to this patch, fixing Value_sep to File_sep in one
place. Hopefully this will be the last post about this, as I am rewriting
this patch to put a trusted username in the R record (accounting info) in
the control file instead, and leaving the P record (username) to be
whatever the user sets and hence untrusted.

--- LPRng-3.8.21/src/common/getqueue.c.orig Wed Apr 16 01:37:42 2003
+++ LPRng-3.8.21/src/common/getqueue.c  Thu Jun 19 13:23:11 2003
@@ -2104,11 +2104,53 @@
int status = 0, fd, i;
struct stat statb;

+   struct line_list l, listv;
+   char *s, *t;
+   Init_line_list(l);
+   Init_line_list(listv);
+
if(DEBUGL3) Dump_job( Create_control: before fixing, job );

/* deal with authentication */

Make_identifier( job );
+
+   /*
+* if we get a request from these hosts, change host name in control
+* file (possibly faked if from untrusted host) to FQDN of remote host
+   */
+   if( Force_controlfile_originate_hostname_DYN ){
+   Free_line_list(l);
+   
Split(l,Force_controlfile_originate_hostname_DYN,File_sep,0,0,0,0,0,0);
+   if( Match_ipaddr_value( l, RemoteHost_IP ) == 0 ){
+   DEBUG1(Create_control: remotehost '%s', FQDNRemote_FQDN );
+   Set_str_value(job-info,FROMHOST,FQDNRemote_FQDN);
+   fromhost = Find_str_value(job-info,FROMHOST,Value_sep);
+   }
+   Free_line_list(l);
+   }
+
+   /*
+* if we get a request from these hosts, change user name in control
+* file (possibly faked if from untrusted host) to specified
+   */
+   if( Force_controlfile_username_DYN ){
+   Free_line_list(listv);
+   Split(listv,Force_controlfile_username_DYN,;,0,0,0,0,0,0);
+   for(i = 0; i  listv.count; ++i ){
+   s = listv.list[i];
+   if( (t = safestrpbrk(s,Value_sep)) ) *t++ = 0;
+   Free_line_list(l);
+   Split(l,t,File_sep,0,0,0,0,0,0);
+   if( Match_ipaddr_value( l, RemoteHost_IP ) == 0 ){
+   DEBUG1(Create_control: username '%s', s );
+   Set_str_value(job-info,LOGNAME,s);
+   break;
+   }
+   }
+   Free_line_list(l);
+   Free_line_list(listv);
+   }

if( !(fromhost = Find_str_value(job-info,FROMHOST,Value_sep)) || 
Is_clean_name(fromhost) ){
Set_str_value(job-info,FROMHOST,FQDNRemote_FQDN);

-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


Re: LPRng: Xerox 3400

2003-06-19 Thread Alex Finch

( posted on behalf of Daniel)

 Original Message 
Subject: Re: LPRng: Xerox 3400 (fwd)
Date: Thu, 19 Jun 2003 08:32:02 -0400 (EDT)
From: Daniel Henninger [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: Alex Finch [EMAIL PROTECTED]

My posts to the LPrng list don't ever seem to get through, but we had a
phaser 5400 to test for a bit and the waitend_byjobname worked without
having to use an external script.  See below:

-- Forwarded message --
Date: Thu, 19 Jun 2003 08:30:05 -0400 (EDT)
From: Daniel Henninger [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: Hans Peter Verne [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: LPRng: Xerox 3400

I don't know if this'll make the actual LPRng mailing list... nothing I've
posted for quite some time ever actually appears on the list.  Anyway, we
had a phaser 5400 for testing and what I found that worked quite well was
utilizing the waitend_byjobname patch that was posted on here a little
while ago.  My entry for the phaser5400 for testing was nothing more than:
[ phaser5400 ]
pjl_waitend_byjobname

and it worked great!  Hope that helps.

Daniel

  We just bought 15 Xerox Phaser 4400DT, for deployment with students and
  employees, after testing numerous models from numerous vendors. Reasons
  for picking the Phaser 4400 over the others:

 I don't know if they are related at all, but has anyone had a look
 at the xerox phaser 3400?

 We've got one now, and it seems to me to be one brain-damaged bugger,
 at least when using ifhp!  I'm trying to find a way to make it
 not only print, but also count pages.  The main problem is that
 it won't drop the connection (?) when ifhp dies unexpectedly (killed),
 and thus won't accept new connections unless we power-cycle it!

 I don't know really what happens, perhaps I'm way of the mark here.
 Has anyone any experiences with this printer?


 mvh,
 --
 Hans Peter

 Someday I'm going to catch a website designer in a dark alley and have
 my way with him.  -- hamei at pacbell.net,  comp.sys.sgi.admin

 -
 YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
 The address you post from MUST be your subscription address

 If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
 or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
 to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
 with:   | example:
 subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
 unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

 If you have major problems,  send email to [EMAIL PROTECTED] with the word
 LPRNGLIST in the SUBJECT line.
 -


-- 
/\\\--///\
\ \\\  Daniel Henninger   http://www.vorpalcloud.org//// /
 \_\\\  North Carolina State University - Systems Programmer///_/
\\\   Information Technology IT  ///
 --begin:vcard 
n:Finch;Alex
x-mozilla-html:FALSE
org:Lancaster University;Physics Dept.
adr:;;
version:2.1
email;internet:[EMAIL PROTECTED]
title:Research Fellow
x-mozilla-cpt:;0
fn:Alex Finch
end:vcard


LPRng: Ricoh Afico 350e

2003-06-19 Thread Ryan Novosielski
Can someone help me find a working config for a Ricoh Afico 350e printer
using ifhp? The thing CLAIMS it accepts PS, but it ends up printing the
postscript code, not the image.

 _  _ _  _ ___  _  _  _
|Y#| |  | |\/| |  \ |\ |  |  | Ryan Novosielski - Jr. UNIX Systems Admin
|$| |__| |  | |__/ | \| _|  | [EMAIL PROTECTED] - 973/972.0922 (2-0922)
\__/ Univ. of Med. and Dent. | IST/ACS - NJMS Medical Science Bldg - C630

-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


Re: LPRng: Ricoh Afico 350e

2003-06-19 Thread David Bear
On Thu, Jun 19, 2003 at 11:22:01AM -0400, Ryan Novosielski wrote:
 Can someone help me find a working config for a Ricoh Afico 350e printer
 using ifhp? The thing CLAIMS it accepts PS, but it ends up printing the
 postscript code, not the image.

we have two aficio copy machine/printers, a 340 and a 1055.  Both
printer manuals claimed the machines could handle postscript.  Yet,
when I went to see if this was handled via a queue name like raw or
ps or pcl, I could never determine exactly how -- so I ended up
just sending pcl to the printers.  the aficio documentation is really
lousy!!!  And their network attachment is really poor -- I could not
find any way in either machine to create hosts-allow/deny lists, and
neither one use appsocket -- only the standard plethora of lousy
protocols like netbios, ipx, appletalk and lpd...


-- 
David Bear
phone:  480-965-8257
fax:480-965-9189
College of Public Programs/ASU
Wilson Hall 232
Tempe, AZ 85287-0803
 Beware the IP portfolio, everyone will be suspect of trespassing

-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


LPRng: pjl_waitend_byjobname - HP LJ 4100

2003-06-19 Thread Ryan Novosielski
Can anyone think of why this file, specfically, would not ever get
pjl job/eoj? I killed it a couple of times and resent it, but still...
trouble. Is the jobname a problem somehow on this file? I assume it's not
the actual data of the file, because that DOES print properly AFAIK.

Thanks!

cfA007...:

Aschaefre@//DXQMD01+7
CA
D2003-06-19-12:45:46.445
H130.219.192.177
JOvid: Love: Am J Health Syst Pharm, Volume 59(22) Supplement 8.November 15, 
2002.S10-S15
Pschaefre
Qljptn246
NOvid: Love: Am J Health Syst Pharm, Volume 59(22) Supplement 8.November 15, 
2002.S10-S15
ldfA007ADDR130.219.192.177
UdfA007ADDR130.219.192.177


 _  _ _  _ ___  _  _  _
|Y#| |  | |\/| |  \ |\ |  |  | Ryan Novosielski - Jr. UNIX Systems Admin
|$| |__| |  | |__/ | \| _|  | [EMAIL PROTECTED] - 973/972.0922 (2-0922)
\__/ Univ. of Med. and Dent. | IST/ACS - NJMS Medical Science Bldg - C630

-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


Re: LPRng: Ricoh Afico 350e

2003-06-19 Thread Ryan Novosielski
It claims that everything is sent via [EMAIL PROTECTED] (for LPD) or sent on
port 10001. I so far haven't gotten postscript out of it via LPRng, but a
co-worker of mine says he bypasses the queue and does get PS to work.

Incidentally... I discovered the source of my problem. My boss'
workstation with a standalone driver for the printer prints with PJL in
the header, and the job prints properly. The drivers I have hosted on the
Samba server I have are tacking this onto the beginning of the dfA...'s:

^NM-s^_M-QM--

I don't know what the hell that is, so I really don't know what I could do
with the magic file. It calls a file prefaced with this a data file, and
then for some reason it makes the leap to PS and prints out some PS
headers stairstepped across the page. Does anyone recognize this string as
meaning anything in any language?

 _  _ _  _ ___  _  _  _
|Y#| |  | |\/| |  \ |\ |  |  | Ryan Novosielski - Jr. UNIX Systems Admin
|$| |__| |  | |__/ | \| _|  | [EMAIL PROTECTED] - 973/972.0922 (2-0922)
\__/ Univ. of Med. and Dent. | IST/ACS - NJMS Medical Science Bldg - C630

On Thu, 19 Jun 2003, David Bear wrote:

 On Thu, Jun 19, 2003 at 11:22:01AM -0400, Ryan Novosielski wrote:
  Can someone help me find a working config for a Ricoh Afico 350e printer
  using ifhp? The thing CLAIMS it accepts PS, but it ends up printing the
  postscript code, not the image.

 we have two aficio copy machine/printers, a 340 and a 1055.  Both
 printer manuals claimed the machines could handle postscript.  Yet,
 when I went to see if this was handled via a queue name like raw or
 ps or pcl, I could never determine exactly how -- so I ended up
 just sending pcl to the printers.  the aficio documentation is really
 lousy!!!  And their network attachment is really poor -- I could not
 find any way in either machine to create hosts-allow/deny lists, and
 neither one use appsocket -- only the standard plethora of lousy
 protocols like netbios, ipx, appletalk and lpd...


 --
 David Bear
 phone:480-965-8257
 fax:  480-965-9189
 College of Public Programs/ASU
 Wilson Hall 232
 Tempe, AZ 85287-0803
  Beware the IP portfolio, everyone will be suspect of trespassing

 -
 YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
 The address you post from MUST be your subscription address

 If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
 or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
 to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
 with:   | example:
 subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
 unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

 If you have major problems,  send email to [EMAIL PROTECTED] with the word
 LPRNGLIST in the SUBJECT line.
 -


-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


LPRng: New feature patch set: Write authentication user in control file

2003-06-19 Thread Henrik Edlund
List,

The following patch set implements new features so that you can configure
LPRng to trust certain network address (like those originating on a low
port on your network) and write the user names given in the control from
these as the accounting user field (R) in the control file. You can also
specify a list of untrusted address and what accounting user they will be
given, and also a default user (default _untrusted) for those address
not caught by the trusted and untrusted rules. The accounting user is
passed via the -R flag to all filter and other scripts called from LPRng.

This patch also includes my old feature of rewriting the control file host
name field (H) with the real remote fully qualified domain name (host
name). To rewrite all H fields with real remote host use:

  force_controlfile_originate_hostname=0.0.0.0/0.0.0.0

To turn on the first feature, put in lpd.conf/printcap:

  force_controlfile_accountingname=1

To specify which addresses you trust user names from:

  force_controlfile_accountingname_trusted=10.0.0.0/255.255.255.0

To specify which you don't trust and what to use as their accounting name

  
force_controlfile_accountingname_untrusted=_unauthenticated=192.168.0.0/255.255.0.0,10.0.1.0/255.255.255.0;_public=10.0.2.42

To override default user, set the following variable to something:

  force_controlfile_accountingname_default

All code released under the GPL just like LPRng. Enjoy and report bugs you
find to me. I hope this release will be bug free, but it is first release
so you never know as usual. It has been tested on my production system, so
I should notice pretty quickly if something goes bezerk.

Regards, Henrik--- LPRng-3.8.21/src/include/getqueue.h.origWed Apr 16 01:37:43 2003
+++ LPRng-3.8.21/src/include/getqueue.h Thu Jun 19 12:48:01 2003
@@ -15,6 +15,7 @@
 EXTERN char *CTRL_A_str DEFINE( = \001 );
 
 /* SSL */
+EXTERN const char * ACCNTNAME  DEFINE( = R );
 EXTERN const char * ACTION DEFINE( = action );
 EXTERN const char * ACTIVE_TIMEDEFINE( = active_time );
 EXTERN const char * ADDR   DEFINE( = addr );
--- LPRng-3.8.21/src/common/vars.c.orig Wed Apr 16 01:37:42 2003
+++ LPRng-3.8.21/src/common/vars.c  Thu Jun 19 20:37:39 2003
@@ -230,6 +230,16 @@
 { filter_stderr_to_status_file, 0, FLAG_K, Filter_stderr_to_status_file_DYN,0,0,0},
/*  print a form feed when device is opened */
 { fo, 0,  FLAG_K,  FF_on_open_DYN,0,0,0},
+   /* force control file setting of user name as accounting name */
+{ force_controlfile_accountingname, 0, FLAG_K, 
Force_controlfile_accountingname_DYN,0,0,0},
+   /* use specified user name as accounting name for host names not explicity 
specified under trusted or untrusted */
+{ force_controlfile_accountingname_default, 0, STRING_K, 
Force_controlfile_accountingname_default_DYN,0,0,=_untrusted},
+   /* trust user names as accounting names from specified host names */
+{ force_controlfile_accountingname_trusted, 0, STRING_K, 
Force_controlfile_accountingname_trusted_DYN,0,0,0},
+   /* use specified user names as accounting names for specified host names */
+{ force_controlfile_accountingname_untrusted, 0, STRING_K, 
Force_controlfile_accountingname_untrusted_DYN,0,0,0},
+   /* force control file originate host name for specified host names */
+{ force_controlfile_originate_hostname, 0, STRING_K, 
Force_controlfile_originate_hostname_DYN,0,0,0},
/* force FQDN HOST value in control file */
 { force_fqdn_hostname, 0,  FLAG_K,  Force_FQDN_hostname_DYN,0,0,0},
/* force IPADDR of Originating host for host value in control file */
--- LPRng-3.8.21/src/include/lp.h.orig  Wed Apr 16 01:37:43 2003
+++ LPRng-3.8.21/src/include/lp.h   Thu Jun 19 20:37:18 2003
@@ -303,6 +303,11 @@
 EXTERN char* Filter_path_DYN;
 EXTERN int Fake_large_file_DYN;/* fake large file size if you cannot use 0 */
 EXTERN int Filter_poll_interval_DYN; /* intervals at which to check filter */
+EXTERN int Force_controlfile_accountingname_DYN;   /* force control file setting 
of user name as accounting name */
+EXTERN char* Force_controlfile_accountingname_default_DYN; /* use specified user 
name as accounting name for host names not explicity specified under trusted or 
untrusted */
+EXTERN char* Force_controlfile_accountingname_trusted_DYN; /* trust user names as 
accounting names from specified host names */
+EXTERN char* Force_controlfile_accountingname_untrusted_DYN;   /* use specified user 
names as accounting names for specified host names */
+EXTERN char* Force_controlfile_originate_hostname_DYN; /* force control file 
originate host name for specified host names */
 EXTERN int Force_FQDN_hostname_DYN; /* force FQDN Host name in control file */
 EXTERN int Force_IPADDR_hostname_DYN; /* force IPADDR for Host name in control file */
 EXTERN int Force_localhost_DYN;/* force localhost for client job transfer */
--- 

Re: LPRng: Xerox 3400

2003-06-19 Thread John Perkins
On Wed, 18 Jun 2003 21:52:41 +0200
Hans Peter Verne [EMAIL PROTECTED] wrote:

 
 I don't know if they are related at all, but has anyone had a look
 at the xerox phaser 3400?

Have you tried enabling appsocket when printing to this printer?  

The fact the printer does not accept connections after losing a connection
to it sounds suspiciously like Xerox implemented appsocket on this printer, 
too...you'll probably find the printer accepts connections once the current 
job finishes.  (Now, if the job is hung or waiting for more input, you've 
obviously got a problem...)

-- 

   John Perkins   |   University of Wisconsin-Madison
   Associate Researcher   |   Department of Computer Science
   [EMAIL PROTECTED]  |   1210 W. Dayton St.
   608-262-0438/608-262-9997 FAX  |   Madison, WI  53706-1685





-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-


Re: LPRng: terminating postscript jobs

2003-06-19 Thread Garance A Drosihn
At 1:26 PM -0500 3/18/03, Brandon S Allbery KF8NH wrote:
On Tue, 2003-03-18 at 12:23, Toby Blake wrote:
  postscript seems absolutely fine to me - it finishes with %%EOF.
%%EOF is a PostScript Document Structuring Convention comment;
printers ignore it.  PostScript end-of-job is a control-D.
This depends on how you are sending the job to the printer.  In
some cases, a control-D is just a character which will be read
by the postscript interpreter, and it will generate an error
(for undefined command, or undefined variable).
Of course, Toby did say this was for a locally-attached printer,
so control-D is probably the right solution.  It's just that I
work a lot with network printers and thus I get annoyed when
programs blindly add control-D's at the beginning or end of the
postscript output that they generate.  Control-D is *not* a
postscript command.
But it's reasonable for a print-queue specific filter to add
control-D's, if that will solve the problem.
--
Garance Alistair Drosehn=   [EMAIL PROTECTED]
Senior Systems Programmer   or  [EMAIL PROTECTED]
Rensselaer Polytechnic Instituteor  [EMAIL PROTECTED]
-
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address
If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:   | example:
subscribe LIST mailaddr   |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST mailaddr |  unsubscribe lprng [EMAIL PROTECTED]
If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-