CBAttributePermissions
Values that represent the read, write, and encryption permissions for a characteristic’s value.
Declaration
struct CBAttributePermissionsOverview
When you initialize a new mutable characteristic, you set the read, write, and encryption permissions for the characteristic’s value. Setting the read and write permissions for a characteristic’s value is different from specifying the read and write properties for a characteristic’s value. When you specify the read and write properties, the client (a central) inspects the read and write permissions of the characteristic’s value. When you specify the read and write permissions for a characteristic’s value, you set the permissions for the server (the peripheral) to allow the type of read or write specified by the characteristic’s properties. Therefore, when you initialize a mutable characteristic, you need to specify read or write properties and their corresponding permissions.
If you want to enforce encryption requirements for reads and writes on a characteristic’s value, you must specify the relevant permission (readEncryptionRequired or writeEncryptionRequired). You may set more than one permission for a characteristic’s value.