platform/upstream/iotivity.git
7 years agofixed warning for Android build
jihwan.seo [Thu, 18 Aug 2016 05:33:55 +0000 (14:33 +0900)]
fixed warning for Android build

Change-Id: I9e992a42f275dd6f36e43a0eb98a32688c686ba9
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10577
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Ziran Sun <ziran.sun@samsung.com>
Reviewed-by: Jon A. Cruz <jon@joncruz.org>
7 years agoClean compilar warnings
George Nash [Fri, 5 Aug 2016 18:40:34 +0000 (11:40 -0700)]
Clean compilar warnings

[unused-variable] warning removed from
    policyengine.c
    caipserver.c
    ocresource.c
[unused-but-set-variable] warning removed from
    psinterface.c
    policyengine.c
[return-type] warning removed from
    psinterface.c
[sign-compare] warning removed from
    doxmresource.c

Change-Id: I44b633871e78a2baf9d0595dff926834581160c9
Signed-off-by: George Nash <george.nash@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10087
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jon A. Cruz <jon@joncruz.org>
7 years agoAccountManager bug fixed
Jung Seungho [Thu, 25 Aug 2016 08:25:46 +0000 (17:25 +0900)]
AccountManager bug fixed

replace userInfo.getUuid() with userUuid that already created.

Change-Id: Icc08e33499c7b15663359ea76a4073fb75d5e92c
Signed-off-by: Jung Seungho <shonest.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10907
Reviewed-by: Yeonghun Nam <yeonghun.nam@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoUpdate security-provisioning logic
Jihun Ha [Thu, 25 Aug 2016 02:27:02 +0000 (11:27 +0900)]
Update security-provisioning logic

 - add client's security-DB reset logic when server's security-DB is deleted

Change-Id: I0e6eadd9effb17e12da2c528ceb41ccb551a20a4
Signed-off-by: Heewon Park <h_w.park@samsung.com>
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10761
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoReplace normal Tag in Log with Easy Setup specified Tag
Heewon Park [Thu, 25 Aug 2016 07:16:39 +0000 (16:16 +0900)]
Replace normal Tag in Log with Easy Setup specified Tag

 - using wrong TAG.

Change-Id: If4e01e3e7d66116e69ffe7e76fb8a2d875de4eb9
Signed-off-by: Heewon Park <h_w.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10899
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoadd JNI methods related to group&invite
Jaewook Jung [Thu, 18 Aug 2016 13:41:33 +0000 (22:41 +0900)]
add JNI methods related to group&invite

