[New-bugs-announce] [issue41130] Improve/fix FreeBSD Bluetooth socket support

myfreeweb report at bugs.python.org
Fri Jun 26 15:00:41 EDT 2020


New submission from myfreeweb <python at unrelenting.technology>:

1) BTPROTO_HCI addresses only expect string identifiers on NetBSD and DragonFly: https://github.com/python/cpython/blob/2e0a920e9eb540654c0bb2298143b00637dc5961/Modules/socketmodule.c#L1931

But of course this is true on FreeBSD too. (DragonFly inherited the BT stack from FreeBSD!)
For example this is how hccontrol creates an address:
https://github.com/freebsd/freebsd/blob/6bb9221a9b865ee432269099f341e4230a6cbcd4/usr.sbin/bluetooth/hccontrol/hccontrol.c#L115-L129

So currently it is not possible to bind an HCI socket (without using FFI to directly use the libc bind function) :(

2) BTPROTO_SCO is excluded on FreeBSD: https://github.com/python/cpython/blob/2e0a920e9eb540654c0bb2298143b00637dc5961/Modules/socketmodule.c#L1953

But SCO has been supported since 2008: https://github.com/freebsd/freebsd/commit/bb4c6de0cf336d006e41521cbbd4706f60a0dfe0

----------
components: FreeBSD
messages: 372439
nosy: koobs, myfreeweb
priority: normal
severity: normal
status: open
title: Improve/fix FreeBSD Bluetooth socket support
type: enhancement
versions: Python 3.10, Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41130>
_______________________________________


More information about the New-bugs-announce mailing list