[IOT-2293] [IOT-2192] reject POST to /acl2 Resource with ACL1 payload 89/20189/2
authorNathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Sat, 20 May 2017 20:42:52 +0000 (13:42 -0700)
committerNathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Sun, 21 May 2017 18:18:17 +0000 (18:18 +0000)
commit048711628b037aec7cefa927bf4961e270bf524e
treeee68a190243fea3ec4e5627f85b3767bbaea5ab0
parent17430f70fe1b6e92943ddabdf094fa6bfc29b025
[IOT-2293] [IOT-2192] reject POST to /acl2 Resource with ACL1 payload

/acl2 POST handler now calls a version-check-only optional CBORPayloadToAcl()
function and, if an acl1 payload is found, denies the POST request.

This update caught some unit test issues that were also corrected with
this patch.

Change-Id: I20d148ef037c82f5862fd9fec156bbb399ab7417
Signed-off-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/20189
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
Reviewed-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
resource/csdk/security/src/aclresource.c
resource/csdk/security/unittest/aclresourcetest.cpp