All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ 00/13] Fix SDP DE Type Descriptor validation issues
@ 2013-02-10 21:26 Anderson Lizardo
  2013-02-10 21:26 ` [PATCH BlueZ 01/13] unit: Add initial SDP library unit tests Anderson Lizardo
                   ` (13 more replies)
  0 siblings, 14 replies; 44+ messages in thread
From: Anderson Lizardo @ 2013-02-10 21:26 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Anderson Lizardo

Hi,

This series adds various missing DTD validations, specially for SEQ* types. The
lack of these validations allows for a remote device to crash BlueZ due to
invalid memory access.

I also added unit tests for all affected functions. They are in a separate C
file (unit/test-sdp-lib.c), which can contain tests for SDP library API that is
not covered by SDP server tests in unit/test-sdp.c. It also contains various
tests for corner cases that increase code coverage (as measured by gcov/lcov).

The only pending related fixes from my part are some missing NULL pointer
checks when accessing empty sequences. These will take some time to fix as they
affect profile code as well.

Best Regards,

Anderson Lizardo (13):
  unit: Add initial SDP library unit tests
  lib: Add SDP_IS_ALT() macro
  lib: Reuse identical code in sdp_get_{add,}_access_protos()
  lib: Cleanup coding style in sdp_get_proto_descs()
  lib: Fix missing DTD validation while accessing SDP data elements
  unit: Add tests for sdp_get_lang_attr()
  lib: Add missing DTD validation in sdp_record_print()
  lib: Validate DTDs when parsing LanguageBaseAttributeIDList
  lib: Validate DTDs when parsing BluetoothProfileDescriptorList
  lib: Add comment to BluetoothProfileDescriptorList parsing workaround
  lib: Validate DTDs when parsing VersionNumberList
  unit: Add tests for sdp_get_profile_descs()
  unit: Add tests for sdp_get_server_ver()

 .gitignore          |    1 +
 Makefile.am         |    5 +-
 lib/sdp.c           |  164 +++++++++++++-----
 lib/sdp.h           |    1 +
 unit/test-sdp-lib.c |  470 +++++++++++++++++++++++++++++++++++++++++++++++++++
 5 files changed, 594 insertions(+), 47 deletions(-)
 create mode 100644 unit/test-sdp-lib.c

-- 
1.7.9.5


^ permalink raw reply	[flat|nested] 44+ messages in thread

end of thread, other threads:[~2013-02-18  8:05 UTC | newest]

Thread overview: 44+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-10 21:26 [PATCH BlueZ 00/13] Fix SDP DE Type Descriptor validation issues Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 01/13] unit: Add initial SDP library unit tests Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 02/13] lib: Add SDP_IS_ALT() macro Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 03/13] lib: Reuse identical code in sdp_get_{add,}_access_protos() Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 04/13] lib: Cleanup coding style in sdp_get_proto_descs() Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 05/13] lib: Fix missing DTD validation while accessing SDP data elements Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 06/13] unit: Add tests for sdp_get_lang_attr() Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 07/13] lib: Add missing DTD validation in sdp_record_print() Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 08/13] lib: Validate DTDs when parsing LanguageBaseAttributeIDList Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 09/13] lib: Validate DTDs when parsing BluetoothProfileDescriptorList Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 10/13] lib: Add comment to BluetoothProfileDescriptorList parsing workaround Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 11/13] lib: Validate DTDs when parsing VersionNumberList Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 12/13] unit: Add tests for sdp_get_profile_descs() Anderson Lizardo
2013-02-10 21:26 ` [PATCH BlueZ 13/13] unit: Add tests for sdp_get_server_ver() Anderson Lizardo
2013-02-15 14:56 ` [PATCH v2 BlueZ 00/13] Fix SDP DE Type Descriptor validation issues Anderson Lizardo
2013-02-15 14:51   ` Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 01/13] unit: Add initial SDP library unit tests Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 02/13] lib: Add SDP_IS_ALT() macro Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 03/13] lib: Reuse identical code in sdp_get_{add,}_access_protos() Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 04/13] lib: Cleanup coding style in sdp_get_proto_descs() Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 05/13] lib: Fix missing DTD validation while accessing SDP data elements Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 06/13] unit: Add tests for sdp_get_lang_attr() Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 07/13] lib: Add missing DTD validation in sdp_record_print() Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 08/13] lib: Validate DTDs when parsing LanguageBaseAttributeIDList Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 09/13] lib: Validate DTDs when parsing BluetoothProfileDescriptorList Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 10/13] lib: Add comment to BluetoothProfileDescriptorList parsing workaround Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 11/13] lib: Validate DTDs when parsing VersionNumberList Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 12/13] unit: Add tests for sdp_get_profile_descs() Anderson Lizardo
2013-02-15 14:56   ` [PATCH BlueZ 13/13] unit: Add tests for sdp_get_server_ver() Anderson Lizardo
2013-02-15 15:07   ` [PATCH v3 BlueZ 00/13] Fix SDP DE Type Descriptor validation issues Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 01/13] unit: Add initial SDP library unit tests Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 02/13] lib: Add SDP_IS_ALT() macro Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 03/13] lib: Reuse identical code in sdp_get_{add,}_access_protos() Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 04/13] lib: Cleanup coding style in sdp_get_proto_descs() Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 05/13] lib: Fix missing DTD validation while accessing SDP data elements Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 06/13] unit: Add tests for sdp_get_lang_attr() Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 07/13] lib: Add missing DTD validation in sdp_record_print() Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 08/13] lib: Validate DTDs when parsing LanguageBaseAttributeIDList Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 09/13] lib: Validate DTDs when parsing BluetoothProfileDescriptorList Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 10/13] lib: Add comment to BluetoothProfileDescriptorList parsing workaround Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 11/13] lib: Validate DTDs when parsing VersionNumberList Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 12/13] unit: Add tests for sdp_get_profile_descs() Anderson Lizardo
2013-02-15 15:07     ` [PATCH BlueZ 13/13] unit: Add tests for sdp_get_server_ver() Anderson Lizardo
2013-02-18  8:05     ` [PATCH v3 BlueZ 00/13] Fix SDP DE Type Descriptor validation issues Johan Hedberg

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.