piotrnarajowski commented on code in PR #2013:
URL: https://github.com/apache/mynewt-nimble/pull/2013#discussion_r2322372436


##########
apps/btshell/src/btshell.h:
##########
@@ -97,6 +97,23 @@ struct btshell_scan_opts {
 extern struct btshell_conn btshell_conns[MYNEWT_VAL(BLE_MAX_CONNECTIONS)];
 extern int btshell_num_conns;
 
+/* BLE_GATT_READ_MAX_ATTRS * (1 ATT + 1 EATT chan) */
+#define PENDING_ATTR_MAX MYNEWT_VAL(BLE_GATT_READ_MAX_ATTRS) * 2
+
+struct auth_attr {
+    uint16_t conn_handle;
+    uint16_t attr_handle;
+};
+
+extern struct auth_attr authorized_attrs[PENDING_ATTR_MAX];

Review Comment:
   I understand your concern and agree that this is not the best way to store 
such information. This btshell patch was just added as an example on how asnyc 
authorization procedure could look like. It is up to application to store 
information on which peer and what attribute has been already authorized. I'll 
try coming up with a smarter way to handle this for btshell. 



-- 
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