Fix markup. Fix backslashes to surive roff.
[netbsd-mini2440.git] / usr.sbin / sdpd / sdpd.8
blob4f655dc3f1587c01cbb2fd58cbc9ff65de918aa1
1 .\" $NetBSD: sdpd.8,v 1.7 2009/08/20 15:51:28 joerg Exp $
2 .\"
3 .\" Copyright (c) 2009 The NetBSD Foundation, Inc.
4 .\" Copyright (c) 2004 Maksim Yevmenkin <m_evmenkin@yahoo.com>
5 .\" All rights reserved.
6 .\"
7 .\" Redistribution and use in source and binary forms, with or without
8 .\" modification, are permitted provided that the following conditions
9 .\" are met:
10 .\" 1. Redistributions of source code must retain the above copyright
11 .\"    notice, this list of conditions and the following disclaimer.
12 .\" 2. Redistributions in binary form must reproduce the above copyright
13 .\"    notice, this list of conditions and the following disclaimer in the
14 .\"    documentation and/or other materials provided with the distribution.
15 .\"
16 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
17 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
20 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26 .\" SUCH DAMAGE.
27 .\"
28 .\" $FreeBSD: src/usr.sbin/bluetooth/sdpd/sdpd.8,v 1.5 2005/12/06 17:56:36 emax Exp $
29 .\"
30 .Dd May 7, 2009
31 .Dt SDPD 8
32 .Os
33 .Sh NAME
34 .Nm sdpd
35 .Nd Bluetooth Service Discovery Protocol daemon
36 .Sh SYNOPSIS
37 .Nm
38 .Op Fl dh
39 .Op Fl c Ar path
40 .Op Fl G Ar group
41 .Op Fl g Ar group
42 .Op Fl u Ar user
43 .Sh DESCRIPTION
44 The
45 .Nm
46 daemon keeps a database of Bluetooth Service Records registered on
47 the host and responds to Service Discovery inquiries from remote
48 Bluetooth devices.
49 .Pp
50 In order to discover services, remote Bluetooth devices send Service
51 Search and Service Attribute or Service Search Attribute requests over
52 Bluetooth L2CAP connections on the SDP PSM (0x0001).
53 The
54 .Nm
55 daemon will try to find matching Service Records in its Service Database
56 and will return the requested record extracts for the remote device to
57 interpret.
58 The remote device will then make a separate connection in order to
59 access the service.
60 .Pp
61 Bluetooth applications, running on the host, are able to insert, remove
62 and update Service Records with the
63 .Nm
64 daemon via the control socket.
65 It is possible to query entire contents of the Service Database locally with
66 .Xr sdpquery 1
67 using the
68 .Fl l
69 option.
70 .Pp
71 The command line options are as follows:
72 .Bl -tag -width indent
73 .It Fl c Ar path
74 Specify path to the control socket.
75 The default path is
76 .Pa /var/run/sdp .
77 .It Fl d
78 Do not detach from the controlling terminal.
79 .It Fl G Ar group
80 Grant permission to members of the
81 .Ar group
82 to modify the
83 .Nm
84 Service Database.
85 .It Fl g Ar group
86 Specifies the group the
87 .Nm
88 should run as after it initializes.
89 The value specified may be either a group name or a numeric group ID.
90 This only works if
91 .Nm
92 was started as root.
93 The default group name is
94 .Dq Li _sdpd .
95 .It Fl h
96 Display usage message and exit.
97 .It Fl u Ar user
98 Specifies the user the
99 .Nm
100 should run as after it initializes.
101 The value specified may be either a user name or a numeric user ID.
102 This only works if
104 was started as root.
105 The default user name is
106 .Dq Li _sdpd .
108 .Sh FILES
109 .Bl -tag -width ".Pa /var/run/sdp" -compact
110 .It Pa /var/run/sdp
112 .Sh SEE ALSO
113 .Xr sdpquery 1 ,
114 .Xr sdp 3
117 .Qq Service Discovery Protocol
118 section of the Bluetooth Core specifications, available at
119 .Qq http://www.bluetooth.com/
120 .Sh HISTORY
121 The original
123 daemon first appeared in
124 .Fx 5.3
125 and was imported into
126 .Nx 4.0
128 .An Iain Hibbert
129 under the sponsorship of
130 .An Itronix, Inc.
131 This version was rewritten by
132 .An Iain Hibbert
134 .Nx 6.0
135 in order to allow Bluetooth applications to fully specify
136 service records.
137 .Sh AUTHORS
138 .An Maksim Yevmenkin Aq m_evmenkin@yahoo.com
139 .An Iain Hibbert
140 .Sh CAVEATS
143 daemon
144 will listen for incoming L2CAP connections on a wildcard BD_ADDR.
146 In case of multiple Bluetooth controllers connected to the same host
147 it is possible to limit visibility of Service Records according to
148 the controller the connection is made through.
150 Requests to insert, remove or update service records can only be made
151 via the control socket.
154 daemon will check the peer's credentials and will only accept the request
155 when the peer is the superuser, of if the peer is a member of the group
156 specified with the
157 .Fl G
158 option.
162 daemon does not check for duplicated Service Records and only
163 performs minimal validation of the record data sent in the Insert/Update
164 Record requests.
165 It is assumed that application must obtain all required resources such
166 as RFCOMM channels etc., before registering the service.
167 .Sh BUGS
169 only ever generates 16-bit sequence headers, so if a response was
170 to grow over
171 .Dv UINT16_MAX ,
172 the sequence header will be wrong.
174 There is no way for clients to discover the maximum packet size that
176 will accept on the local socket.
177 Currently this is
178 .Dv SDP_LOCAL_MTU
179 as defined in
180 .In bluetooth/sdp.h .