aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Align dbt_peripheral00, DBTPeripheral00 to Trial's DBTServer00Sven Gothel2022-04-153-66/+94
|
* TestDBTClientServer*: Cleanup stop()/close() of server and ensure server ↵Sven Gothel2022-04-154-52/+90
| | | | gets close() at test end
* Bump jaulib aeca78fe379e0f5c2b80d333958c0c4fb52e409fSven Gothel2022-04-151-0/+0
|
* BTGattHandler::l2capReaderEndLocked(): Disable off-thread ↵Sven Gothel2022-04-151-0/+3
| | | | BTDevice::disconnect() on io-error, BT host is sending out disconnect - simplify tear down
* TestDBTClientServer*: Replace fixed timeout with polling, speeding up server ↵Sven Gothel2022-04-154-19/+33
| | | | data pulse etc ..
* Bump jaulib's service_runner change, adapt and fix BTGattHandler's ↵Sven Gothel2022-04-155-23/+31
| | | | | | | | | | | | | | | | l2capReader data race (use after free) BTGattHandler::disconnect(): - If disconnected, ensure to wait until l2cap_reader_service has ended via join(), otherwise BTDevice could dtor the BTGattHandler! - Call BTDevice::disconnect() as the last command, since it leads to dtor of this BTGattHandler! - removed l2capReaderEndFinal() post lock due to data leak (removed from service_runner API as well) - Have l2capReaderEndLocked() call BTDevice::disconnect() off-thread in case of io-error only, this is a safe compromise w/o missing a disconnect.
* WIP: BTAdapter::startDiscovery(): Retry up to MAX_BACKGROUND_DISCOVERY_RETRY ↵Sven Gothel2022-04-143-28/+69
| | | | (3), mitigating failure to start discovery
* BTAdapter::startDiscovery(): Issue removeDiscoveredDevices() before branch ↵Sven Gothel2022-04-141-2/+2
| | | | once for clarity (always)
* BTAdapter: Shorten DBG_PRINT "BTAdapter::{EventHCI->hci}:"Sven Gothel2022-04-141-20/+19
|
* BTDevice::notifyLEFeature(): Remove HCIStatusCode param and only call with ↵Sven Gothel2022-04-143-16/+12
| | | | | | SUCCESS status code In case of a connection failure, status code is !SUCCESS and we shall not enter into pairing mode!
* Fix and document default connection paramter, leaning to higher performance ↵Sven Gothel2022-04-1411-31/+77
| | | | side - add documentation file
* Trial Tests: Extract the non-encryption tests to its own Test* unit fileSven Gothel2022-04-146-32/+116
|
* Fixes slave/server legacy LTK issue: Resolve ↵Sven Gothel2022-04-144-69/+58
| | | | | | | | | | MgmtLongTermKeyInfo::{initiator->role} field's actual role, depending on the adapter's role BlueZ interprets `role` as follows: - Adapter role slave/responder (GATT server) - 1 = master/initiator (GATT client); 0 = slave/responder (GATT server) - Adapter role master/initiator (GATT client) - 0 = master/initiator (GATT client); 1 = slave/responder (GATT server)
* Updated Eclipse lang settingSven Gothel2022-04-111-3/+3
|
* README.md: Bump for v2.6.3v2.6.3Sven Gothel2022-04-112-1/+22
|
* Use project name 'Direct-BT' instead of 'DirectBT' for version info .. it is ↵Sven Gothel2022-04-1110-19/+19
| | | | the brand Luke :)
* Examples: Only attempt using LE_PHYs::LE_2M if BT.major > 4, to keep the ↵Sven Gothel2022-04-115-9/+9
| | | | logs clean and for documentation (not required though)
* Align C++ -> Java BTGattChar::get[ClientCharConfig,UserDescription]() and ↵Sven Gothel2022-04-114-48/+82
| | | | | | add API doc Reorder the java code a little to better match C++
* Cleanup Gatt numbers: Merge GattTypes.hpp into GattNumbers.hpp, remove ↵Sven Gothel2022-04-1110-106/+30
| | | | redundant and unrelated BTGattDesc::Type
* BTAdapter: Add 'simple_timer smp_watchdog' triggering FAILED, key removal ↵Sven Gothel2022-04-116-2/+68
| | | | and disconnect if no pairing progress within 2s while in KEY_DISTRIBUTION
* BTAdapter::sendDevicePairingState(): If FAILED pairing -> disconnect w/ ↵Sven Gothel2022-04-111-0/+5
| | | | | | reason AUTHENTICATION_FAILURE If occuring on client side, our server (if in use) will also remove the SMPKeyBin file
* BTAdapter::mgmtEvDeviceDisconnectedHCI(): As slave/master: If reason was ↵Sven Gothel2022-04-111-17/+24
| | | | failed pairing on client side -> removeSMPKeyBin()
* BTAdapter::mgmtEvDeviceConnectedHCI(): As slave/server: Only ↵Sven Gothel2022-04-111-3/+8
| | | | device->setConnSecurity() if no pre-paired key is in use
* BTAdapter::startAdvertising: Reset to SMPIOCapability::NO_INPUT_NO_OUTPUTSven Gothel2022-04-111-0/+6
|
* BTDevice::processL2CAPSetup: Show dev_id in DBG_PRINTSven Gothel2022-04-111-8/+8
|
* SMPPairingState: Complete util functionsSven Gothel2022-04-111-1/+11
|
* TestDBTClientServer11_SC0: Enable test01 EncNoneSven Gothel2022-04-111-1/+1
|
* BTDevice::PairingData::toString() and BTDevice::setConnSecurity(): Show ↵Sven Gothel2022-04-112-13/+13
| | | | adapter.dev_id
* TestDBTClientServer*: Expand to SC 0 (legacy) and SC 1 (secure connections) ↵Sven Gothel2022-04-117-57/+203
| | | | SMP tests
* BTDevice::processL2CAPSetup: Only set local server open l2cap_att's ↵Sven Gothel2022-04-101-1/+5
| | | | BTSecurityLevel is > UNSET (aka set)
* BTDevice: Use HCIStatusCode::AUTHENTICATION_FAILURE reason for disconnect if ↵Sven Gothel2022-04-101-3/+3
| | | | SMP failed.
* Bump jaulib f3706ea975f4b3dc3a6e64200e62774d23915ee1Sven Gothel2022-04-101-0/+0
|
* Bump jaulib a41475e3bfc1e04883411d68a6a28729a1e6dff8Sven Gothel2022-04-101-0/+0
|
* L2CAPComm.hpp: L2CAP{ClientServer->Comm}, add adapter device id for clarity ↵Sven Gothel2022-04-107-143/+138
| | | | of adapter association
* Add SMPCrypto.cpp: SMP F5 algo according to BT Core Spec for documentation, ↵Sven Gothel2022-04-101-0/+165
| | | | currently disabled due to no access to dhkey.
* SMPTypes.hpp: Encryption Types: Add note to little-endian byte order used ↵Sven Gothel2022-04-101-13/+13
| | | | for encryption data
* Bump jaulib a0dfa3f94f6bf84bca9d6b482eaf3ae295c22a45Sven Gothel2022-04-101-0/+0
|
* L2CAPComm: Rename L2CAP{Comm->Client} and have L2CAP{Client,Server} derive ↵Sven Gothel2022-04-1010-276/+289
| | | | | | from new common L2CAPClientServer This is a preparation to utilize common setBTSecurityLevelImpl(..) for L2CAPServer w/o code duplication.
* SMPHandler.hpp: #define -> 'inline constexpr' to allow proper compile time ↵Sven Gothel2022-04-1010-474/+456
| | | | analysis; Also 'static constexpr const -> inline constexpr const' for global constants
* BTDevice::clearData() to be performed after notifying listener and if ↵Sven Gothel2022-04-092-2/+5
| | | | !isConnSecurityAutoEnabled()
* Refine DBT live test trial: Give client a name as well; Test both adapter in ↵Sven Gothel2022-04-0910-219/+381
| | | | | | | both client/server directions There are still stability issues w/ BT5 and server mode using encryption: - encryption hangs due to missing Mgmt key info event
* BTDevice: Update btRole = !adapter.getRole() when clearData() @ disconnected ↵Sven Gothel2022-04-091-0/+3
| | | | | | and update() @ found or connected This ensures proper role even if device has not been removed and roles have changed.
* BTDevice::clearData() when disconnected, avoiding using old scanned ↵Sven Gothel2022-04-092-4/+28
| | | | artifacts (name, ..) misleading state of device
* Re-add FIXME? in BTAdapter::startAdvertising(), whether a 'little wait' is ↵Sven Gothel2022-04-091-1/+1
| | | | required for restarting advertising
* BTGattCmd: Fix DEBUG mode: Check rsp_data @ string conversion and use ↵Sven Gothel2022-04-091-2/+6
| | | | BTUtils.bytesHexString(..) for string conversion
* DBTGattChar.findGattDesc() (java): Fix wrong comparison (inverse, typo)Sven Gothel2022-04-091-1/+1
|
* No need for BTAdapter::removeDiscoveredDevices() for server nor client ↵Sven Gothel2022-04-096-19/+3
| | | | before startDiscovert(), implicit on the latter
* MgmtDefaultParam: Fox for g++ 8.3; MgmtReadDefaultSysParamCmd::getParams() ↵Sven Gothel2022-04-082-5/+5
| | | | shall move MgmtDefaultParam into list
* Server Test: Align connection interval min to system default, max to 30ms: ↵Sven Gothel2022-04-083-3/+3
| | | | (8, 24) -> 10ms - 30ms
* DBG_PRINT: Show BTManager::readDefaultSysParam() @ pre/post ↵Sven Gothel2022-04-082-1/+21
| | | | BTManager::initializeAdapter() and BTAdapter::startAdvertising()