Ver código fonte

ble_mesh: stack: The value of expect_ack_for will be rewrited after send_pub_key().

For case MESH/PVNR/PROV/BV-04-C
wangjialiang 3 anos atrás
pai
commit
ee7d448e3c

+ 6 - 0
components/bt/esp_ble_mesh/mesh_core/provisioner_prov.c

@@ -2943,6 +2943,12 @@ static void gen_prov_ack(const uint8_t idx, struct prov_rx *rx, struct net_buf_s
         case PROV_START:
             pub_key_oob = link[idx].conf_inputs[13];
             send_pub_key(idx, pub_key_oob);
+            /* For case MESH/PVNR/PROV/BV-04-C, if using OOB public key,
+             * the value of expect_ack_for shall be PROV_PUB_KEY.
+             */
+            if (pub_key_oob) {
+                return;
+            }
             break;
         case PROV_PUB_KEY:
             prov_gen_dh_key(idx);