Commit Graph

174 Commits

Author SHA1 Message Date
Guo Jia Cheng
1e67cf1ec5 Merge branch 'feature/mdns-multiple-instance' into 'master'
mdns: allow mutiple instances with same service type

See merge request espressif/esp-idf!15180
2021-10-11 02:49:16 +00:00
David Cermak
2a2b95b9c2 mdns: Update copyright header 2021-10-06 20:39:18 +08:00
David Cermak
e7dabb14f7 mdns: Fix potential null dereference identified by fuzzer tests 2021-10-06 20:39:18 +08:00
Jiacheng Guo
b7a99f4658 mdns: allow mutiple instances with same service type 2021-09-22 13:07:31 +08:00
baohongde
b310c062cd components/bt: move config BT_RESERVE_DRAM from bluedroid to ESP32 controller 2021-09-16 20:26:35 +08:00
Guo Jia Cheng
e5766eb3d3 Merge branch 'feature/mdns-async-callback' into 'master'
mdns: add notification callback for async APIs

See merge request espressif/esp-idf!14760
2021-08-25 03:34:00 +00:00
Guo Jia Cheng
139bf4af64 Merge branch 'feature/add-mdns-result-attributes' into 'master'
mdns: add more mdns result attributes

See merge request espressif/esp-idf!14674
2021-08-23 09:28:19 +00:00
David Cermak
fc7e2d9e90 mdns: Add host test using linux target 2021-08-17 18:39:40 +08:00
David Cermak
73dfe84bf2 mdns: Implement mdns_networking using BSD sockets
And use only if configured. By default we still use lwip raw (low-level) API
2021-08-17 18:39:40 +08:00
Jiacheng Guo
986603cf07 mdns: add notification callback for async APIs 2021-08-17 16:53:37 +08:00
Jiacheng Guo
76ec76c12c mdns: add more mdns result attributes 2021-08-11 19:02:05 +08:00
Jiacheng Guo
5e98772eaf mdns: fix crash when adding services without hostname set 2021-07-29 10:45:10 +08:00
David Cermak
619235c2ee mdns: Fix fuzzer IDF-mock layer
Removed lwip dependencies
Simplified the mocks for esp32 and esp-netif
2021-07-01 15:45:05 +02:00
David Cermak
54e329444a mdns: Clean the main mdns module from lwip dependencies
* Reduced number of include paths
* Abstract the internals of mdns packet (specifics defined in
mdns_networking.c)
* Use ESP_IP addresses instead of lwip addresses
2021-07-01 15:01:39 +02:00
David Čermák
6661d01a64 Merge branch 'feature/mdns_query_async' into 'master'
mdns: Add asynchronous query API

See merge request espressif/esp-idf!13988
2021-07-01 12:28:54 +00:00
David Čermák
68f33b75de Merge branch 'bugfix/mdns_fuzzer_crashes' into 'master'
mdns: Fix null dereferences reported by fuzzer tests

See merge request espressif/esp-idf!14153
2021-07-01 10:46:55 +00:00
David Cermak
d81482d699 mdns: Add asynchronous query API
Closes https://github.com/espressif/esp-idf/issues/7090
2021-06-30 17:20:30 +04:00
Jiacheng Guo
2386113972 mdns: return ESP_OK rather than ERR_OK in API functions 2021-06-29 17:35:45 +08:00
Jiacheng Guo
0baee93211 mdns: fix memory leak in mdns_free when adding delegated hostnames 2021-06-29 17:35:45 +08:00
David Cermak
4a2e72677c mdns: Fix crashes reported by the fuzzer tests 2021-06-25 08:34:39 +02:00
David Cermak
dae803335e mdns/fuzzer: Fix non-instrumentation test to reproduce fuzzer issues
Regression from 7d76245173 skipped reading the packet causing issues when locally reproducing crashed found by the fuzzer
2021-06-25 08:33:38 +02:00
David Cermak
f167238fac mdns: Support for One-Shot mDNS queries 2021-06-24 07:05:00 +02:00
David Čermák
3452c5f194 Merge branch 'feature/mdns-value-len' into 'master'
mdns: allow explicit txt value length

See merge request espressif/esp-idf!13981
2021-06-23 14:53:48 +00:00
David Čermák
4d604ee6d2 Merge branch 'bugfix/remove_unstable_network_tests' into 'master'
CI: Move mqtt publish tests from regular pipeline to weekend tests

Closes IDFCI-653

