Soletta Project is a framework for making IoT devices. With Soletta Project's libraries developers can easily write software for devices that control actuators/sensors and communicate using standard technologies. It enables adding smartness even on the smallest edge devices.
I'm improving the src/test/test-lwm2m.c program to cover all new functionalities
added during GSoC, and found this issue.
This patch fixes a bug when a given LWM2M Server who owns a given
Access Control Object Instance tries to modify it (for instance,
to add or remove an ACL for a given third-party LWM2M Server).
There was no way to modify an Access Control Object Instance, since
the check_authorization() would fail, not finding an Access Control
Object Instance related to the target instance - which should not
exist anyway. To fix it, a new condition was added in case the target
obj_id == ACCESS_CONTROL_OBJECT_ID, in which we should only look
for the target instance_id itself and then inside the OWNER Resource,
not looking for ACLs or anything else.
I'm improving the
src/test/test-lwm2m.c
program to cover all new functionalities added during GSoC, and found this issue.This patch fixes a bug when a given LWM2M Server who owns a given Access Control Object Instance tries to modify it (for instance, to add or remove an ACL for a given third-party LWM2M Server).
There was no way to modify an Access Control Object Instance, since the check_authorization() would fail, not finding an Access Control Object Instance related to the target instance - which should not exist anyway. To fix it, a new condition was added in case the target
obj_id
==ACCESS_CONTROL_OBJECT_ID
, in which we should only look for the targetinstance_id
itself and then inside the OWNER Resource, not looking for ACLs or anything else.Signed-off-by: Bruno Melo bsilva.melo@gmail.com