chiark / gitweb /
found in cvs on davenant
[authbind.git] / authbind-helper.8
1 .\" Hey, Emacs!  This is an -*- nroff -*- source file.
2 .\" Authors: Ian Jackson
3 .\" 
4 .\" authbind is Copyright (C) 1998 Ian Jackson
5 .\"
6 .\" This program is free software; you can redistribute it and/or modify
7 .\" it under the terms of the GNU General Public License as published by
8 .\" the Free Software Foundation; either version 2, or (at your option)
9 .\" any later version.
10 .\"
11 .\" This program is distributed in the hope that it will be useful,
12 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
13 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 .\" GNU General Public License for more details.
15 .\"
16 .\" You should have received a copy of the GNU General Public License
17 .\" along with this program; if not, write to the Free Software Foundation,
18 .\" Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 
19 .\"
20 .\" $Id$
21 .\"
22 .TH AUTHBIND\-HELPER 8 "30th August 1998" "Debian Project" "Debian Linux manual"
23 .br
24 .SH NAME 
25 authbind\-helper \- helper program to bind sockets to privileged ports without root
26 .SH SYNOPSIS
27 .BI /usr/lib/authbind/helper " addr\-hex port\-hex " < socket
28 .SH DESCRIPTION
29 .B helper
30 is the program used by
31 .BR libauthbind ,
32 which is in turn used by
33 .B authbind
34 to allow programs which do not or should not run as root to bind to
35 low-numbered ports in a controlled way.  See
36 .BR authbind (1).
37 .PP
38 It may also be used standalone, i.e. without assistance from
39 .BR authbind .
40 Its standard input should be a TCP/IP socket, and it should be passed
41 two arguments.
42 .PP
43 The arguments are the address and port number, respectively, to which
44 the caller desires that the socket be bound.  They should be hex
45 strings,
46 .I without
47 leading
48 .BR 0x ,
49 of exactly the right length (8 and 4 digits, respectively), being
50 a pairs of hex digits for each byte in the address or port number when
51 expressed in host byte order.  For example, the port argument is the
52 result of something like
53 .B sprintf(arg,
54 .B """%04X"",
55 .BR sin.sin_port) .
56 .PP
57 .B helper
58 will not bind to ports 512 and onwards, because programs like
59 .B rshd
60 expect these to be used for outgoing connections, so allowing a user
61 to bind to one of these would open up security hole(s).
62 .SH EXIT STATUS
63 .B helper
64 will exit with code 0 on success.
65 .PP
66 If possible,
67 .B helper
68 will return an appropriate
69 .B errno
70 value as its exit status.  If this is not possible it may exit with
71 status 255 or with an exit status corresponding to
72 .B ENOSYS
73 .RI ( "Function not implemented" ).
74 .SH ACCESS CONTROL
75 See
76 .BR authbind (1)
77 for details of the access control regime implemented by
78 .BR helper .
79 .SH SEE ALSO
80 .BR authbind (1),
81 .BR bind (2)
82 .SH AUTHOR
83 .B authbind
84 and this manpage were written by Ian Jackson.  They are
85 Copyright (C)1998
86 by him and released under the GNU General Public Licence; there is NO
87 WARRANTY.  See
88 .B /usr/doc/authbind/copyright
89 and
90 .B /usr/doc/copyright/GPL
91 for details.