szymon-czapracki commented on code in PR #1813:
URL: https://github.com/apache/mynewt-nimble/pull/1813#discussion_r1732828930


##########
targets/nordic_pca10095_net-blehci/syscfg.yml:
##########
@@ -39,4 +39,7 @@ syscfg.vals:
     BLE_MULTI_ADV_INSTANCES: 5
     BLE_PERIODIC_ADV: 1
     BLE_PERIODIC_ADV_SYNC_TRANSFER: 1
-    BLE_VERSION: 51
+    BLE_PERIODIC_ADV_SYNC_BIGINFO_REPORTS: 1
+    BLE_LL_ISO_BROADCASTER: 1

Review Comment:
   Done



##########
nimble/host/audio/services/bass/src/ble_audio_svc_bass.c:
##########
@@ -298,10 +331,23 @@ ble_svc_audio_bass_add_source(uint8_t *data, uint16_t 
data_len, uint16_t conn_ha
     operation.op = BLE_SVC_AUDIO_BASS_OPERATION_ADD_SOURCE;
     operation.conn_handle = conn_handle;
 
+    offset++;
     operation.add_source.adv_addr.type = data[offset++];
+    if (operation.add_source.adv_addr.type < 0 ||
+        operation.add_source.adv_addr.type > 3) {
+        rc = BLE_HS_EINVAL;
+        ev.bass_operation_status.status = BLE_HS_EINVAL;
+        goto done;
+    }
     memcpy(operation.add_source.adv_addr.val, &data[offset], 6);
     offset += 6;
     operation.add_source.adv_sid = data[offset++];
+    if (operation.add_source.adv_sid < 0 ||
+        operation.add_source.adv_sid > 0xF) {

Review Comment:
   Done



##########
nimble/host/audio/services/bass/src/ble_audio_svc_bass.c:
##########
@@ -298,10 +331,23 @@ ble_svc_audio_bass_add_source(uint8_t *data, uint16_t 
data_len, uint16_t conn_ha
     operation.op = BLE_SVC_AUDIO_BASS_OPERATION_ADD_SOURCE;
     operation.conn_handle = conn_handle;
 
+    offset++;
     operation.add_source.adv_addr.type = data[offset++];
+    if (operation.add_source.adv_addr.type < 0 ||
+        operation.add_source.adv_addr.type > 3) {

Review Comment:
   Done



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to