Commit Graph

22877 Commits

Author SHA1 Message Date
Andrei Emeltchenko
e3177885c9 tester: Verify DHKey generation
Verify that HCI controller correctly generate Diffie-Hellman key.
2015-05-22 14:47:46 +03:00
Andrei Emeltchenko
2dd971c0a9 tester: Refactor Read Local Public Key command
Save Local Public Key to calculate DHKey for later tests. Also verify
that Command Status and Meta Event are generated.
2015-05-22 14:47:44 +03:00
Johan Hedberg
665143e1cd emulator: Fix passing correct EDiv & Rand values 2015-05-22 14:42:20 +03:00
Gowtham Anandha Babu
f5fcdf45a6 unit/test-uuid: Use tester framework 2015-05-22 13:52:48 +03:00
Gowtham Anandha Babu
068dcecd44 unit/test-lib: Use tester framework 2015-05-22 13:52:47 +03:00
Gowtham Anandha Babu
3fb9cbb522 unit/test-queue: Use tester framework 2015-05-22 13:52:47 +03:00
Gowtham Anandha Babu
bce027cedb unit/test-textfile: Use tester framework 2015-05-22 13:52:47 +03:00
Gowtham Anandha Babu
f23f056a5d unit/test-ringbuf: Use tester framework 2015-05-22 13:52:47 +03:00
Luiz Augusto von Dentz
cdd6175605 tests/example-advertisement: Change type to peripheral
With broadcast type it won't be connectable which is much more convenient
when testing.
2015-05-22 13:13:57 +03:00
Luiz Augusto von Dentz
4a9baabf0e shared/ad: Fix service data matching
bt_uuid_cmp return 0 if it matches not a true.
2015-05-22 13:12:50 +03:00
Luiz Augusto von Dentz
f61999e563 shared/ad: Do not lookup service data twice
This remove call to bt_ad_has_service_data inside bt_ad_add_service_data
since it already does the lookup for existing data before.
2015-05-21 12:50:29 +03:00
Marie Janssen
521e00006a Fix name in AUTHORS
Update Marie's name to be correct and add it to .mailmap.
2015-05-20 23:16:30 +03:00
Luiz Augusto von Dentz
72ffc5a101 shared/ad: Replace data if already exists
If either manufacturer or service data already exist but the content
is different replace with the new data.
2015-05-20 23:10:17 +03:00
Luiz Augusto von Dentz
206bdc3cab shared/ad: Fix data matching
The user_data was never used so adding new data will always fail if one
already exists.
2015-05-20 23:09:58 +03:00
Szymon Janc
4453f67fcf emulator: Handle Host Number Of Completed Packets Command
The Host_Number_Of_Completed_Packets command is a special command in
the sense that no event is normally generated after the command
has completed.
2015-05-20 20:55:08 +03:00
Szymon Janc
7c2c6fbf57 emulator: Move Host Buffer Size Command handling block
Commands codes in switch-case are kept in ascending order.
2015-05-20 20:55:07 +03:00
Szymon Janc
fac4629544 emulator: Verify Set Controller To Host Flow Control Command
Return invalid parameters error if reserved value is used.
2015-05-20 20:55:05 +03:00
Johan Hedberg
8cd59c7734 emulator: Reset LE scan & adv state upon HCI_Reset 2015-05-20 11:11:40 +03:00
Szymon Janc
4bc962568a android/pts: Remove SPP tests not implemented in PTS 2015-05-19 20:47:04 +02:00
Mariusz Skamra
cdc97c6700 android/pts: Update SPP test results
PTS 6.1 and Android 5.1
2015-05-19 20:46:31 +02:00
Mariusz Skamra
0a72b76346 android/pts: Update MCAP test results
PTS 6.1 and Android 5.1
2015-05-19 20:45:27 +02:00
Mariusz Skamra
12616644ba android/pts: Update DID test results
PTS 6.1 and Android 5.1
2015-05-19 16:42:43 +02:00
Mariusz Skamra
ab068036fd android/pts: Update GAP test results
PTS 6.1 and Android 5.1
2015-05-19 16:42:43 +02:00
Mariusz Skamra
b576fa4d33 shared/att: Add ext_signed flag to be able to use external crypto
Due to the issues with CSRK tests ext_signed flag has been added to
allow android/gatt handle signed write operations.

This patch fixes following tests:
GAP__TC_SEC_CSIGN_BV_02_C
GAP__TC_SEC_CSIGN_BI_01_C
GAP__TC_SEC_CSIGN_BI_02_C
GAP__TC_SEC_CSIGN_BI_03_C
GAP__TC_SEC_CSIGN_BI_04_C
SM__TC_SIGN_BV_03_C
2015-05-19 16:42:43 +02:00
Grzegorz Kolodziejczyk
c895e5ae5b profiles/network: Add support for handling extension hdr in ctrl msg
Support for extension headers is mandatory functionality. This patch
add support to it and leave responsibility for processing extension
header and sending setup success response to kernel.

