Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#46687 - [bluez] fails to invoke NewConnection on registered profiles.
Attached to Project:
Arch Linux
Opened by john doe (jatone) - Monday, 12 October 2015, 22:37 GMT
Last edited by Andreas Radke (AndyRTR) - Monday, 04 January 2016, 18:09 GMT
Opened by john doe (jatone) - Monday, 12 October 2015, 22:37 GMT
Last edited by Andreas Radke (AndyRTR) - Monday, 04 January 2016, 18:09 GMT
|
Detailsthe bluetooth seems to be unable to invoke NewConnection on registered profiles.
however when bluetooth is shutdown it does correctly invoke the Release method on the registered profile. jhe in #bluez irc seems to think it was related to the fact bluez tries to pass the socket to the profile via the NewConnection method and something like selinux is preventing it. Steps to reproduce: python test-profile.py --name="test-profile" --path="/hello/world" --uuid={some profile id} -s --channel=11 connect to the profile using an application. it will fail to connect, and there will be no real reason why. but when you restart bluetooth: sudo systemctl restart bluetooth it'll correctly invoke the Release callback and such down the test/test-profile.py program. python test-profile.py --name="test-profile" --path="/hello/world" --uuid=00005007-0000-1000-8000-0002ee000001 -a -s --channel=11 logs from bluetooth: Oct 12 18:36:57 jambli bluetoothd[2774]: src/profile.c:ext_exited() "test-profile" exited Oct 12 18:36:57 jambli bluetoothd[2774]: src/profile.c:ext_adapter_remove() "test-profile" removed Oct 12 18:36:57 jambli bluetoothd[2774]: src/adapter.c:adapter_service_remove() /org/bluez/hci0 Oct 12 18:36:57 jambli bluetoothd[2774]: src/adapter.c:remove_uuid() sending remove uuid command for index 0 Oct 12 18:36:57 jambli bluetoothd[2774]: src/sdpd-service.c:remove_record_from_server() Removing record with handle 0x1000f Oct 12 18:36:57 jambli bluetoothd[2774]: src/profile.c:remove_ext() Removed "test-profile" Oct 12 18:36:58 jambli bluetoothd[2774]: src/profile.c:register_profile() sender :1.200 Oct 12 18:36:58 jambli bluetoothd[2774]: src/profile.c:create_ext() Created "test-profile" Oct 12 18:36:58 jambli bluetoothd[2774]: src/profile.c:ext_adapter_probe() "test-profile" probed Oct 12 18:36:58 jambli bluetoothd[2774]: src/profile.c:ext_start_servers() test-profile listening on chan 11 Oct 12 18:36:58 jambli bluetoothd[2774]: src/adapter.c:adapter_service_add() /org/bluez/hci0 Oct 12 18:36:58 jambli bluetoothd[2774]: src/sdpd-service.c:add_record_to_server() Adding record with handle 0x1000f Oct 12 18:36:58 jambli bluetoothd[2774]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00000003-0000-1000-8000-00805f9 Oct 12 18:36:58 jambli bluetoothd[2774]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00000100-0000-1000-8000-00805f9 Oct 12 18:36:58 jambli bluetoothd[2774]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00001002-0000-1000-8000-00805f9 Oct 12 18:36:58 jambli bluetoothd[2774]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00005007-0000-1000-8000-0002ee0 Oct 12 18:36:58 jambli bluetoothd[2774]: src/adapter.c:adapter_service_insert() /org/bluez/hci0 Oct 12 18:36:58 jambli bluetoothd[2774]: src/adapter.c:add_uuid() sending add uuid command for index 0 Oct 12 18:36:59 jambli bluetoothd[2774]: src/adapter.c:discovering_callback() hci0 type 7 discovering 0 method 0 Oct 12 18:36:59 jambli bluetoothd[2774]: src/adapter.c:trigger_start_discovery() Oct 12 18:36:59 jambli bluetoothd[2774]: src/adapter.c:cancel_passive_scanning() Oct 12 18:37:02 jambli bluetoothd[2774]: src/adapter.c:connected_callback() hci0 device BC:F5:AC:7D:48:73 connected eir_len 5 Oct 12 18:37:03 jambli bluetoothd[2774]: src/profile.c:ext_connect() test-profile connected to BC:F5:AC:7D:48:73 Oct 12 18:37:04 jambli bluetoothd[2774]: src/adapter.c:start_discovery_timeout() Oct 12 18:37:04 jambli bluetoothd[2774]: src/adapter.c:start_discovery_timeout() adapter->current_discovery_filter == 0 Oct 12 18:37:04 jambli bluetoothd[2774]: src/adapter.c:start_discovery_complete() status 0x00 Oct 12 18:37:04 jambli bluetoothd[2774]: src/adapter.c:discovering_callback() hci0 type 7 discovering 1 method 0 Oct 12 18:37:07 jambli bluetoothd[2774]: src/adapter.c:dev_disconnected() Device BC:F5:AC:7D:48:73 disconnected, reason 2 Oct 12 18:37:07 jambli bluetoothd[2774]: src/adapter.c:adapter_remove_connection() Oct 12 18:37:07 jambli bluetoothd[2774]: plugins/policy.c:disconnect_cb() reason 2 Oct 12 18:37:07 jambli bluetoothd[2774]: src/adapter.c:bonding_attempt_complete() hci0 bdaddr BC:F5:AC:7D:48:73 type 0 status 0xe Oct 12 18:37:07 jambli bluetoothd[2774]: src/device.c:device_bonding_complete() bonding (nil) status 0x0e Oct 12 18:37:07 jambli bluetoothd[2774]: src/device.c:device_bonding_failed() status 14 Oct 12 18:37:07 jambli bluetoothd[2774]: src/adapter.c:resume_discovery() Oct 12 18:37:07 jambli bluetoothd[2774]: src/adapter.c:trigger_start_discovery() Oct 12 18:37:07 jambli bluetoothd[2774]: src/adapter.c:cancel_passive_scanning() |
This task depends upon
Closed by Andreas Radke (AndyRTR)
Monday, 04 January 2016, 18:09 GMT
Reason for closing: No response
Monday, 04 January 2016, 18:09 GMT
Reason for closing: No response
I'm aware Arch doesn't use selinux by default. and my system doesn't have selinux.
selinux only mentioned because bluez devs have seen similar issue caused by selinux.
Something is causing it to not invoke the method on the dbus interface.
so basically we have it silently failing to invoke a dbus method, but the Release method on the same dbus object gets invoked correctly.
src/profile.c:create_conn:
/* Do not add UUID if client role is not enabled */
if (!server->ext->enable_client) {
service = NULL;
goto done;
}
...
if (service)
conn->service = btd_service_ref(service);
src/profile.c:ext_connect:
if (conn->service && service_accept(conn->service) == 0) {
if (send_new_connection(ext, conn))
return;
}