1PR3287(1)                   General Commands Manual                  PR3287(1)
2
3
4

NAME

6       pr3287 - IBM host printing tool
7

SYNOPSIS

9       pr3287 [options] [L:][Y:][LUname[,LUname...]@]hostname[:port][=accept]
10

DESCRIPTION

12       pr3287  opens  a  telnet connection to an IBM host, and emulates an IBM
13       3287 printer.  It implements RFCs 2355  (TN3270E),  1576  (TN3270)  and
14       1646 (LU name selection).
15
16       If  the  hostname  is  prefixed  with  L:,  the connection will be made
17       through an SSL/TLS tunnel.  If the hostname is also prefixed  with  Y:,
18       the  host's  SSL/TLS certificate will not be checked.  pr3287 also sup‐
19       ports TELNET START-TLS option negotiation without any need for command-
20       line options.
21
22       A  specific  LU  name  to  use may be specified by prepending it to the
23       hostname with an `@'.  Multiple LU names to try  can  be  separated  by
24       commas.  An empty LU can be placed in the list with an extra comma.
25
26       The  port  to connect to defaults to telnet.  This can be overridden by
27       appending a port to the hostname with a colon `:'.
28
29       An accept name (a name to compare to the  host's  SSL/TLS  certificate)
30       may be specified by appending it with an equals sign.
31

OPTIONS

33       pr3287 understands the following options:
34
35       -accepthostname name
36              Specifies  a  particular  hostname to accept when validating the
37              name presented in the server SSL certificate, instead of compar‐
38              ing to the name used to make the connection.  name can either be
39              any (OpenSSL only), which disables name validation,  or  a  spe‐
40              cific name.
41
42       -assoc LUname
43              Causes the session to be associated with the specified LUname.
44
45       -blanklines
46              In  LU3  formatted  mode, print blank lines even if they are all
47              NULLs or control characters.  (This is a violation of  the  3270
48              printer protocol, but some hosts require it.)
49
50       -cadir directory
51              Specifies  a  directory containing CA (root) certificates to use
52              when verifying a certificate  provided  by  the  host.  (OpenSSL
53              only)
54
55       -cafile filename
56              Specifies a PEM-format file containing CA (root) certificates to
57              use when verifying a certificate provided by the host.  (OpenSSL
58              only)
59
60       -certfile filename
61              Specifies  a  file  containing  a  certificate to provide to the
62              host.  The default file type is PEM (OpenSSL) or PKCS12 (MacOS).
63
64       -certfiletype type
65              Specifies the type of the certificate file specified  by  -cert‐
66              file.  Type can be pem or asn1. (OpenSSL only)
67
68       -chainfile filename
69              Specifies  a  certificate chain file in PEM format, containing a
70              certificate to provide to the host,  as  well  as  one  or  more
71              intermediate  certificates  and  the CA certificate used to sign
72              that certificate.  If  -chainfile  is  specified,  it  overrides
73              -certfile. (OpenSSL only)
74
75       -clientcert name
76              Specifies  the  name  of  a client certificate to provide to the
77              host. It must be installed in the keychain. (MacOS only)
78
79       -charset name
80              Specifies an alternate host code page  (input  EBCDIC  mapping).
81              The default maps the U.S. English (037) code page to the current
82              locale character encoding.  pr3287 generally supports  the  same
83              host character sets as x3270.
84
85       -command command
86              Specifies the command to run for each print job.  The default is
87              lpr.
88
89       -crlf  Causes newline characters in the output to be expanded  to  car‐
90              riage-return/linefeed sequences.
91
92       -crthru
93              In  unformatted  3270 mode, causes EBCDIC CR orders to be passed
94              to directly to the printer as ASCII CR characters, and the  out‐
95              put buffer to be flushed, instead of being specially interpreted
96              by pr3287.
97
98              By default, EBCDIC CRs cause the (virtual) print head to  return
99              to  column 0, so that subsequent text overwrites what is already
100              in the buffer, and the buffer is flushed only when an EBCDIC  NL
101              or EM order is received.
102
103       -daemon
104              Causes pr3287 to become a daemon (background) process.
105
106       -eojtimeout seconds
107              Causes pr3287 to complete the print job after seconds seconds of
108              inactivity.
109
110       -emflush
111              Causes pr3287 to flush any pending printer output whenever an EM
112              (End  of  Medium)  order arrives in unformatted 3270 mode.  This
113              can help preserve multi-page output with hosts that do not clear
114              the  3270  buffer  between pages.  (Note: This option is defined
115              for historical purposes only; -emflush is now the default.)
116
117       -noemflush
118              Causes pr3287 not to flush any pending printer output when an EM
119              (End of Medium) order arrives in unformatted 3270 mode.
120
121       -ignoreeoj
122              Ignore TN3270E PRINT-EOJ commands, relying on UNBIND commands to
123              indicate the ends of print jobs.
124
125       -ffeoj Causes pr3287 to add a FF (formfeed) at the end  of  each  print
126              job.
127
128       -ffskip
129              Causes  pr3287  to  ignore a FF (formfeed) order if it occurs at
130              the top of a page.
131
132       -ffthru
133              In SCS mode, causes pr3287 to pass FF (formfeed) orders  through
134              to  the  printer as ASCII formfeed characters, rather than simu‐
135              lating them based on the values of the MPL (maximum presentation
136              line) and TM (top margin) parameters.
137
138       -keyfile filename
139              Specifies  a file containing the private key for the certificate
140              file (specified via -certfile or -chainfile).  The default  file
141              type is PEM. (OpenSSL only)
142
143       -keyfiletype type
144              Specifies  the  type  of the private key file specified by -key‐
145              file.  Type can be pem or asn1. (OpenSSL only)
146
147       -keypasswd type:value
148              Specifies the password for  the  private  key  file,  if  it  is
149              encrypted.   The  argument can be file:filename, specifying that
150              the password is in a  file,  or  string:string,  specifying  the
151              password on the command-line directly.
152
153       -mpp n Specifies a non-default value for the Maximum Presentation Posi‐
154              tion (the line length  for  unformatted  Write  commands).   The
155              default is 132.  The minimum is 40 and the maximum is 256.
156
157
158       -noverifycert
159              Do not verify the host certificate for SSL/TLS connections.
160
161       -proxy type:host[:port]
162              Causes  pr3287  to  connect  via the specified proxy, instead of
163              using a direct connection.  The host can be  an  IP  address  or
164              hostname.   The optional port can be a number or a service name.
165              For a list of supported proxy types, see PROXY below.
166
167       -reconnect
168              Causes pr3287 to reconnect to the host, whenever the  connection
169              is   broken.   There  is  a  5-second  delay  between  reconnect
170              attempts, to reduce network thrashing for down or  misconfigured
171              hosts.
172
173       -skipcc
174              For  unformatted  writes,  skip  ASA carriage control characters
175              (e.g., blank for single-space, 0 for double-space, 1  for  form‐
176              feed, etc.) in the first position of each line of host output.
177
178       -trace Turns  on  data  stream  tracing.   Trace information is usually
179              saved in the file /tmp/x3trc.pid.
180
181       -tracedir dir
182              Specifies the directory to save trace files in, instead of /tmp.
183
184       -trnpre file
185              Specifies a file containing  data  that  will  be  sent  to  the
186              printer before each print job.  The file contents are treated as
187              transparent data, i.e., they are not translated in any way.
188
189       -trnpost file
190              Specifies a file containing  data  that  will  be  sent  to  the
191              printer  after each print job.  The file contents are treated as
192              transparent data, i.e., they are not translated in any way.
193
194       -v     Display build and version information and exit.
195
196       -verifycert
197              Verify the host certificate for SSL/TLS  connections.  (This  is
198              the default setting.)
199
200       -xtable file
201              Specifies  a file containing transparent data translations.  The
202              file specifies EBCDIC characters that will  be  translated  into
203              transparent ASCII data (data that will not be further translated
204              and will not count as taking up column(s) on  the  print  line).
205              Any  printable  ECBDIC  code  can  be translated to zero or more
206              ASCII characters.
207
208              The table consists of lines that look like:
209              ebcdic ebcdic-code ascii ascii-code...
210
211
212              The ebcdic-code can be specified in hexadecimal  X'nn'  notation
213              or  as numbers in decimal, octal (with a leading 0) or hexadeci‐
214              mal (with a leading 0x).  The ascii-codes can  be  specified  as
215              numbers  in decimal, octal or hexadecimal, control codes such as
216              ^X, symbolic control codes such as CR or Escape, or  as  double-
217              quoted  strings, following the full C-language conventions, such
218              as \r for a carriage return.  Comments begin with #, ! or //.
219
220              Here are some examples of translations.
221              # Expand EBCDIC D to an escape sequence.
222              ebcdic X'C4' ascii Esc "]1,3" 0x6d
223              # Delete EBCDIC B's
224              ebcdic X'C2' ascii
225
226              The full list of symbolic control codes is: BS CR BEL ESC ESCAPE
227              FF HT LF NL NUL SPACE TAB VT.
228

SIGNALS

230       SIGINT,  SIGHUP  and  SIGTERM cause the current print job to be flushed
231       (any pending data to be printed) and pr3287 to exit.
232
233       SIGUSR1 causes the current print job to be  flushed  without  otherwise
234       affecting the pr3287 process.
235
236

PROXY

238       The -proxy option causes pr3287 to use a proxy server to connect to the
239       host.  The syntax of the option is:
240              type:host[:port]
241
242       The supported values for type are:
243
244                    Proxy Type   Protocol            Default Port
245                    ──────────────────────────────────────────────
246                       http      RFC 2817 HTTP           3128
247                                 tunnel (squid)
248                     passthru    Sun in.telnet-gw        none
249                      socks4     SOCKS version 4         1080
250                      socks5     SOCKS version 5         1080
251                                 (RFC 1928)
252                      telnet     No protocol (just       none
253                                 send connect host
254                                 port)
255
256       The special types socks4a and socks5d can also be  used  to  force  the
257       proxy server to do the hostname resolution for the SOCKS protocol.
258

SEE ALSO

260       x3270(1), c3270(1), telnet(1), tn3270(1)
261       Data Stream Programmer's Reference, IBM GA23-0059
262       Character Set Reference, IBM GA27-3831
263       3174 Establishment Controller Functional Description, IBM GA23-0218
264       RFC 1576, TN3270 Current Practices
265       RFC 1646, TN3270 Extensions for LUname and Printer Selection
266       RFC 2355, TN3270 Enhancements
267

COPYRIGHTS

269       Copyright 1993-2020, Paul Mattes.
270       Copyright 1990, Jeff Sparkes.
271       Copyright 1989, Georgia Tech Research Corporation (GTRC), Atlanta, GA
272        30332.
273       All rights reserved.
274
275       Redistribution  and  use  in  source  and binary forms, with or without
276       modification, are permitted provided that the following conditions  are
277       met:
278
279
280       *      Redistributions  of  source code must retain the above copyright
281              notice, this list of conditions and the following disclaimer.
282
283       *      Redistributions  in  binary  form  must  reproduce   the   above
284              copyright  notice,  this  list  of  conditions and the following
285              disclaimer in the documentation and/or other materials  provided
286              with the distribution.
287
288       *      Neither  the  names  of  Paul Mattes, Jeff Sparkes, GTRC nor the
289              names of their contributors may be used to  endorse  or  promote
290              products  derived  from  this  software  without  specific prior
291              written permission.
292
293       THIS SOFTWARE IS PROVIDED BY PAUL MATTES, JEFF SPARKES AND GTRC `AS IS'
294       AND  ANY  EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
295       THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A  PARTICULAR
296       PURPOSE  ARE DISCLAIMED. IN NO EVENT SHALL PAUL MATTES, JEFF SPARKES OR
297       GTRC  BE  LIABLE  FOR  ANY  DIRECT,  INDIRECT,   INCIDENTAL,   SPECIAL,
298       EXEMPLARY,  OR  CONSEQUENTIAL  DAMAGES  (INCLUDING, BUT NOT LIMITED TO,
299       PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;  LOSS  OF  USE,  DATA,  OR
300       PROFITS;  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
301       LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,  OR  TORT  (INCLUDING
302       NEGLIGENCE  OR  OTHERWISE)  ARISING  IN  ANY WAY OUT OF THE USE OF THIS
303       SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
304

VERSION

306       pr3287 3.6ga10
307
308
309
310                               23 February 2020                      PR3287(1)
Impressum