public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ 0/1] fix writes to attributes of size 512
@ 2023-08-09 20:27 Bart Philips
  2023-08-09 20:27 ` [PATCH BlueZ 1/1] fix writing attributes of length 512 Bart Philips
  2023-08-10  0:10 ` [PATCH BlueZ 0/1] " patchwork-bot+bluetooth
  0 siblings, 2 replies; 4+ messages in thread
From: Bart Philips @ 2023-08-09 20:27 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Bart Philips

writing attributes of length 512 fails, although the Bluetooth spec (Vol 4, Part F, 3.2.9) states that attributes sizes up to 512 are allowed. The check_length calls in write_cb and prep_write_cb in gatt-server.c currently pass the length parameter that include the handle/offset length and therefore fail for attributes of length 512. This patch subtracts the handle/offset length before passing it to the check_length function, allowing writes to attributes up to 512 in size. 

Bart Philips (1):
  fix writing attributes of length 512

 src/shared/gatt-server.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-08-10  0:10 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-09 20:27 [PATCH BlueZ 0/1] fix writes to attributes of size 512 Bart Philips
2023-08-09 20:27 ` [PATCH BlueZ 1/1] fix writing attributes of length 512 Bart Philips
2023-08-09 23:00   ` fix writes to attributes of size 512 bluez.test.bot
2023-08-10  0:10 ` [PATCH BlueZ 0/1] " patchwork-bot+bluetooth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox