Diff between fe0f3fab1809cdc397b7d8dd41fb0ceed3e73a6c and 28a755273c28a4acc374829b82ec42f86ee08eca
Changed Files
| File | Additions | Deletions | Status |
| src/attrib-server.c | +2 | -0 | modified |
Full Patch
diff --git a/src/attrib-server.c b/src/attrib-server.c
index 9543da6..dc05d7e 100644
--- a/src/attrib-server.c
+++ b/src/attrib-server.c
@@ -173,6 +173,8 @@ static uint8_t att_check_reqs(struct gatt_channel *channel, uint8_t opcode,
channel->encrypted = g_attrib_is_encrypted(channel->attrib);
if (reqs == ATT_AUTHENTICATION && !channel->encrypted)
return ATT_ECODE_INSUFF_AUTHEN;
+ else if (reqs == ATT_AUTHORIZATION)
+ return ATT_ECODE_INSUFF_AUTHO;
switch (opcode) {
case ATT_OP_READ_BY_GROUP_REQ: