Update the OTMContext management mechanism to improve the reliability of the OTM... 57/13857/7
authorChul Lee <chuls.lee@samsung.com>
Mon, 31 Oct 2016 03:02:30 +0000 (12:02 +0900)
committerRandeep Singh <randeep.s@samsung.com>
Wed, 9 Nov 2016 05:58:01 +0000 (05:58 +0000)
commit77b6057600843dab97b1af64f31c6aacd5a9b32c
treecd73ef89bf51d62a8919b7d25f35bda7b71564d5
parentf1efbed041407660f5d630044b11507d249466ac
Update the OTMContext management mechanism to improve the reliability of the OTM process.

  1. Apply the list mechanism to manage the OTMContext.
    -> It replaces the global variables of OTMContext.

  2. Add the OCDoHandle member into OTMContext.
    -> In case of OTM process stopped before OTM process complete,
       unnecessary retransmission can be occur
       due to request is performed just before the OTM process stops.
       So we need to cancel this request to prevent retransmission.
       OCDoHandle will be used at this time.

  3. Add the device status of PDM to prevent duplicate OTM.
    -> Added PDM_DEVICE_INIT to prevent deplicate OTM.
       If device status is PDM_DEVICE_INIT, PT will skip OTM process of this device.

Change-Id: I74e200aa88a0c5016c065a518b75614bf4a3a7a8
Signed-off-by: Chul Lee <chuls.lee@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/13857
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
12 files changed:
resource/csdk/security/provisioning/SConscript
resource/csdk/security/provisioning/include/internal/otmcontextlist.h [new file with mode: 0644]
resource/csdk/security/provisioning/include/internal/ownershiptransfermanager.h
resource/csdk/security/provisioning/include/internal/provisioningdatabasemanager.h
resource/csdk/security/provisioning/src/multipleownershiptransfermanager.c
resource/csdk/security/provisioning/src/ocprovisioningmanager.c
resource/csdk/security/provisioning/src/otmcontextlist.c [new file with mode: 0644]
resource/csdk/security/provisioning/src/ownershiptransfermanager.c
resource/csdk/security/provisioning/src/provisioningdatabasemanager.c
resource/csdk/security/provisioning/unittest/provisioningdatabasemanager.cpp
resource/csdk/security/src/aclresource.c
resource/csdk/security/src/doxmresource.c