Diff between ed0ee6eb932f9af41272a8f0090ee3ef82f2a616 and 60faa1eb043e1031ee52323835e8f0921ca63635

Changed Files

File Additions Deletions Status
unit/test-sdp.c +47 -0 modified

Full Patch

diff --git a/unit/test-sdp.c b/unit/test-sdp.c
index f537a03..310bce6 100644
--- a/unit/test-sdp.c
+++ b/unit/test-sdp.c
@@ -1322,5 +1322,52 @@ int main(int argc, char *argv[])
 			0x00),
 		raw_pdu(0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x04));
 
+	/*
+	 * Service Search Attribute Request
+	 *
+	 * Verify the correct behaviour of the IUT when searching
+	 * for existing Attribute, using invalid request syntax,
+	 * using the ServiceSearchAttributeRequest PDU.
+	 */
+	define_ssa("BI-01-C/UUID-16",
+		raw_pdu(0x06, 0x00, 0x01, 0x00, 0x0b, 0x35, 0x03, 0x19,
+			0x01, 0x00, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00),
+		raw_pdu(0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x03));
+	define_ssa("BI-01-C/UUID-32",
+		raw_pdu(0x06, 0x00, 0x01, 0x00, 0x0d, 0x35, 0x05, 0x1a,
+			0x00, 0x00, 0x01, 0x00, 0x35, 0x03, 0x09, 0x00,
+			0x01, 0x00),
+		raw_pdu(0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x03));
+	define_ssa("BI-01-C/UUID-128",
+		raw_pdu(0x06, 0x00, 0x01, 0x00, 0x19, 0x35, 0x11, 0x1c,
+			0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x10, 0x00,
+			0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb,
+			0x35, 0x03, 0x09, 0x00, 0x01, 0x00),
+		raw_pdu(0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x03));
+
+	/*
+	 * Service Search Attribute Request
+	 *
+	 * Verify the correct behaviour of the IUT when searching
+	 * for existing Attribute, using invalid PDU-size, using the
+	 * ServiceSearchAttributeRequest PDU.
+	 */
+	define_ssa("BI-02-C/UUID-16",
+		raw_pdu(0x06, 0x00, 0x01, 0x00, 0x12, 0x35, 0x03, 0x19,
+			0x01, 0x00, 0xff, 0xff, 0x35, 0x03, 0x09, 0x00,
+			0x01, 0x00),
+		raw_pdu(0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x04));
+	define_ssa("BI-02-C/UUID-32",
+		raw_pdu(0x06, 0x00, 0x01, 0x00, 0x14, 0x35, 0x05, 0x1a,
+			0x00, 0x00, 0x01, 0x00, 0xff, 0xff, 0x35, 0x03,
+			0x09, 0x00, 0x01, 0x00),
+		raw_pdu(0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x04));
+	define_ssa("BI-02-C/UUID-128",
+		raw_pdu(0x06, 0x00, 0x01, 0x00, 0x20, 0x35, 0x11, 0x1c,
+			0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x10, 0x00,
+			0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb,
+			0xff, 0xff, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00),
+		raw_pdu(0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x04));
+
 	return g_test_run();
 }