As I added new C++ APIs related to group and invite, I implemented JNI
methods too.
(https://gerrit.iotivity.org/gerrit/#/c/10149/)

Change-Id: I48be652cec7eb6d85cd8e406481e62a7d3f2dc5f
Signed-off-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10625
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoMerge remote-tracking branch 'origin/notification-service'
cc [Thu, 25 Aug 2016 04:56:19 +0000 (13:56 +0900)]
Merge remote-tracking branch 'origin/notification-service'

Topic feature is added.

Change-Id: I2dd9127d274e2f8d11c19abdabda7188517410da
Signed-off-by: cc <ch79.cho@samsung.com>
7 years agoModify response logic for NSTopicEntityHandler.
jaesick.shin [Wed, 24 Aug 2016 08:48:59 +0000 (17:48 +0900)]
Modify response logic for NSTopicEntityHandler.

two times, send response.

second patch included,
remove the DoResponse for error case.

Change-Id: Ife6e8b87868afa6307ed82ca41430b1837c56798
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10879
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoUpdated JAVA and JNI API's for Topic Resource
nikhil.a [Wed, 24 Aug 2016 15:53:08 +0000 (21:23 +0530)]
Updated JAVA and JNI API's for Topic Resource

1. Added JAVA APIs related to topic resource for provider and consumer
2. Added JNI for respective Java API's
3. Minor changes for cpp-wrapper

Change-Id: I459c70b64529040010d099bf239d42863b1417c2
Signed-off-by: nikhil.a <nikhil.a7@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10883
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoUpdated Topic resource changes for C++ wrapper
abitha.s [Fri, 12 Aug 2016 08:47:21 +0000 (14:17 +0530)]
Updated Topic resource changes for C++ wrapper

1. Modified the Topic resource and Topic LL changes in Provider and Consumer
2. Updated the APIs for Topic resource in C++ wrapper
3. Updated the sample application for calling Topic APIs

patch 1 : initial commit
patch 2 : updated commit message
patch 3 : updated review comments
patch 4 : updated commit message
patch 5 : removed NSAccessPolicy struct

Change-Id: I737bef2eebb129c5f13034d990398d75dd13b3b7
Signed-off-by: abitha.s <abitha.s@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10623
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoFix bug for Find provider using Address.
KIM JungYong [Wed, 24 Aug 2016 04:41:12 +0000 (13:41 +0900)]
Fix bug for Find provider using Address.

When finding provider using address,
search logic do invalid type casting for provider connection information.
For the above reason, Provider was never finding with address on storage.
In this patch, invalid type casting is fixed.

Change-Id: I6cde6c9b85e589501cb3ae7567246e631d5e9a65
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10845
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify cloud interface
cc [Mon, 22 Aug 2016 07:00:12 +0000 (16:00 +0900)]
Modify cloud interface

Cloud interface and APIs are modified according to cloud module changes.
And configurations related to the interface are changed.

Conflicts:
service/notification/examples/linux/notificationconsumer.c

Change-Id: I0c7cb16dd19596cda90c0eef2a6332cc6a5532ae
Signed-off-by: cc <ch79.cho@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10717
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoBug fixes for unlock mutex.
jaesick.shin [Wed, 24 Aug 2016 08:42:09 +0000 (17:42 +0900)]
Bug fixes for unlock mutex.

Add unlock mutex NSStorageDelete.

Change-Id: I52795aff7395051b00f60f764163cda85e318be1
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10877
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoAdd explanatory comments for doxygen in easy setup
Jihun Ha [Wed, 24 Aug 2016 03:03:57 +0000 (12:03 +0900)]
Add explanatory comments for doxygen in easy setup

Add comments in easy setup class.
Additionally, header files of internal classes moves to src folder so that
they are excluded in doxygen file.

Change-Id: I7b4b46de0206bf81d19812e9236d1fe4afd4b1a7
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10843
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoAccountManager bug fixed (private group creation)
yeonghun.nam [Wed, 24 Aug 2016 08:05:38 +0000 (17:05 +0900)]
AccountManager bug fixed (private group creation)

1. add device logic is fixed (when the other device of a user once signed up)

Change-Id: Ic35638e457b504514e0aa0e14b61517881c05c72
Signed-off-by: yeonghun.nam <yeonghun.nam@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10875
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoAdd Consumer Logic to update observe result for each connections
YounghyunJoo [Wed, 24 Aug 2016 05:10:58 +0000 (14:10 +0900)]
Add Consumer Logic to update observe result for each connections

- Modify to update result additionally in case of observe fail during while loop

Change-Id: I272db06e182e0ded3c227de571fa15cd736feabe
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10853
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoAdd new RD API to support a specific device id.
hyuna0213.jo [Mon, 22 Aug 2016 11:26:51 +0000 (20:26 +0900)]
Add new RD API to support a specific device id.

Add new RD API to support a specific device id.

Change-Id: Ifa6cf02752ad53e180818bceef0ac75650875889
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10739
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoUpdate readme files for cloud
Jee Hyeok Kim [Wed, 24 Aug 2016 05:34:23 +0000 (14:34 +0900)]
Update readme files for cloud

1. Update readme files for cloud
   (CI, RD, AS, MQ)

2. Update readme file for sample client

Change-Id: I3459192c3d43d4a3e6621980b881ac5e7876ce68
Signed-off-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10855
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
7 years agoFix wrong API call in easy setup
Jihun Ha [Wed, 24 Aug 2016 07:10:23 +0000 (16:10 +0900)]
Fix wrong API call in easy setup

getESCloudState is removed in https://gerrit.iotivity.org/gerrit/#/c/10685/.
Instead, getESResult is used.

Change-Id: I5972ba99508230b53e42e1b6f0a0281a81d48076
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10867
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoAdd logic to handle GET/POST request with various interface
Jihun Ha [Wed, 24 Aug 2016 06:48:24 +0000 (15:48 +0900)]
Add logic to handle GET/POST request with various interface

Provisioning resource supports Baseline, link-list, batch interface and
each interface expects a different payload format. This patch is to handle
this.

Change-Id: If6513b4442377a3493d80f68bc04050e58f889c7
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10865
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
7 years agoremoved unnecessary enum value for message queue.
jihwan.seo [Thu, 18 Aug 2016 07:38:32 +0000 (16:38 +0900)]
removed unnecessary enum value for message queue.

Change-Id: I75393da0348cdc32cf3ea08c0b81709d6820cdb6
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10589
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agofixed to convert Result issue related OC_EH_VALID, OC_STACK_SLOW_RESOURCE
jihwan.seo [Fri, 19 Aug 2016 07:52:41 +0000 (16:52 +0900)]
fixed to convert Result issue related OC_EH_VALID, OC_STACK_SLOW_RESOURCE

when return value in entity handler is set OC_EH_VALID, OC_EH_SLOW,
Error response was sent automatically.

Change-Id: Ica8042aab4e91ec8d276cde1ee2b8e6cd4216997
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10779
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Ziran Sun <ziran.sun@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoSend ack response when the request is CON for presence
hyuna0213.jo [Tue, 23 Aug 2016 01:15:53 +0000 (10:15 +0900)]
Send ack response when the request is CON for presence

If resource-client subscribe presence with CON, resource-server
should send the response message to stop the retransmission.

Change-Id: I90008dffc6a8940c9f1645c27d4ded6efa6d9421
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10755
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoChange uri from 'ocf' to 'oic'
Jaehong Jo [Mon, 22 Aug 2016 05:57:30 +0000 (14:57 +0900)]
Change uri from 'ocf' to 'oic'

According to a OCF spec.
And associated with the patch below.
https://gerrit.iotivity.org/gerrit/#/c/10581/

Change-Id: I74cab69eb1b0a0b241591c0e48ee5fe63ce3f54d
Signed-off-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10713
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hyuna Jo <hyuna0213.jo@samsung.com>
Reviewed-by: Eunok Shin <eunok.shin@samsung.com>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
Reviewed-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoadded APIs related to group&invite on OCAccountManager
Jaewook Jung [Fri, 29 Jul 2016 08:34:31 +0000 (17:34 +0900)]
added APIs related to group&invite on OCAccountManager

According to the OCF cloud specification, I implemented new 15 APIs
related to group and invite.
: createGroup, getGroupList, deleteGroup, joinGroup, addDeviceToGroup,
  getGroupInfo, leaveGroup, deleteDeviceFromGroup, observeGroup,
  cancelObserveGroup, observeInvitation, cancelObserveInvitation,
  sendInvitation, cancelInvitation, deleteInvitation

Change-Id: I29e4cb8839d254a58be48b04d0fef35e6fbb2867
Signed-off-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10149
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoModify cloud client buildscript
Jee Hyeok Kim [Wed, 24 Aug 2016 05:43:48 +0000 (14:43 +0900)]
Modify cloud client buildscript

1. Uncomment cloud client build script.

Change-Id: Icbf836be13684322f96bd2791c916da9790ed516
Signed-off-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10857
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
7 years agoUse global variable to pass the event from ca jni to app in android
hyuna0213.jo [Mon, 15 Aug 2016 23:29:22 +0000 (08:29 +0900)]
Use global variable to pass the event from ca jni to app in android

Use global variable to not create the local variable when we received
event from stack.

Change-Id: I013d916e531568f0668eb1ee850d234591607465
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10467
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoRead CA cert from SVR DB for TLS
Jongmin Choi [Thu, 18 Aug 2016 08:17:06 +0000 (17:17 +0900)]
Read CA cert from SVR DB for TLS

Read and use CA cert from SVR DB for TLS
assuming that SVR DB has a Trust CA credential

Patch #1: Initial upload
Patch #2: API Renamed
Patch #3-4: Support for reading multiple cred & encoding types

Change-Id: Ibc930d6c8b0fa436077f1f71336489e0fb1e1ac6
Signed-off-by: Jongmin Choi <jminl.choi@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10601
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
7 years agoUpdate the OCRemoveDeviceWithUuid API to delete the target device information
Chul Lee [Thu, 18 Aug 2016 14:09:20 +0000 (23:09 +0900)]
Update the OCRemoveDeviceWithUuid API to delete the target device information
in case of target device not discovered.

Change-Id: Ie6b95a5ce322bb21e64cf7f350640293391cf018
Signed-off-by: Chul Lee <chuls.lee@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10629
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Heewon Park <h_w.park@samsung.com>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
7 years agoRestrict topic list control when Provider does not have permission.
jaesick.shin [Tue, 23 Aug 2016 09:44:00 +0000 (18:44 +0900)]
Restrict topic list control when Provider does not have permission.

If provider does not have the comsumer subscription accept capability
following topic related API should not work.
1. NSProviderSelectTopic
2. NSProviderUnselectTopic

Change-Id: I197a60a0aae5eef3226f3766f1b793594628a9f9
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10795
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify invalid type for NSPostConsumerTopics.
jaesick.shin [Tue, 23 Aug 2016 09:27:04 +0000 (18:27 +0900)]
Modify invalid type for NSPostConsumerTopics.

change int to int64_t.

Change-Id: Iba4a1897cfb1e234da8574849e3fa739eaaaad8c
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10793
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
7 years agomodify logic for OC_REST_POST of topic.
jaesick.shin [Tue, 23 Aug 2016 07:21:41 +0000 (16:21 +0900)]
modify logic for OC_REST_POST of topic.

1. Accepter is provider case :
   - our service is not support sendtopiclist from OC_REST_POST
2. // Accepter is consumer.
   - our service is support sendtopiclist from OC_REST_POST

Change-Id: I4e2090197f388892e831071e7d3ff600494261c7
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10781
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify logic for related Topic.
jaesick.shin [Tue, 23 Aug 2016 06:25:17 +0000 (15:25 +0900)]
Modify logic for related Topic.

This patch included
add OCDoReponse for NSEntityHandlerTopicCb.
add DeleteConsumerTopicList.
When the topic entityhandler OC_REST_POST is requested,
the function is called NSPostConsumerTopics.
At this time, delete a list of consumer who have a provider,
and make a new selection topiclist.

second patch included.
modify comment out.

Change-Id: Ib5eba3809dfc199bc2ab93008e32591da1312060
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10773
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify Consumer example & Logic to copy provider
YounghyunJoo [Wed, 24 Aug 2016 04:57:41 +0000 (13:57 +0900)]
Modify Consumer example & Logic to copy provider

- Modify example code to test Topic
- Modify Logic to copy provider during processing topic

Change-Id: I4a6ca0d2d0c203fcfb76af00cc4c05b745d498e0
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10783
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoRemove unnecessary flags in script files when building iotivity & easy setup targeted...
sy01.youn [Tue, 23 Aug 2016 22:57:59 +0000 (07:57 +0900)]
Remove unnecessary flags in script files when building iotivity & easy setup targeted to Tizen.
Also remove unused tizen script files.
In addtion, security related function is activated in Tizen Enrolle Sample App. (which was commented before)
Tested on Tizen Mobile Z3, and it works well.

Change-Id: If70424c31949aa22210b64c45003983ea56a8594
Signed-off-by: sy01.youn <sy01.youn@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10833
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoAdd Logic to store NSProvider subscribe information after subscribing
YounghyunJoo [Tue, 23 Aug 2016 11:58:11 +0000 (20:58 +0900)]
Add Logic to store NSProvider subscribe information after subscribing

- fix bug for non-storing issue
- fix bug logic which does not push task into the queue when received presence stopped

Change-Id: I0ba93229bfa02361def5bfbf357043ec05e5a4f1
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10759
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoFix sign up error in AccountResource
Jung Seungho [Wed, 24 Aug 2016 01:02:20 +0000 (10:02 +0900)]
Fix sign up error in AccountResource

Change-Id: I85d3190534ef795d1669ec72209f675c4b7cbb5d
Signed-off-by: Jung Seungho <shonest.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10835
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoModify MessagId for type.
jaesick.shin [Tue, 23 Aug 2016 12:33:59 +0000 (21:33 +0900)]
Modify MessagId for type.

The OIC specification supports 32 bits only for int type.

Change-Id: I6485f6657c4de50340727b244b5fe22f71da5816
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10805
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoMerge branch 'cloud-interface'
Jee Hyeok Kim [Tue, 23 Aug 2016 22:03:45 +0000 (07:03 +0900)]
Merge branch 'cloud-interface'

Change-Id: I0afaad7de29086f718b99dcadc8f001881f4cb2c
Signed-off-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoResolved svace issues in AccountServer
yeonghun.nam [Mon, 22 Aug 2016 10:12:40 +0000 (19:12 +0900)]
Resolved svace issues in AccountServer

Change-Id: I2818113959143b1c1877b7b179ab4b5293d703a3
Signed-off-by: yeonghun.nam <yeonghun.nam@samsung.com>
Signed-off-by: Glen Youngjin Kim <glen.kim@samsung.com>
Signed-off-by: Jung Seungho <shonest.jung@samsung.com>
Signed-off-by: yeonghun.nam <yeonghun.nam@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10639
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agofixed CI unit test.
Jung Seungho [Tue, 23 Aug 2016 09:20:28 +0000 (18:20 +0900)]
fixed CI unit test.

1. Code Coverage up to 84.5%.
2. Fixed DeviceServerSystem and Constants.
3. Add the Apache License comment.

Change-Id: I2e70a87e7179daee227e2ec703e9720400eeb0d3
Signed-off-by: Jung Seungho <shonest.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10535
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agomodify the payload format of device presence resource according to the specifications
eunok.shin [Tue, 16 Aug 2016 09:45:39 +0000 (18:45 +0900)]
modify the payload format of device presence resource according to the specifications

Change-Id: I6031880957198acea537a83a327724114cdc8d46
Signed-off-by: eunok.shin <eunok.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10507
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoFix a defect detected by a static code analysis tool
Jihun Ha [Tue, 23 Aug 2016 12:08:08 +0000 (21:08 +0900)]
Fix a defect detected by a static code analysis tool

The static analysis tool detects a defect about indentation. This patch
is to align the indentation.

Change-Id: I4a72caa256fa3a42132e346c2cc2c67717a83539
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10803
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoAdd deallocation memory for related topic.
jaesick.shin [Tue, 23 Aug 2016 07:10:10 +0000 (16:10 +0900)]
Add deallocation memory for related topic.

This patch included,
Add deallocation memory for remaining task.

Change-Id: I344ae1f65eb8385959a832baf9e09454833cc611
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10777
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoFix build with TinyCBOR from the dev branch: stop using internal API
Thiago Macieira [Sun, 31 Jul 2016 06:15:48 +0000 (23:15 -0700)]
Fix build with TinyCBOR from the dev branch: stop using internal API

Using the CborEncoder "ptr" member is deprecated. TinyCBOR 0.3
introduced two functions that replace the uses we had here. TinyCBOR 0.4
will rename those members.

Change-Id: I0031aa609e714ae983c3fffd14664c21b9460423
Signed-off-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/9867
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: David Antler <david.a.antler@intel.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Habib Virji <habib.virji@samsung.com>
7 years agoFix bug for copy of provider informations.
KIM JungYong [Mon, 22 Aug 2016 08:05:08 +0000 (17:05 +0900)]
Fix bug for copy of provider informations.

When provider information was stored,
storage module copy whole of provider connections,
but first pointer of connection information was wrongly redefine with next connection information.
For the reason, first connection information was ignored.
In this patch wrongly calculation of pointer was fixed.

Change-Id: Ic91abd458979c2b113e641b3d9c28e6894dd5b7f
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10723
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoadd cloud client samples
Minji Park [Tue, 23 Aug 2016 06:36:21 +0000 (15:36 +0900)]
add cloud client samples

- air conditioner added for cloud client c++ api sample
- thin light added for cloud client c api sample

Change-Id: Ie054119f8309f554169954a87dec8077973e2ea9
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10771
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoUpdate EnrolleeConf data model
Heewon Park [Mon, 22 Aug 2016 10:29:58 +0000 (19:29 +0900)]
Update EnrolleeConf data model

 - chaged the getter/setter logic

Change-Id: I1871bc29aa0bae9d49fff4756e8dae54c5c6467d
Signed-off-by: Heewon Park <h_w.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10733
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoMerge "Merge remote-tracking branch 'origin/master' into notification-service" into...
Uze Choi [Tue, 23 Aug 2016 11:25:34 +0000 (11:25 +0000)]
Merge "Merge remote-tracking branch 'origin/master' into notification-service" into notification-service

7 years agoBug fixes unittest for ExpectCallNotifyOnConsumerByAcceptIsTrue.
jaesick.shin [Tue, 23 Aug 2016 00:57:47 +0000 (09:57 +0900)]
Bug fixes unittest for ExpectCallNotifyOnConsumerByAcceptIsTrue.

change new NSMessage to NSCreateMessage.

Change-Id: Ic6639f936504a40fe5b40a2ed0efdabf4d6121c7
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10751
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoRemove not required function.
jaesick.shin [Tue, 23 Aug 2016 05:44:00 +0000 (14:44 +0900)]
Remove not required function.

this patch included
remove not required function in NSProviderMemoryCache.
and refactoring code about related NSStorageDelete function.

Change-Id: Iee2e6bbfb149a4cf3d1a0908974d0c752e54be0b
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10765
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agobug fixes logic for subscription cache update.
jaesick.shin [Mon, 22 Aug 2016 07:15:55 +0000 (16:15 +0900)]
bug fixes logic for subscription cache update.

If consumer have controlled access
then provider always allowed for subscription.
Added call function of subscription updateState.

second patch included,
remove not required code.
change NSSendSubscriptionResponse to NSSendConsumerSubResponse.

Change-Id: Ia39766e814130bd492193e5c3a57436493b9e409
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10719
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoUpdate Sconscript to disable easysetup unittest for secured mode
Jihun Ha [Tue, 23 Aug 2016 09:21:23 +0000 (18:21 +0900)]
Update Sconscript to disable easysetup unittest for secured mode

Easysetup SDK is utilizing some of security APIs. These APIs will be tested
in unittests of security implementation. So Easy setup does not have to do
unittest for secured mode.

Change-Id: I8250592dd05939cf448e73b90a2b69f85beb12c8
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10791
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoUpdate Android.mk file in easy setup
Jihun Ha [Tue, 23 Aug 2016 01:05:08 +0000 (10:05 +0900)]
Update Android.mk file in easy setup

To build successfully even if the codes is built for various architecture,
e.g., armeabi, x86.

Change-Id: Idcf06150d6c7694ef4e5510467ac18a29b581d27
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10753
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoremove prefix .well-known uri & change from 'ocf' to 'oic' uri
eunok.shin [Thu, 18 Aug 2016 05:43:49 +0000 (14:43 +0900)]
remove prefix .well-known uri & change from 'ocf' to 'oic' uri

Change-Id: I23cdfc7b86dd9576b96fe14841a2d7257b8fb29f
Signed-off-by: eunok.shin <eunok.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10581
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoUpdate resource types of easy setup
Jihun Ha [Tue, 23 Aug 2016 01:16:08 +0000 (10:16 +0900)]
Update resource types of easy setup

Rather than "ocf.wk." prefix, "oic.wk." is decided to be used.

Change-Id: Ic140b82fdc987da0d95491abe9985febf1e6b544
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10757
Reviewed-by: Heewon Park <h_w.park@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoUpdate unittest for easy setup along with the removal of ESCloudProvState
Jihun Ha [Mon, 22 Aug 2016 10:49:43 +0000 (19:49 +0900)]
Update unittest for easy setup along with the removal of ESCloudProvState

In successful provisioning for cloud, ES_FOUND_ENROLLE and ES_OK are returned
in a callback function.

Change-Id: I1ab32d817ff324a777d60d2ecbb5a5a1908a4f0b
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10735
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agomodify cbor method logic.
Jung Seungho [Mon, 22 Aug 2016 01:16:26 +0000 (10:16 +0900)]
modify cbor method logic.

1. remove unnecessary method (parser devodeDeviceId)
2. Add Exception, when payload is null.

Change-Id: Idfffe24425c2c1f9c9f98f7efe1837bfc080b554
Signed-off-by: Jung Seungho <shonest.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10697
Reviewed-by: Yeonghun Nam <yeonghun.nam@samsung.com>
Reviewed-by: Glen Youngjin Kim <glen.kim@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoAccountManger fixed to verify refreshtoken
yeonghun.nam [Mon, 22 Aug 2016 08:06:18 +0000 (17:06 +0900)]
AccountManger fixed to verify refreshtoken

Change-Id: I7e88b61d61c08be8e777e19cbe736524499af42c
Signed-off-by: yeonghun.nam <yeonghun.nam@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10255
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Eunok Shin <eunok.shin@samsung.com>
Reviewed-by: Glen Youngjin Kim <glen.kim@samsung.com>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoSave and Provision Trust Cert. Chain
js126.lee [Thu, 18 Aug 2016 07:43:39 +0000 (16:43 +0900)]
Save and Provision Trust Cert. Chain

1. Save TrustCertChain as binary
2. Provision TrustCertChain
3. Add credusae and optionaldata into cred resource

[Patch 1] Upload patch
[Patch 2] Add encodingtype into optionaldata
[Patch 3] Add encodingtype into OC/SRPSVACETrustCertChain API
[Patch 4] Apply review comment

Note: You can verify this patch with https://gerrit.iotivity.org/gerrit/#/c/10597/

Change-Id: I651f3e61bcfc16e2d7355fe6a01833fda4433579
Signed-off-by: js126.lee <js126.lee@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10595
Reviewed-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
Tested-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
7 years agoadd unit tests for invite resource in accout server
Minji Park [Tue, 16 Aug 2016 09:08:34 +0000 (18:08 +0900)]
add unit tests for invite resource in accout server

- test cases for invite resource
- add request query check in invite resource

Change-Id: I24de60fd3884c64437e35a5c0b1ed29cd5685378
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10499
Reviewed-by: Yeonghun Nam <yeonghun.nam@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: jung seungho <shonest.jung@samsung.com>
Reviewed-by: Glen Youngjin Kim <glen.kim@samsung.com>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agofix detected potential defects in RD
Minji Park [Fri, 19 Aug 2016 04:27:57 +0000 (13:27 +0900)]
fix detected potential defects in RD

- detected warnings with SVACE fixed

Change-Id: I2b03fdb09905703f70eba03354d37f0cab9949fe
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10643
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Glen Youngjin Kim <glen.kim@samsung.com>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
Reviewed-by: Eunok Shin <eunok.shin@samsung.com>
7 years agoMerge remote-tracking branch 'origin/master' into notification-service
Hun-je Yeon [Tue, 23 Aug 2016 03:55:18 +0000 (12:55 +0900)]
Merge remote-tracking branch 'origin/master' into notification-service

Change-Id: Ifc4d229deb7d96800790c617536d96b9ad25136c
Signed-off-by: Hun-je Yeon <hunje.yeon@samsung.com>
7 years agoFix build fail of consumer unittest.
KIM JungYong [Mon, 22 Aug 2016 02:03:59 +0000 (11:03 +0900)]
Fix build fail of consumer unittest.

When notification service build,
before unittest is commented why unittest has fail case and build error.
Fail case is resolved other patch by Jaesick.shin.
In this patch, build error is fixed.

Change-Id: Id5a588f719ae8b6eb1ac78bf987dd793da208c14
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10707
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoRemoved the duplicated code in catcpserver.c
hyuna0213.jo [Thu, 11 Aug 2016 00:30:47 +0000 (09:30 +0900)]
Removed the duplicated code in catcpserver.c

removed the duplicated code caused by merge of
https://gerrit.iotivity.org/gerrit/#/c/8027/

Change-Id: Id9429af0959cae4a2cc9d508a007c7b26a7e0c31
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10243
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoCorrect wrong use of API for creating resources in unittests.
Ziran Sun [Mon, 8 Aug 2016 10:05:48 +0000 (11:05 +0100)]
Correct wrong use of API for creating resources in unittests.

Change-Id: Ib05481a2a87c2eb4714832d453a8455a80c1456f
Signed-off-by: Ziran Sun <ziran.sun@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10139
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Habib Virji <habib.virji@samsung.com>
7 years agoModify TLS adapter implementation to store subjectAltName
Oleksii Beketov [Thu, 18 Aug 2016 11:04:36 +0000 (14:04 +0300)]
Modify TLS adapter implementation to store subjectAltName

CAdecryptTls() from ca_adapter_net_tls.c modified to check certificate
for subject alternative name (SAN) optional field. It will be stored
as userId.

Change-Id: I5a018f1030873f031966d785658db8c9b36f2839
Signed-off-by: Oleksii Beketov <ol.beketov@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10613
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
7 years agoModify unittest for ExpectCallNotifyOnConsumerByAcceptIsTrue.
jaesick.shin [Mon, 22 Aug 2016 03:45:10 +0000 (12:45 +0900)]
Modify unittest for ExpectCallNotifyOnConsumerByAcceptIsTrue.

this unittest is sometimes success or fail.

Change-Id: I5db819e90919c9db1281b0853c44214cbf58cc43
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10701
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoModify some internal functions' name in easy setup
Jihun Ha [Sat, 20 Aug 2016 06:20:37 +0000 (15:20 +0900)]
Modify some internal functions' name in easy setup

This patch change names of some funtions more readable.
Additionally, update the codes to remove warning messages in building

Change-Id: Ifaf31b0bc99641110a79f199bea753fa4e4597dd
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10689
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Heewon Park <h_w.park@samsung.com>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoRemove ESCloudProvState in Jni and Android
Jihun Ha [Sat, 20 Aug 2016 05:32:01 +0000 (14:32 +0900)]
Remove ESCloudProvState in Jni and Android

Followed by https://gerrit.iotivity.org/gerrit/#/c/10685/,
this change is applied to jni and Android.

Change-Id: I0f716706f65ef4f455a61ccbd9f79ae4854458ed
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10687
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Heewon Park <h_w.park@samsung.com>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoRemove ESCloudProvState due to duplication
Jihun Ha [Sat, 20 Aug 2016 04:52:03 +0000 (13:52 +0900)]
Remove ESCloudProvState due to duplication

ESCloudProvState and ESResult can produce a similar result in easy setup.
So ESCloudProvState is decided to be merged into ESResult for consistency
with the other provisioning API like deviceProvisioning.

Change-Id: Ic937688f0f47eac9b7f4ce2b257ea7c3c6306eba
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10685
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoComment out unittest of resource hosting.
KIM JungYong [Mon, 22 Aug 2016 04:45:55 +0000 (13:45 +0900)]
Comment out unittest of resource hosting.

When unittest of resource hosting running,
lead to crash because pure virtual method called.
some of resource hosting class has OCResource as shared pointer.
When the termination of application
OCResource as shared pointer call destructors on RH's instance termination,
but RI c++ alread terminated, so RH app(unittest) lead to crash.

Change-Id: I297300a16ecd0e4dd7f9a1db8557d7167a59c5a5
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10705
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoMQ unit test updated
Minji Park [Thu, 18 Aug 2016 09:46:21 +0000 (18:46 +0900)]
MQ unit test updated

- update unit test for exceptional cases

Change-Id: I5eabc438257bfa22b084ea2fb5bb6468c053e733
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10607
Reviewed-by: Yeonghun Nam <yeonghun.nam@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Glen Youngjin Kim <glen.kim@samsung.com>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoFix unittest of things manager to wait a certain time to discover resources
Jihun Ha [Mon, 22 Aug 2016 04:26:23 +0000 (13:26 +0900)]
Fix unittest of things manager to wait a certain time to discover resources

findCandidateResources can have the third parameter which is a waitTime
for discovering resources. If it is not specified, it acts like findResource.
It means, once any resource is discovered, it is immediately called, which
makes the test case failed if wrong resource is discovered.
To resolve this issue, we wait until a right resource id discovered.

Change-Id: Ib3d6f5595c955c8565d031d5fd2faf2ee904abe5
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10703
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoAS unit test fixed according to fixed ServerSystem
yeonghun.nam [Thu, 18 Aug 2016 10:19:52 +0000 (19:19 +0900)]
AS unit test fixed according to fixed ServerSystem

Change-Id: I685db0f2cc4f9016cd4916889b8a3b145ae945b2
Signed-off-by: yeonghun.nam <yeonghun.nam@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10471
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: jung seungho <shonest.jung@samsung.com>
Reviewed-by: Glen Youngjin Kim <glen.kim@samsung.com>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agofixed bug for setValue in refreshAccessToken
Jaewook Jung [Wed, 17 Aug 2016 08:00:43 +0000 (17:00 +0900)]
fixed bug for setValue in refreshAccessToken

Since OCRepresentation doesn't perceive a const string as std::string value,
need to clarify a type of parameter.
Otherwise, it is passed as a true boolean value whatever it is.

Change-Id: I3db677f6bdf59bf23036dc678781b35af95025e6
Signed-off-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10539
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoFix TLS-related Build error
Jongmin Choi [Sat, 20 Aug 2016 10:28:03 +0000 (19:28 +0900)]
Fix TLS-related Build error

Fix service build error related to TLS support

Change-Id: If0c9884ed2e21e8810c4a9d8b2e79b6cbf38dd90
Signed-off-by: Jongmin Choi <jminl.choi@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10693
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
7 years agoFix build fail of consumer unittest.
KIM JungYong [Mon, 22 Aug 2016 02:03:59 +0000 (11:03 +0900)]
Fix build fail of consumer unittest.

When notification service build,
before unittest is commented why unittest has fail case and build error.
Fail case is resolved other patch by Jaesick.shin.
In this patch, build error is fixed.

Change-Id: Id5a588f719ae8b6eb1ac78bf987dd793da208c14
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10699
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoMerge branch 'notification-service'
Hun-je Yeon [Fri, 19 Aug 2016 16:15:18 +0000 (01:15 +0900)]
Merge branch 'notification-service'

Notification topic is added.
After this patch, notification provider could distinguish
the notification according to its topics, and consumer
could receive the selected notification from provider

Change-Id: I66a8c3d6aec28c0e8d20ccdb4f00b77850e374f7
Signed-off-by: Hun-je Yeon <hunje.yeon@samsung.com>
7 years agoFix Consumer's bug & support to non topic scenario
YounghyunJoo [Fri, 19 Aug 2016 08:50:47 +0000 (17:50 +0900)]
Fix Consumer's bug & support to non topic scenario

Change-Id: Iaf704defc826147d85762095ebb0981398e77cac
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10669
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: jaesick shin <jaesick.shin@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
7 years agoFix bug for prevent crash when access null pointer string.
KIM JungYong [Fri, 19 Aug 2016 13:04:18 +0000 (22:04 +0900)]
Fix bug for prevent crash when access null pointer string.

When consumer receive responce of discovery,
we was compare uri of discovered resource with "notification".
But, sometime uri of discovered resource was null,
consumer service occur crash.
In this patch, protection code is added in discover result handling logic.

Change-Id: I9006a36874ea9e282031aa7f95609ac3ac307f02
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10675
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agocomment out for ExpectCallNotifyOnConsumerByAcceptIsTrue case.
jaesick.shin [Fri, 19 Aug 2016 10:37:16 +0000 (19:37 +0900)]
comment out for ExpectCallNotifyOnConsumerByAcceptIsTrue case.

This case is sometimes failed when build with TCP=1.
Comment out for this case.
will change code.

Change-Id: I86c7092da222b2b512b292d3f66760e2f8059851
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10671
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoMerge "Merge remote-tracking branch 'origin/master' into notification-service" into...
Uze Choi [Fri, 19 Aug 2016 11:49:19 +0000 (11:49 +0000)]
Merge "Merge remote-tracking branch 'origin/master' into notification-service" into notification-service

7 years agoChange OCCloudPublish API to OCRDRublish
ch79.cho [Fri, 19 Aug 2016 05:50:34 +0000 (14:50 +0900)]
Change OCCloudPublish API to OCRDRublish

Cloud publish API is changed to OCRDPublish provided by
resource directory. And the cloud login example is removed,
because the API releated to login will be changed.

Change-Id: I13dd27ca5461fb79ef1e2fc0df70d08c9a37515e
Signed-off-by: ch79.cho <ch79.cho@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10655
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoAdd consumer logic for provider was stopped.
KIM JungYong [Thu, 18 Aug 2016 06:56:54 +0000 (15:56 +0900)]
Add consumer logic for provider was stopped.

When consumer presence listener received event of
stopped provider or deleted notification resource of provider,
consumer service does not act anything.
In this patch,
consumer service will process for canceling observe and removing provider infomation.

Change-Id: I9133ddbcbe8e341584ebaf8152c22df003cbb2ff
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10587
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify logic for NSProviderGetConsumerTopicsCacheData Function.
jaesick.shin [Fri, 19 Aug 2016 05:35:24 +0000 (14:35 +0900)]
Modify logic for NSProviderGetConsumerTopicsCacheData Function.

This Function is direct used The User Interface function.
Changed to use a cache memory function.

Change-Id: I567e644a3890f78bb25495b2ab55d46be9f7912f
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10653
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify for Related Topic.
jaesick.shin [Fri, 19 Aug 2016 04:22:17 +0000 (13:22 +0900)]
Modify for Related Topic.

this patch included
1. bug fixes for invalid type and mutex unlock logic.
2. Add NSProviderDeleteConsumerTopic Function. This function is called when you deselect topic.
3. delete NSIsTopicSubscribed function. This function is not required.

Change-Id: I2629418f441ad0efaaee864b22150424158fa43c
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10645
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoFixed wrong address conversion of ip information
hyuna0213.jo [Tue, 16 Aug 2016 08:22:46 +0000 (17:22 +0900)]
Fixed wrong address conversion of ip information

Fixed wrong address conversion of ip information

Change-Id: I8c730ae9ca0efcef51d3e9f90e24f24d3a90bd8b
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10495
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoChange the delimiter from '&' to ';'
Jaehong Jo [Mon, 8 Aug 2016 09:52:46 +0000 (18:52 +0900)]
Change the delimiter from '&' to ';'
According to the specifications

Change-Id: I6c4afcd312515e71b5d9702b2edaa154bce7f2ea
Signed-off-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10135
Reviewed-by: Jaewook Jung <jw0213.jung@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoFix wrong network interface length when secured option is true
hyuna0213.jo [Tue, 16 Aug 2016 22:54:59 +0000 (07:54 +0900)]
Fix wrong network interface length when secured option is true

If secured option is true, network interface length contain
invalid values.

Change-Id: Id6a99ad9ea5d03de724239e9a0d9b21ece3cbe19
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10525
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoFixed memory leak from keep-alive
hyuna0213.jo [Wed, 10 Aug 2016 06:33:17 +0000 (15:33 +0900)]
Fixed memory leak from keep-alive

The keep-alive mechanism was not properly deleting the payload
that was created for keep-alive.

Change-Id: I80736893e472c31f9058c2d2b5c1d3c38a692c04
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10223
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years ago[IoT-1211] modified java file list for Android build
jihwan.seo [Wed, 17 Aug 2016 04:46:20 +0000 (13:46 +0900)]
[IoT-1211] modified java file list for Android build

https://jira.iotivity.org/browse/IOT-1211
Some interfaces including EDR, BLE, NFC will be excluded,
when there is no target option in scons build

Change-Id: I5d488b5cd7b5641c1db75e249b82a8199b46b35f
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10529
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agomodified scan interval logic when BT adapter is on.
jihwan.seo [Tue, 16 Aug 2016 04:12:39 +0000 (13:12 +0900)]
modified scan interval logic when BT adapter is on.

when BT adapter is off -> on,
scan logic is not working
because condition variable was freed.

Change-Id: Ifa244c44d57d60fea84ab42f58b100ab3cf8d147
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10477
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoFix unittest of Things manager for TCP build
Jihun Ha [Fri, 19 Aug 2016 07:14:44 +0000 (16:14 +0900)]
Fix unittest of Things manager for TCP build

If a found resource has TCP connectivity, it would be not used for unittest.

Change-Id: I2a1aa34ee399474c122208e7133fee8dc89267e6
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10661
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoTizen Enrollee Sample App. and its script files are updated. EasySetup logic and...
sy01.youn [Thu, 18 Aug 2016 23:12:22 +0000 (08:12 +0900)]
Tizen Enrollee Sample App. and its script files are updated. EasySetup logic and Wifi Connection implementation (targeted mobile tizen) are newly updated.
It works fine when tested on tizen mobile Z3.

Change-Id: Iff140fc33bb22ec83fd9c4ee26e6ba5fb05ab91c
Signed-off-by: sy01.youn <sy01.youn@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10531
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoAdd & fix unittest of easy setup.
sy01.youn [Thu, 18 Aug 2016 08:20:17 +0000 (17:20 +0900)]
Add & fix unittest of easy setup.

- Add unit test cases
(1) Enrollee handles individual get request from client.
(2) Enrollee handles put request from client.
(3) ESSetCallbackForUserdata API unit test is added.

- Remove GetTargetNetworkInfoFromProvResource API in resourcehandler.
  . This API is not need anymore.

Change-Id: If634923b0daaf9760b78b3d7e853c823769db6ba
Signed-off-by: sy01.youn <sy01.youn@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10603
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
7 years agoFixed memory-leak of |cJSON| object on |json2cbor|
Kyungsun Cho [Thu, 18 Aug 2016 07:22:56 +0000 (16:22 +0900)]
Fixed memory-leak of |cJSON| object on |json2cbor|

Change-Id: I972cb1386ba55279b8f961e2d6c0a76231cac872
Signed-off-by: Kyungsun Cho <goodsun.cho@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10593
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
7 years agoUpdate Provider Example.
jaesick.shin [Fri, 19 Aug 2016 02:15:48 +0000 (11:15 +0900)]
Update Provider Example.

Add User input logic for topic.

Change-Id: I0308f4bf28c222ebb164bf824668579075e058e5
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10633
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoAdd send Response with DOResponse for subscription request.
jaesick.shin [Fri, 19 Aug 2016 02:29:57 +0000 (11:29 +0900)]
Add send Response with DOResponse for subscription request.

observe request alwyas needs response with DoResponse.

Change-Id: Icc9d25def0aed28a48f0f34278e3bc87e6e67d9c
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10641
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify(Fix) Logic bugs in Notification consumer
YounghyunJoo [Thu, 18 Aug 2016 11:38:32 +0000 (20:38 +0900)]
Modify(Fix) Logic bugs in Notification consumer

Change-Id: Ia39dd3519f8ed0febe12b7655aaa9eb3478d33da
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/10615
Reviewed-by: Chihyun Cho <ch79.cho@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>