This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Please tell me how to set permissions.

Hello.
I'm thinking about what I can do with peripheral rolls.

I have a question about GATT communication data.
The following content was described in the Core Specification of the Bluetooth SIG.

The following access permissions are possible:
• Readable
• Writeable
• Readable and writable
The following encryption permissions are possible:
• Encryption required
• No encryption required
The following authentication permissions are possible:
• Authentication Required
• No Authentication Required
The following authorization permissions are possible:
• Authorization Required
• No Authorization Required

I think that the structure used when setting the data of the characteristic is "ble_add_char_params_t".
How can I set the contents described?

Best regards.

  • • No encryption required
        BLE_GAP_CONN_SEC_MODE_SET_ENC_NO_MITM

    Correction: BLE_GAP_CONN_SEC_MODE_SET_OPEN

    The following authentication permissions are possible:
    • Authentication Required

    BLE_GAP_CONN_SEC_MODE_SET_SIGNED_NO_MITM and BLE_GAP_CONN_SEC_MODE_SET_SIGNED_WITH_MITM

    Authenticate by signature

    • No Authentication Required
        BLE_GAP_CONN_SEC_MODE_SET_NO_ACCESS

    This will block access to the attribute. What is it you want here?

    I've only used the Open and LESC with MITM in my projects. What is it you want to achieve specifically?

  • Hello.

    What I want to do is create a characteristic that can only be read and written by central devices that meet certain criteria.

    At that time, you have to set each characteristic, but I don't know what kind of setting should be done, so please let me know.

    Best regards.

  • Hello.

    I tried to summarize it with reference to what you taught me.
    Please tell me if this is the case.

    The following content showed the same thing.
    
    BLE_GAP_CONN_SEC_MODE_SET_NO_ACCESS         ⇔   SEC_NO_ACCESS
    BLE_GAP_CONN_SEC_MODE_SET_OPEN              ⇔   SEC_OPEN
    BLE_GAP_CONN_SEC_MODE_SET_ENC_NO_MITM       ⇔   SEC_JUST_WORKS
    BLE_GAP_CONN_SEC_MODE_SET_ENC_WITH_MITM     ⇔   SEC_MITM
    BLE_GAP_CONN_SEC_MODE_SET_SIGNED_NO_MITM    ⇔   SEC_SIGNED
    BLE_GAP_CONN_SEC_MODE_SET_SIGNED_WITH_MITM  ⇔   SEC_SIGNED_MITM
    
    
    The following access permissions are possible:
    • Readable  → ble_gatt_char_props_t read = 1
    • Writeable → ble_gatt_char_props_t write = 1
    • Readable and writable → ble_gatt_char_props_t read = 1, write = 1
    
    The following encryption permissions are possible:
    • Encryption required → security_req_t SEC_JUST_WORKS & SEC_MITM & SEC_SIGNED & SEC_SIGNED_MITM
    • No encryption required → security_req_t SEC_OPEN
    
    The following authentication permissions are possible:
    • Authentication Required → security_req_t SEC_MITM & SEC_SIGNED & SEC_SIGNED_MITM
    • No Authentication Required → security_req_t SEC_OPEN & SEC_JUST_WORKS
    
    The following authorization permissions are possible:
    • Authorization Required → security_req_t SEC_MITM & SEC_SIGNED & SEC_SIGNED_MITM
    • No Authorization Required → security_req_t SEC_OPEN & SEC_JUST_WORKS
    

    Best regards.

  • Hello.

    I need your information to create a feature.
    If possible, please reply as soon as possible.

    Best regards.

  • sorry for the delay, i had a covid case in my home and hence had to be away from work

    Yes, your reference settings and its understanding seems ok to me.

Related