See merge request espressif/esp-idf!13891
2021-06-17 07:04:51 +00:00
Jiacheng Guo
b4e0088b68 mdns: allow explicit txt value length 2021-06-16 17:47:07 +08:00
David Cermak
79ba738626 mdns: Fix crashes reported by the fuzzer 2021-06-11 16:53:06 +02:00
David Cermak
7d76245173 mdns: Minor correction of the test code 2021-06-11 16:53:06 +02:00
David Cermak
14099fe15e mdns: Fix fuzzer from miss-interpreting adding services as timeouts 2021-06-11 16:53:06 +02:00
Jiacheng Guo
a4f263948c mdns: fix test script delayed response 2021-06-04 10:44:36 +08:00
Jiacheng Guo
e6135552d2 mdns: fix wrong SRV/PTR record handling 2021-06-04 10:44:36 +08:00
Jiacheng Guo
439b31d065 mdns: fix wrong service hostname after mangling 2021-06-04 10:44:36 +08:00
Jiacheng Guo
7bbb72d865 mdns: fix empty address change announce packets 2021-06-04 10:44:36 +08:00
Jiacheng Guo
d2a5d25984 mdns: fix mdns probe/reply behavior
* send correct hostnames when probing.
* add test for mdns host delegation.
2021-06-04 10:44:36 +08:00
Jiacheng Guo
2d34352f3d mdns: make delegate host address a list
Also adds unit test and doc string for new apis.
2021-06-04 10:44:36 +08:00
Jiacheng Guo
2174693096 mdns: add remove delegate host api 2021-06-04 10:44:36 +08:00
Jiacheng Guo
401ff56cc1 mdns: add mdns delegation
This allows publishing mdns services for other devices.
2021-06-04 10:44:36 +08:00
Jiacheng Guo
5f244c86f2 mdns: fix memory free issue when repeating the query in reply
The repeated query will be copied in the next event loop while the
memory is freed instantly. Delay the free to fix this issue.
2021-06-04 10:44:36 +08:00
Suren Gabrielyan
03de74a728 mdns: Fix of crash when wifi interface get deleted and mdns receives the packets
Closes https://github.com/espressif/esp-idf/issues/6973
2021-06-02 13:43:54 +00:00
Suren Gabrielyan
53c18a85db Docs: Added README.md for lwip fuzzer tests
Closes IDFCI-540
2021-05-18 17:52:07 +04:00
David Cermak
5cce919cbe mdns: Fixed the ip header TTL to be correctly set to 255
Defined in https://tools.ietf.org/html/rfc6762#section-11: All Multicast DNS responses (including responses sent via unicast)
   SHOULD be sent with IP TTL set to 255
2021-04-12 13:24:19 +00:00
David Cermak
34049454df mdns: Fix parsing answers with questions when instance name not set
mdns resolver didn't correctly resolved queries when host name wasn't
assigned. Fixed by allowing processing also if some answer present
(non-strict mode)

Closes https://github.com/espressif/esp-idf/issues/6598
2021-04-12 13:24:19 +00:00
David Cermak
b649603a0d mdns: Fix the resolver to correctly parse it's own non-strict answers
The resolver was able to respond correctly, but would also resolve its
own queries and cause issues with BCT 1.5.2, specifically
* MULTIPLE QUESTIONS - DUPLICATE SUPPRESSION
* MULTIPLE QUESTIONS - DISTRIBUTED DUPLICATE SUPPRESSION
tests failed.
2021-04-12 13:24:19 +00:00
suren.gabrielyan
0eee31546d mdns: Add MDNS_STRICT_MODE config option
Strict mode was hardcoded in private header file, but it's useful for
users to enable/disable it depending on the mdns library they are using.
e.g. Avahi might not resolve the non-strict answers.
2021-04-12 13:24:19 +00:00
Renz Bagaporo
39cf818838 freertos: common config header 2021-03-22 12:19:03 +08:00
suren.gabrielyan
55716945a9 mdns: Removed freeRTOS dependancies from fuzzer tests 2021-03-11 08:57:36 +00:00
suren.gabrielyan
9f8d2b944d mDNS: Updated APIs description and shows the warning when hostname contains domain name during the query
Closes https://github.com/espressif/esp-idf/issues/6590
2021-03-10 13:38:13 +00:00
yuanjm
da58235a0e components: Use CONFIG_LWIP_IPV6 to strip IPv6 function in components 2021-02-23 18:26:03 +08:00
suren.gabrielyan
2b9d2c06f5 mdns: add bound check when setting interface as duplicate
Closes IDF-2787

Partially addresses https://github.com/espressif/esp-idf/issues/6440
2021-02-15 06:43:51 +00:00
suren.gabrielyan
be0ae1ebbb mDNS: Fix of text length calculation when detecting a collision 2021-01-18 12:54:27 +00:00
Angus Gratton
9769be3fde Merge branch 'bugfix/fix_sign_compare' into 'master'
global: fix sign-compare warnings for system level components

See merge request espressif/esp-idf!11252
2021-01-13 12:45:05 +08:00