This patch is necessary to pass PTS bnep test TC_CTRL_BV_19_C.
2015-05-19 16:33:35 +02:00
Grzegorz Kolodziejczyk
90012afd11 lib/bnep: Update bnep header with BNEPGETSUPPFEAT and setup response
This patch updates bnep header with get bnep supported features ioctl
xand bnep setup response flag.
2015-05-19 16:31:56 +02:00
Mariusz Skamra
04436a9d64 android/pts: Update HFP test results
PTS 6.1 and Android 5.1
2015-05-19 16:15:08 +02:00
Mariusz Skamra
2670b0c3aa android/pts: Update PBAP test results
PTS 6.1 and Android 5.1
2015-05-19 16:10:00 +02:00
Marcel Holtmann
4bbadba8b8 tools: Provide HOME environment variable before calling qemu 2015-05-19 12:19:11 +02:00
Johan Hedberg
5f5094dc55 emulator: Pretend to support host flow control command 2015-05-19 11:07:37 +03:00
Szymon Janc
e66c163290 tools: Add initial HCI User Channel tester
This adds basic tests only.
2015-05-18 22:02:19 +02:00
Luiz Augusto von Dentz
386028d3ef unit/test-gdbus-client: Don't run tests if setup fails
This will make all gdbus tests be ignored if D-Bus is not available and
one cannot be created with dbus-run-session.
2015-05-18 21:35:40 +03:00
Luiz Augusto von Dentz
65f10c8537 build: Check if dbus-run-session for unit tests
This checks if dbus-run-session is available and then add it to
AM_TESTS_ENVIRONMENT so tests using D-Bus run in its own session.
2015-05-18 21:35:40 +03:00
Andrei Emeltchenko
314cf64222 adapter: Fix memory leak
In case of error with dbus stuff free allocated memory and set filter
to NULL.
2015-05-18 10:44:46 +03:00
Andrei Emeltchenko
cb0182cc17 tester: Test DHKey generation in controller
Test that appropriate command status event and LE Meta events are
generated.
2015-05-17 10:39:14 +03:00
Andrei Emeltchenko
26b9d72adf btdev: Add DHKey generation command to emulator
Add LE Generate DHKey Command available in Bluetooth Spec 4.2.
Controller sends Command Status and LE Meta event LE Generate DHKey
Complete.
...
> HCI Event: Command Status (0x0f) plen 4
      LE Generate DHKey (0x08|0x0026) ncmd 1
        Status: Success (0x00)
> HCI Event: LE Meta Event (0x3e) plen 34
      LE Generate DHKey Complete (0x09)
        Status: Success (0x00)
        Diffie-Hellman key:<key>
...
2015-05-17 10:39:13 +03:00
Andrei Emeltchenko
a36a7af598 tester: Add test for LE Read Local PK
Test that public/private key pair is generated.
2015-05-17 10:39:12 +03:00
Andrei Emeltchenko
409de18730 btdev: Add LE Read Local Public Key cmd to emulator
Support LE Read Local P-256 Public Key Command introduced in Bluetooth
Spec 4.2. The Controller shall generate a new P-256 public/private key
pair upon receipt of this command so private key is saved to btdev.
2015-05-17 10:39:11 +03:00
Andrei Emeltchenko
f16b30cf3f tester: Add HCI LE Rand command
Check status only
2015-05-17 10:39:10 +03:00
Andrei Emeltchenko
bd16cbccb8 tester: Add HCI LE Encrypt command test
Use RFC 4493 "The AES-CMAC Algorithm" sample test vectors to test HCI
controller encryption.
2015-05-17 10:39:09 +03:00
Andrei Emeltchenko
9626d1e5b6 btdev: Refactor Le Rand using Linux crypto infrastructure
Use standard Linux crypto infrastructure for emulating HCI LE Rand
command.
2015-05-17 10:39:08 +03:00
Andrei Emeltchenko
1c8f39a843 btdev: Add LE Encrypt command support to emulator
Add basic crypto support to btdev using Linux crypto infrastructure.
2015-05-17 10:39:07 +03:00
Szymon Janc
06fc39b55a doc/test-coverage: Update mgmt-tester test count 2015-05-17 10:39:00 +03:00
Szymon Janc
efa46eb08c tools/mgmt-tester: Add Device Found test with invalid ADV_DATA
This test verify if kernel correctly terminates EIR when invalid
ADV_DATA (length includes non-significant part) was received from
 remote device.
2015-05-17 10:39:00 +03:00
Szymon Janc
f41312b893 emulator/bthost: Add support for setting custom ADV data
This allows to set any ADV data and not just flags.
2015-05-17 10:39:00 +03:00
Andrei Emeltchenko
cf8c7401a0 gatt: Fix NULL pointer dereference
Safely return in case of error.
2015-05-17 10:39:00 +03:00
Marcel Holtmann
b5093e5688 lib: Update company identifiers 2015-05-17 01:22:51 +02:00
Marcel Holtmann
a08f1baa24 build: Always build Android support for releases 2015-05-17 01:08:37 +02:00
Marcel Holtmann
8ab72fb4b0 tools: Limit CPUID check to IA platforms 2015-05-17 01:06:26 +02:00
Gowtham Anandha Babu
25eadc12ea tools: Handle the common profile & service ecode
Handles the common profile and service error codes sent over the
Attribute Protocol in btgatt-client and monitor.
2015-05-15 14:48:27 +03:00