Version 1.3.9
[yazproxy-moved-to-github.git] / README
1 YAZ proxy - A Z39.50/SRU proxy.
2
3 Introduction
4 ------------
5
6 YAZ proxy is a powerful general purpose Z39.50/SRU proxy.
7 The proxy application and development library is covered by the
8 GPL - see LICENSE for details.
9
10 Documentation
11 -------------
12
13 The "doc" directory contains documentation in HTML and PDF.
14 You can also read it online at http://www.indexdata.dk/yazproxy/
15
16 Overview
17 --------
18
19 YAZ proxy builds a programmers' library libyazproxy.lib and a
20 proxy application.
21
22 Directory structure of the YAZ++ package:
23
24   -- src (YAZ proxy library and application)
25   -- include/yazproxy (C++ headers for proxy) 
26   -- win (Windows build files)
27   -- doc (DocBook-format documentation)
28   -- etc (Proxy config + XSLT files)
29
30 About the proxy
31 ---------------
32
33 For the proxy the actual target is determined in by the OtherInfo
34 part of the InitRequest. We've defined an OID for this which we call
35 PROXY. The OID is 1.2.840.10003.10.1000.81.1. 
36
37   OtherInformation   ::= [201] IMPLICIT SEQUENCE OF SEQUENCE{
38     category           [1]   IMPLICIT InfoCategory OPTIONAL, 
39     information        CHOICE{
40       characterInfo            [2]  IMPLICIT InternationalString,
41       binaryInfo               [3]  IMPLICIT OCTET STRING,
42       externallyDefinedInfo    [4]  IMPLICIT EXTERNAL,
43       oid                      [5]  IMPLICIT OBJECT IDENTIFIER}}
44 --
45   InfoCategory ::= SEQUENCE{
46       categoryTypeId   [1]   IMPLICIT OBJECT IDENTIFIER OPTIONAL,
47       categoryValue    [2]   IMPLICIT INTEGER}
48
49 The InfoCategory is present with categoryTypeId set to the PROXY OID
50 and categoryValue set to 1. The information in OtherInformation uses
51 characterInfo to represent the target using the form target[:port][/db].
52
53 For clients that don't set the PROXY OtherInformation, a default
54 target can be specified using option -t for proxy.
55
56 Example:
57   We start the proxy so that it listens on port 9000. The default
58   target is Bell Labs Library unless it is overridden by a client in
59   the InitRequest.
60
61      $ ./yaz-proxy -t z3950.bell-labs.com/books @:9000
62
63   The client is started and talks to the proxy without specifying
64   a target. Hence this client will talk to the Bell Labs server.
65
66      $ ./yaz-client localhost:9000
67
68   The client is started and it specifies the actual target itself.
69
70      $ ./yaz-client -p localhost:9000 bagel.indexdata.dk/gils
71
72   For ZAP the equivalent would be
73      proxy=localhost:9000
74      target=bagel.indexdata.dk/gils
75   Simple, huh!
76