Commit Graph

17 Commits

Author SHA1 Message Date
christos
a80110f6b6 need <sys/stat.h> 2017-01-10 21:08:48 +00:00
wiz
d860f590d4 Fix typo ("then" instead of "than") 2013-12-09 09:35:16 +00:00
christos
d97d3aebdc - use poll() instead of select()
- make everything static
- knf
- consistently check for == -1 for syscall errors
- isatty(fd) == tcgetattr(fd), don't do it twice
- make error messages more consistent
- use sig_atomic_t for variable set inside signal handler
2011-07-18 21:51:06 +00:00
plunky
412b8db41e only modify the termios structure when tty_in is verifiably a terminal 2011-07-18 15:44:17 +00:00
plunky
a4d969557b In server mode, relax the requirement to specify a channel number. If
one is not given, attempt to allocate the first unused one.
2010-11-03 08:27:27 +00:00
plunky
48b6f8e46b Add a new feature, allow to specify an alternative PSM value for the
RFCOMM protocol to use in client or server mode. Also, handle the case
where service search of the remote device returns non-standard PSM.
2009-09-24 18:30:37 +00:00
plunky
9b85369a0a use system provided MAX(a, b) macro instead of defining our own 2009-05-21 14:44:01 +00:00
plunky
a092292999 update rfcomm_sppd to use the new Service Discovery API 2009-05-12 18:43:35 +00:00
lukem
98e5374ccb Remove the \n and tabs from the __COPYRIGHT() strings.
Tweak to use a consistent format.
2008-07-21 14:19:20 +00:00
dsl
858e924206 Fix 64bit build, strlen() doesn't return int. 2007-04-21 10:39:30 +00:00
plunky
f5db72e7b7 Add 'service level' security for L2CAP and RFCOMM connections, following
the Linux (BlueZ) API.

    - L2CAP or RFCOMM connections can require the baseband radio link
    mode be any of:
	authenticated (devices are paired)
	encrypted (implies authentication)
	secured (encryption, plus generate new link key)

    - for sockets, the mode is set using setsockopt(2) and the socket
    connection will be aborted if the mode change fails.

    - mode settings will be applied during connection establishment, and
    for safety, we enter a wait state and will only proceed when the mode
    settings are successfuly set.

    - It is possible to change the mode on already open connections, but
    not possible to guarantee that data already queued (from either end)
    will not be delivered. (this is a feature, not a bug)

    - bthidev(4) and rfcomm_sppd(1) support "auth", "encrypt" and
    "secure" options

    - btdevctl(8) by default enables "auth" for HIDs, and "encrypt" for
    keyboards (which are required to support it)
2007-04-21 06:15:22 +00:00
plunky
89f52265ce fix warnings produced by -Wextra
fix warnings produced by lack of const
2007-03-31 07:14:44 +00:00
plunky
ca0b33b2ff cut and paste error meant you could only use "-s <num>" as the last
option on the commandline..
2007-03-08 19:13:14 +00:00
plunky
e55e3c248c only turn off input processing if it is on 2007-03-08 19:10:49 +00:00
plunky
d7e75bcc12 rework the -c and -s options to make them a bit more consistent.
when EOF is reached, we are done.
2007-03-01 21:44:30 +00:00
plunky
defc1075ef This comprises a rewrite, which
- adds a server mode for incoming bluetooth connections
	- does not cfmakeraw the slave tty as this caused problems
	- does not hold open the slave tty as this prevented multiple opens
	- modifies the termios for stdio so that this can be used directly
	  by a user.
2007-01-31 08:12:21 +00:00
gdamore
a5c89047c0 Initial import of bluetooth stack on behalf of Iain Hibbert. (plunky@,
NetBSD Foundation Membership still pending.)  This stack was written by
Iain under sponsorship from Itronix Inc.

The stack includes support for rfcomm networking (networking via your
bluetooth enabled cell phone), hid devices (keyboards/mice), and headsets.

Drivers for both PCMCIA and USB bluetooth controllers are included.
2006-06-19 15:44:33 +00:00