summaryrefslogtreecommitdiff
path: root/src/agent.c
Commit message (Collapse)AuthorAgeFilesLines
* core: Rename hcid.h to btd.hLuiz Augusto von Dentz2020-10-291-1/+1
| | | | | Since we use btd term for daemon APIs it makes sense to use it also for the header name instead of hcid.
* src: Add SPDX License IdentifierTedd Ho-Jeong An2020-09-211-14/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds SPDX License Identifier and removes the license text. ------------------------------------- License COUNT ------------------------------------- LGPL-2.1-or-later : 62 GPL-2.0-or-later : 51 BSD-2-Clause : 2 License: LGPL-2.1-or-later src/adv_monitor.c src/adv_monitor.h src/shared/mainloop-glib.c src/shared/btp.c src/shared/tester.c src/shared/btsnoop.c src/shared/gatt-helpers.h src/shared/log.h src/shared/util.h src/shared/mainloop-ell.c src/shared/hci-crypto.c src/shared/mainloop.c src/shared/hfp.h src/shared/mainloop-notify.c src/shared/io-mainloop.c src/shared/btsnoop.h src/shared/uhid.h src/shared/util.c src/shared/ringbuf.c src/shared/btp.h src/shared/shell.h src/shared/io-glib.c src/shared/queue.h src/shared/gatt-server.h src/shared/crypto.c src/shared/crypto.h src/shared/io-ell.c src/shared/timeout-glib.c src/shared/mgmt.c src/shared/gatt-db.c src/shared/mainloop-notify.h src/shared/hfp.c src/shared/timeout-ell.c src/shared/shell.c src/shared/hci.c src/shared/log.c src/shared/ringbuf.h src/shared/gatt-helpers.c src/shared/queue.c src/shared/tty.h src/shared/timeout-mainloop.c src/shared/tester.h src/shared/gap.h src/shared/mgmt.h src/shared/gatt-db.h src/shared/uhid.c src/shared/mainloop.h src/shared/timeout.h src/shared/att-types.h src/shared/pcap.c src/shared/gap.c src/shared/att.c src/shared/pcap.h src/shared/hci.h src/shared/gatt-client.h src/shared/io.h src/shared/gatt-client.c src/shared/ad.c src/shared/att.h src/shared/gatt-server.c src/shared/hci-crypto.h src/shared/ad.h License: GPL-2.0-or-later src/attrib-server.h src/advertising.h src/textfile.c src/attrib-server.c src/uinput.h src/log.h src/eir.h src/sdpd.h src/sdpd-request.c src/service.h src/sdpd-database.c src/adapter.h src/plugin.h src/uuid-helper.h src/plugin.c src/main.c src/sdp-xml.c src/error.h src/oui.c src/device.c src/agent.h src/sdp-client.c src/oui.h src/device.h src/gatt-database.c src/error.c src/backtrace.c src/sdpd-server.c src/adapter.c src/log.c src/agent.c src/backtrace.h src/sdp-xml.h src/hcid.h src/dbus-common.h src/uuid-helper.c src/storage.c src/profile.c src/advertising.c src/storage.h src/dbus-common.c src/profile.h src/sdpd-service.c src/eir.c src/sdp-client.h src/gatt-database.h src/gatt-client.h src/rfkill.c src/gatt-client.c src/service.c src/textfile.h License: BSD-2-Clause src/shared/ecc.h src/shared/ecc.c
* agent: Detect when ongoing request is already in progressLuiz Augusto von Dentz2019-12-271-45/+83
| | | | | | This detects when a agent request is already pending for the same device which could happen when there are 2 or more adapters in the system and they are trying to pair with each other.
* agent: Make the first agent to register the defaultLuiz Augusto von Dentz2018-07-301-8/+6
| | | | | | This simplifies the handling of default agent and enforce the IO capabilities to be set whenever there is an agent available in the system.
* agent: Change default IO capability to KeyboardDisplayJohan Hedberg2015-11-251-1/+1
| | | | | | | | The intention of the DisplayYesNo default capability was originally to provide the richest possible option available. However with LE there is a new even more capable option, namely KeyboardDisplay. When applied to BR/EDR connections this gets implicitly downgraded to DisplayYesNo since KeyboardDisplay is LE-specific.
* core: Use local libbluetooth includesMarcel Holtmann2015-02-281-4/+5
|
* core: List all enum values in switchSzymon Janc2014-12-081-0/+4
| | | | As described in coding style M10
* Revert "core: Fix unnecessary calls to agent_cancel()"Luiz Augusto von Dentz2014-10-301-0/+1
| | | | | agent_cancel calls are necessary since agent_unref only call it in case the last reference is dropped.
* core: Remove always_pairable featureJohan Hedberg2014-07-301-7/+0
| | | | | | We've decided to have pairable (soon to be renamed to bondable) always set after all, so neither the always_pairable variable nor the AlwaysPairable config option is needed.
* core: Move always_pairable check into adapter_set_pairable()Johan Hedberg2014-07-181-2/+1
|
* core: Add convenience API to check for available default agentJohan Hedberg2014-07-181-0/+5
|
* core: Make pairable mode dependent on the existence of a default agentJohan Hedberg2014-07-181-0/+4
| | | | | | | | This patch updates the adapter code to only enable pairable mode when there is a default agent available. A new main.conf option called AlwaysPairable is also introduced to allow keeping the old behavior, however the default is the new behavior (i.e. this option defaults to FALSE).
* agent: Allow to stack default agentsSzymon Janc2014-04-291-11/+36
| | | | | | | | | There is no API for notifying agent that it is no longer default one. This can lead to situation when ie. console agent (bluetoothctl) is set as default leaving UI agent unfunctional after bluetoothctl exited. This patch adds stacking of default agents in case more then one agent requested being default.
* core: Fix unnecessary calls to agent_cancel()Johan Hedberg2014-03-191-1/+0
| | | | | The agent_unref() function already takes care of agent_cancel() so there's no need to call both functions in sequence.
* agent: Remove not used enum valueSzymon Janc2014-01-181-1/+0
| | | | Only user of AGENT_REQUEST_CONFIRM_MODE is already removed.
* core: Fix crash due to agent callback freeing the agentSzymon Janc2013-12-101-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | Similar fix was provided for simple_agent_reply in a2f5d438 but missed pincode_reply case. Fix following: src/agent.c:agent_disconnect() Agent :1.48 disconnected src/agent.c:set_default_agent() Default agent cleared src/agent.c:agent_destroy() agent :1.48 src/agent.c:agent_unref() 0x4701c68: ref=1 Agent /org/bluez/agent replied with an error: org.freedesktop.DBus.Error.NoReply, Message did not receive a reply (timeout by message bus) src/adapter.c:btd_adapter_pincode_reply() hci0 addr 6C:0E:0D:DB:D1:16 pinlen 0 src/agent.c:agent_unref() 0x4701c68: ref=0 src/adapter.c:btd_adapter_pincode_reply() hci0 addr 6C:0E:0D:DB:D1:16 pinlen 0 src/agent.c:agent_unref() 0x4701c68: ref=-1 src/adapter.c:btd_adapter_pincode_reply() hci0 addr 6C:0E:0D:DB:D1:16 pinlen 0 src/agent.c:agent_unref() 0x4701c68: ref=-2 ...
* core: Fix protecting from agent callback freeing the agentJohan Hedberg2013-11-271-0/+5
|
* core: Make use of g_dbus_send_message_with_replyLuiz Augusto von Dentz2013-09-091-6/+6
| | | | | This replaces dbus_connection_send_with_reply with g_dbus_send_message_with_reply which does not alter message order.
* core: Add logging of default agent changesJohan Hedberg2013-06-071-0/+5
|
* core: Remove the total silly usage of gchar and replace it with just charMarcel Holtmann2013-01-041-6/+6
|
* core: Prefer adapter_foreach over manager functionJohan Hedberg2013-01-031-2/+1
|
* core: Use ERROR_INTERFACE instead of org.bluez.ErrorAnderson Lizardo2012-12-221-2/+3
|
* core: Improve error logging for agent repliesJohan Hedberg2012-12-191-2/+2
|
* core: Check for valid agent capabilityMarcel Holtmann2012-12-181-0/+2
|
* core: Update agent manager implementation to match API docJohan Hedberg2012-12-181-2/+10
|
* core: Remove implicit setting of the default agentJohan Hedberg2012-12-171-25/+10
|
* core: Clear default agent in agent_disconnect()Johan Hedberg2012-12-171-0/+3
|
* core: Set implicit default agent when first agent registersJohan Hedberg2012-12-171-0/+3
|
* core: Fix looking up "any" agent from the hash tableJohan Hedberg2012-12-171-8/+18
|
* core: Remove unused agent_matches functionJohan Hedberg2012-12-171-8/+0
|
* core: Remove unused agent_is_busy functionJohan Hedberg2012-12-171-11/+0
|
* core: Update adapter IO capability based on default agentJohan Hedberg2012-12-171-4/+26
|
* core: Make agent_create private to agent.cJohan Hedberg2012-12-171-13/+3
|
* core: Implement AgentManager1.RequestDefaultJohan Hedberg2012-12-171-5/+31
|
* core: Add agent_get functionJohan Hedberg2012-12-171-0/+14
|
* core: Use existing agent struct for new AgentManager1 interfaceJohan Hedberg2012-12-171-88/+64
|
* core: Add reference counting for agent objectsJohan Hedberg2012-12-171-4/+18
|
* core: Add agent registration handling of agent managerMarcel Holtmann2012-12-151-1/+111
|
* core: Add empty stubs for agent managerMarcel Holtmann2012-12-141-0/+34
|
* core: Append version to Agent interfaceLuiz Augusto von Dentz2012-12-141-9/+10
|
* core: Remove ConfirmModeChange methodLuiz Augusto von Dentz2012-12-131-55/+0
| | | | This method was only used by RequestSession which is now removed.
* Revert "Ensure config.h is included by using CPPFLAGS"Johan Hedberg2012-12-071-0/+4
| | | | | | | | | | | | | | This reverts commit 8a03376544b046a84301847d1594f6c3674983ff. The patch needs to be split up and the gdbus/ changes were bogus compared to the original commit message. Conflicts: Makefile.am Makefile.obexd profiles/cyclingspeed/cyclingspeed.c profiles/heartrate/heartrate.c src/error.c
* Use the entire include path for gdbus.hLucas De Marchi2012-12-051-1/+1
|
* Ensure config.h is included by using CPPFLAGSLucas De Marchi2012-12-051-4/+0
| | | | | | | | | | Instead of trying to include config.h in each file over the tree and possibly forgetting to include it, give a "-include config.h" argument to the compiler so it's guaranteed that a) it will be included for all source files and b) it will be the first header included. gdbus/ directory is left out, since it would break other projects using it.
* core: Add SSP just-works acceptor mapping to Agent.RequestAuthorizationJohan Hedberg2012-12-041-0/+58
|
* agent: Rename Authorize to AuthorizeServiceJohan Hedberg2012-12-041-14/+11
|
* agent: Remote not used variables from pincode_replySzymon Janc2012-10-021-4/+0
| | | | adapter and sba are not used later in function code.
* agent: Simplify DBusConnection object handlingAndrzej Kaczmarek2012-09-211-27/+17
| | | | | | | | This patch removes local reference to DBusConnection object and uses btd_get_dbus_connection() call wherever such object is needed instead. Pointer returned by this call is guaranteed to be valid for entire bluetoothd lifetime and thus do not need to be refcounted.
* agent: Add missing parameter to DisplayPasskeyJohan Hedberg2012-09-041-1/+2
|
* Add profile abstraction (replaces btd_device drivers)Johan Hedberg2012-09-031-0/+1
| | | | | | | | | | | | | | | | | | This patch removes the btd_device_driver concept and replaces it with btd_profile. The new construct also contains the necessary parts for adapter drivers, so btd_adapter_driver is only needed for non-profile related functionality (most of which is in plugins/*). The main purpose of this new construct is to facilitate a centralized connection creation mechanism for profiles, ultimately enabling the addition of a Device.Connect() method instead of requiring a UI to know to call e.g. Input.Connect or Audio.Connect. This feature will also be extended to externally implemented profiles once the internal implementation gets more stable, such as OBEX (obexd) and HFP (oFono). The new D-Bus interface will also partially restore functionality which was previously available through the Serial interface.