contrib/iotivity.git
9 years agoMerge branch 'master' into resource-manipulation
hunje.yeon [Thu, 16 Jul 2015 00:11:31 +0000 (09:11 +0900)]
Merge branch 'master' into resource-manipulation

Apply latest updates from 'master' branch into 'resource-manipulation' branch

Change-Id: I2a3cce2070bf9193ca8d87261e4422f5ec8649f8
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
9 years agoImprove logging in the stack.
Mandeep Shetty [Mon, 13 Jul 2015 22:11:49 +0000 (15:11 -0700)]
Improve logging in the stack.

Log messages in the stack mostly hinted at WHERE the call flow was
going.
Added logging to say WHAT the execution is doing. Helps tremendously
with debugging the logs if we can see what important params are passed
into functions.

Change-Id: I50a2ebf4be2d4eea527015cad01d27e5d03e6004
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1640
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoUpdated android examples to use OcConnectivityType.CT_DEFAULT since
Rahul Rahul [Wed, 15 Jul 2015 18:53:37 +0000 (11:53 -0700)]
Updated android examples to use OcConnectivityType.CT_DEFAULT since
IPV4 is no longer supported

Change-Id: Ie158c53924d934cd83450297e125c61d71b6bc79
Signed-off-by: Rahul Rahul <rahul.rahul@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1677
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoFixed Double-passing in the cbor parser
Erich Keane [Wed, 15 Jul 2015 18:17:18 +0000 (11:17 -0700)]
Fixed Double-passing in the cbor parser

The Cbor Parser incorrectly missed a break in the parsing
after a double.  This patch repairs that, plus fixes some of
the spacing issues that seem to have come in due to a find/replace

Change-Id: Ife48886bc8d1391cd7e7361ea49eb3aff318431d
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1676
Reviewed-by: Omkar Hegde <omkar.m.hegde@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoRemoved Dead Code from CBOR merge
Erich Keane [Wed, 15 Jul 2015 16:48:16 +0000 (09:48 -0700)]
Removed Dead Code from CBOR merge

Somehow a bit of code from the OCSerialization.h got left
over from the development process.  This commit removes it,
since it is dead code.

Change-Id: I9b692086f3a00b5ff0f4e1b38c25239fe9d40b96
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1675
Reviewed-by: Omkar Hegde <omkar.m.hegde@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoFixing collection samples
Omkar Hegde [Wed, 15 Jul 2015 16:25:49 +0000 (09:25 -0700)]
Fixing collection samples

Wrong property name was being used for resource and
values being added incorrectly to the payload after
CBOR changes.

Change-Id: Id3e4c8c20bae0feee33efb1f5c1479da76f680c9
Signed-off-by: Omkar Hegde <omkar.m.hegde@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1673
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoRemoving unnecessary use of IPV6 flags.
Omkar Hegde [Tue, 14 Jul 2015 21:59:41 +0000 (14:59 -0700)]
Removing unnecessary use of IPV6 flags.

Previously, default flags were interpreted as both
IPv4 and IPv6 and "[ ]" was added around the IP address
in presence uri. This was wrong for IPv4. Changing the
addition of brackets exclusive to IPv6 and removing IPv6
flag from caipserver since it is not supported yet.

Change-Id: Ic103f9f0f10dcda3252e95404bc6f1a19d56597b
Signed-off-by: Omkar Hegde <omkar.m.hegde@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1653
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoMerge "Merge 'security-basecamp' branch into master with CBOR"
Sachin Agrawal [Wed, 15 Jul 2015 18:14:27 +0000 (18:14 +0000)]
Merge "Merge 'security-basecamp' branch into master with CBOR"

9 years agoMerge 'security-basecamp' branch into master with CBOR
Sachin Agrawal [Wed, 15 Jul 2015 16:40:26 +0000 (09:40 -0700)]
Merge 'security-basecamp' branch into master with CBOR

security-basecamp for 0.9.2 is merged in master brach.

Change-Id: Ia5cd2710a688d3e631009ed03f7e5eb97aba5d24
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agofixed linux, android sample app in CA
hyuna0213.jo [Wed, 15 Jul 2015 05:25:21 +0000 (14:25 +0900)]
fixed linux, android sample app in CA

- add the payload length
- resolve the compile warning

Change-Id: I2766090765790283afecc05f052ec77b85252334
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1658
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoadd descriptor in andorid BLE server
jihwan.seo [Tue, 14 Jul 2015 23:46:35 +0000 (08:46 +0900)]
add descriptor in andorid BLE server

actually, it had removed previously for Tizen 2.4
but as not only Tizen 2.4 delay to release but also
OIC spec/linux BLE is supporting descriptor.
we decided that it should add.

Change-Id: I07e8b42e566d56d71bd65f5b590f40484c4a8492
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1656
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoUpdated Resource Client and Sample Applications
Jay Sharma [Wed, 15 Jul 2015 07:48:05 +0000 (13:18 +0530)]
Updated Resource Client and Sample Applications

- Added exception for the missed api.
- Updated exception handling in Resource Client
- Added more logs in the Sample Applications

Change-Id: I7a212e05856f37628f2e744d83d4f1619f6a1e06
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1663
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix bug for ResourceCacheManager.
jyong2.kim [Wed, 15 Jul 2015 05:48:52 +0000 (14:48 +0900)]
Fix bug for ResourceCacheManager.

change definition value to milliseconds for time.
add prefix and suffix for definition value.

Change-Id: I7f8496f3ac0d95e206a46b1d90ff896fe019bdb5
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1659
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoUnitTest cases for Resource Client with resource manipulation API
Jay Sharma [Wed, 15 Jul 2015 09:32:31 +0000 (15:02 +0530)]
UnitTest cases for Resource Client with resource manipulation API

Change-Id: I224d370e1a3be92d93b6806ed44d8863a99029cb
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1666
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoMoved resource container API header files to new include folder
Markus Jung [Wed, 15 Jul 2015 07:24:54 +0000 (16:24 +0900)]
Moved resource container API header files to new include folder

Change-Id: I2a22f3efb5f6e0e010b2543697192efeff1a2e1f
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1662
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd logic about device presence timeout handle.
jyong2.kim [Wed, 15 Jul 2015 10:32:58 +0000 (19:32 +0900)]
Add logic about device presence timeout handle.

add device presence timeout.
add changing presence mode.
change to definition value for time.
add definition value for timer.

Change-Id: Ia631d18774d1684207b6bc87cbd8010af8a1a3bd
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1668
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix broken unit-test for the Resource Builder
coderhyme [Tue, 14 Jul 2015 15:02:45 +0000 (00:02 +0900)]
Fix broken unit-test for the Resource Builder

It is caused by AutoNotify which is new feature of ResourceObject.

Change-Id: I20b423d9c155d9f410d809be6b91c4c945d480c7
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Change-Id: I20b423d9c155d9f410d809be6b91c4c945d480c7
Reviewed-on: https://gerrit.iotivity.org/gerrit/1648
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd missing method for ResourceAttributes in Resource Manipulation Module
coderhyme [Tue, 14 Jul 2015 15:04:01 +0000 (00:04 +0900)]
Add missing method for ResourceAttributes in Resource Manipulation Module

clear is a mandatory method for this class.

Change-Id: I5a4a571b9f8c85e06ca98214c42ac610a3cde9ba
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Change-Id: I5a4a571b9f8c85e06ca98214c42ac610a3cde9ba
Reviewed-on: https://gerrit.iotivity.org/gerrit/1649
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoRemove DeadLockException from ResourceObject
coderhyme [Tue, 14 Jul 2015 15:01:46 +0000 (00:01 +0900)]
Remove DeadLockException from ResourceObject

It allows recursive lock from now, instead.

Change-Id: I349c9dd9f2916d73587f814ac98d088790b4e09e
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1647
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix Discovery Payload parsing for Secure Port
Sachin Agrawal [Tue, 14 Jul 2015 21:39:03 +0000 (14:39 -0700)]
Fix Discovery Payload parsing for Secure Port

Discovery response with CBOR was not parsing Secure Port info
in Policy Node.

Change-Id: I8db9e38dc08c3153ab62d58c8ac6fe6872eede7c
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1650
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoImproved OIC Virtual Resource definitions (IOT-603)
Sachin Agrawal [Fri, 10 Jul 2015 16:17:30 +0000 (09:17 -0700)]
Improved OIC Virtual Resource definitions (IOT-603)

There were multiple instances of same virtual resource strings
within C stack. This was a cause of 'many' recent un-intended bugs
in the Ioptivity stack. Updated octypes public interface to publish
'reserved' virtual resources and those can be used by applications.
Also updated associated sample applications.

Change-Id: I587727a63dace0086cc27b994bdf238ad203daa4
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1620
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoFix Discovery Payload
Omkar Hegde [Tue, 14 Jul 2015 21:02:07 +0000 (14:02 -0700)]
Fix Discovery Payload

We were accidentally accessing the resource types
instead of interface name when doing discovery response.
The issue could be seen on running collection samples.

Change-Id: Iabd132e1a8b85b1c8f9890ae2db1a35983bee938
Signed-off-by: Omkar Hegde <omkar.m.hegde@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1651
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoCBOR rebase onto master for merge/review
Omkar Hegde [Fri, 10 Jul 2015 21:41:46 +0000 (14:41 -0700)]
CBOR rebase onto master for merge/review

The CA layer has been converted to use binary data, rather
than string data to support CBOR as a transport.  The CSDK has
been changed to use the OCPlatform object model instead of json
strings.  Underneath this, the JSON encoding has been replaced
with CBOR.

Also, some of the previous blockwise transfer functionality has
been removed, since the blockwise-transfer functionality has been
pushed ot the CA stack.

Change-Id: I6423a5180643cea3d311ec7497b246117f7c02b0
Signed-off-by: Erich Keane <erich.keane@intel.com>
Signed-off-by: Omkar Hegde <omkar.m.hegde@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1613
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoFix for the Jira issue IOT-524
Ravi Nanjundappa [Wed, 24 Jun 2015 10:26:02 +0000 (15:56 +0530)]
Fix for the Jira issue IOT-524

This patch addresses the first part of IOT-524.
Added the --prefix option to install all the build output files
in the user preferred location, if opted for.
All exe files will go into PREFIX/bin and all library files will
go into PREFIX/lib
For ex: /home/XYZ/bin and /home/XYZ/lib

Change-Id: Id1ab0fe0ca0ed0b3b86095df87f172448c366daf
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1439
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jon A. Cruz <jonc@osg.samsung.com>
Reviewed-by: Younghyun Joo <yh_.joo@samsung.com>
Reviewed-by: Minji Park <minjii.park@samsung.com>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoremove unnecessary codes in android BLE
jihwan.seo [Fri, 10 Jul 2015 05:25:03 +0000 (14:25 +0900)]
remove unnecessary codes in android BLE

there are many unnecessary wait/mutex/flag.
it will bring slow performance.

Change-Id: I8cb9c4c93d522c5c32669aab569da1a6ff22511a
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1617
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix IOT-605: fridgeclient executable's abnormal termination
sonu1.yadav [Tue, 14 Jul 2015 09:09:57 +0000 (14:39 +0530)]
Fix IOT-605: fridgeclient executable's abnormal termination

Change-Id: Idcfcd4296d76742859e10b44f36f3ca56ce76ca0
Signed-off-by: sonu1.yadav <sonu1.yadav@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1644
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoChange 'resource-manipulation' folder structure
hunje.yeon [Tue, 14 Jul 2015 12:31:46 +0000 (21:31 +0900)]
Change 'resource-manipulation' folder structure

Move sub-folders of 'modules' to 'src'.
Remove 'modules' folder
Update SConscript according to the folder changes
Disable SConscript of 'resource-manipulation' due to gcc version (jenkins is not gcc4.7)

Change-Id: I90a6f6e0afd3a72a569d70d8c16fd69cad897c8d
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1646
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd AutoNotify & SetRequestPolicy Feature
Heewon Park [Tue, 14 Jul 2015 07:24:08 +0000 (16:24 +0900)]
Add AutoNotify & SetRequestPolicy Feature

 - AutoNotify Feature Implement
 - SetRequestPolicy Feature Implement
 - AutoNotify Unit Test Implement

Change-Id: Idcb346d6bb38637a231d69b91ba5ee3418a5a444
Signed-off-by: Heewon Park <h_w.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1606
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoChanged api's name 'requestTimer' to 'postTimer'
doil.kwon [Mon, 13 Jul 2015 13:28:17 +0000 (22:28 +0900)]
Changed api's name 'requestTimer' to 'postTimer'

Changed api's value's unit 'second' to 'millisecond'

Defined about api's value for using 'expiryTimer'

- MILLISECOND
- SECOND

Change-Id: I92fb805a9cd7351d6971132fb47f83f5f2390ad2
Signed-off-by: doil.kwon <doil.kwon@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1636
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd destroyTimer function to ExpiryTimer
ChaJiwon [Fri, 10 Jul 2015 05:22:37 +0000 (14:22 +0900)]
Add destroyTimer function to ExpiryTimer

User call destroyTimer function, ExpiryTimer is destroyed.

Change-Id: I7cf625adbb51c3ec2ade4f6b223c8a3876ce842f
Signed-off-by: ChaJiwon <jw_wonny.cha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1603
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: kwon doil <doil.kwon@samsung.com>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoModify resourceCache/DataCache file
YounghyunJoo [Mon, 13 Jul 2015 11:28:42 +0000 (20:28 +0900)]
Modify resourceCache/DataCache file

correct building errors
modify the function name from requestTimer to postTimer

Change-Id: I7ed1fb6656291ea1b3d863b27fae53b4a7ebf83d
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1632
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoImplemented C++/Android API for OCRegisterPersistentStorageHandler()
Sachin Agrawal [Mon, 13 Jul 2015 18:17:45 +0000 (11:17 -0700)]
Implemented C++/Android API for OCRegisterPersistentStorageHandler()

Add C++ secure sample client and server test app using c++ persistent
storage handler.
Add Android secure sample client app with persistent storage API.

[Patch set 2]: 1. Enhanced Android secure_simpleclient app to choose SVR DB file.
       2. Fixed setting.gradle for android sample.
               3. Add UTC for Persistent Storage in Plaform Config.
[Patch 3]: 1. Fix Sconscript to install SVR DB file for unit test.
[Patch 4]: 1. Fixed jenkins build break.

[Patch 7]: Fixed build issue due linux provisioning client during andriod build.
[Patch 8]: removed secure_simpleclient/server and modified simpleclient/server
[patch 10]: Removed Dialog box for db file selection.
            Modify simpleserver for PS changes.
[Patch 11]: Addressed Review Comments.
[Patch 13]: Rebased to security-basecamp branch
[Patch 14]: Updated Android Server sample to publish non-secure resource
    (otherwise it will break Android client-server non-secure
     test case)

Change-Id: Ica2fc26e65b228a02bc400f87e9780798c19c700
Signed-off-by: Sandeep Sharma <sandeep.s9@samsung.com>
Signed-off-by: Randeep Singh <randeep.s@samsung.com>
Signed-off-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1491
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoFixed broken observation cancellation.
Mandeep Shetty [Mon, 13 Jul 2015 02:15:37 +0000 (19:15 -0700)]
Fixed broken observation cancellation.

Observe Cancel was broken because the uri from the client callback was
not copied into the request object. This caused connectivity to eat the
request witout sending it out.

Change-Id: Ib0ab815647897f2815fdffc3011e9977a003ac5f
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1637
Reviewed-by: Omkar Hegde <omkar.m.hegde@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFixed Fridge sample with constructResourceObject
Erich Keane [Fri, 10 Jul 2015 23:34:32 +0000 (16:34 -0700)]
Fixed Fridge sample with constructResourceObject

The constructResourceObject takes a host string, which isn't compatible
with the current OCDevAddr address.  This patch parses said string, and
converts it properly to an OCDevAddr.

Change-Id: Id86f3832e596aa8869794a1d33915e158fe85008
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1624
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoFixed CA request/response handler over write issue
Randeep Singh [Wed, 8 Jul 2015 07:13:15 +0000 (16:13 +0900)]
Fixed CA request/response handler over write issue

ocstack register HandleCARequest and handleCAResponse using CARegisterHandler
and save values in global variables to handle request and response.
Provisioning API is also using CARegisterHandler and over writing those handlers.
This change resolves this issue.

Change-Id: Id8d86edb487e58ad1c6a5ed5b0211c4b8b28cd6e
Signed-off-by: Randeep Singh <randeep.s@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1577
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoIn case of Just works provisioning,
leechul [Mon, 13 Jul 2015 00:25:59 +0000 (09:25 +0900)]
In case of Just works provisioning,
Close the temporary dtls session after the ownership transfer.
Now, PT will use the PSK based session for ACL provisioning.

patch#6 : rebase with master
patch#8 : Fix the ownership transfer. But ACL provisioning will still fail.
patch#10 : Change to the copy CAEndPoint_t of addDevice() using memcpy
patch#12 : Resolve provisioning credential issuses.
          (missing the provisioning status intialization to the provision of
           two or more times.)
patch#14 : Resolved mem leak in sendCARequest(). Updated doOwnershipTransfer()
   to disable anon ECDH before leaving the method.
patch#15 : Remove .gitignore which was added accidently in previous patch.
patch$16 : Remove the code that invokes the CASelectCipherSuite().

Change-Id: I5e5ef061c46c4a81615cd923dc915fc028699d74
Signed-off-by: leechul <chuls.lee@samsung.com>
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1628
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoBugfix for unregister of bundles and renamed Java Bundle API getters
Markus Jung [Thu, 9 Jul 2015 10:55:22 +0000 (19:55 +0900)]
Bugfix for unregister of bundles and renamed Java Bundle API getters

Added java bundle test. Allowing container test sample app and unit tests to be build in parallel.
Configureable library path for Java bundles. Set bundle-api version number to 0.1

Change-Id: I8660787613b38d7acc4296c9c6c701397e18dee2
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1597
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoFixed Secure Resource Mgr Policy Engine to allow for wildcard resource URIs.
Nathan Heldt-Sheller [Sat, 11 Jul 2015 05:12:47 +0000 (22:12 -0700)]
Fixed Secure Resource Mgr Policy Engine to allow for wildcard resource URIs.

The Policy Engine was not checking for wilcard resource URIs in Access Control List entry (URI = "*"); this has been added per Security Spec A v0.96r3.

Change-Id: Iff6d8618cee2d177aa1b03dc3c58a78cd1fd6061
Signed-off-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1626
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
Reviewed-by: Shilpa Sodani <shilpa.a.sodani@intel.com>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoMerge branch 'master' into resource-manipulation
hunje.yeon [Sun, 12 Jul 2015 03:35:30 +0000 (12:35 +0900)]
Merge branch 'master' into resource-manipulation

Apply the resece updates from 'master' branch into 'resource-manipulation' branch
This update includes the fix of current 'presence' issues.

Change-Id: I4417164bd31285e80d9dd4b655e6f828ee1b6fe0
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
9 years agoFixed broken presence after IPv6 plumbing merge to master.
Erich Keane [Sat, 11 Jul 2015 05:37:41 +0000 (22:37 -0700)]
Fixed broken presence after IPv6 plumbing merge to 

Presence wasn't working for multiple reasons. oc/presence was not moved
to oic/ad, probably lost in the merge to master.
resourceUri in CA data structures was moved form the endpoint to the
CAInfo struct. But wasn't included in a clone operation which resulted
in a race condition when the memory was free'd in the main thread before
being accessed by the thread in CA.
Other adapter/flag issues.
Unicast presence failed to work because host() from OCResource only
returned the IP without the port.

Change-Id: If2e46f4677ebe369cbaee9609de38c369bf4c524
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Signed-off-by: Erich Keane <erich.keane@verizon.net>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1424
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoChanged C Samples to use correct adapter type
Omkar Hegde [Fri, 10 Jul 2015 23:21:17 +0000 (16:21 -0700)]
Changed C Samples to use correct adapter type

The  C Samples were broken as a result of changing
the samples for IPv6. Also, removed port 6298 from
unicast discovery query and replaced some printf()
with OC_LOG(). Removed Differentiation between
IPv4 and IPv6 in the samples.

Change-Id: I83859aaf468c991ca5406014359476d0f43d5745
Signed-off-by: Omkar Hegde <omkar.m.hegde@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1623
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFixed an invalid read/write caused by deleted temporary
Erich Keane [Fri, 10 Jul 2015 22:42:07 +0000 (15:42 -0700)]
Fixed an invalid read/write caused by deleted temporary

The copy used a std::copy mechanism on optionData, which
resulted in the temporary being deleted before the function
returned.  This creates a variable to hold the temporary so that
the string won't be deleted before use.

Change-Id: I5da2601b730e27d42e244b52ba6cdd69a0e28fb4
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1622
Reviewed-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-by: Omkar Hegde <omkar.m.hegde@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoUpdated Secure Sample for new resource discovery response
Sachin Agrawal [Fri, 10 Jul 2015 00:27:59 +0000 (17:27 -0700)]
Updated Secure Sample for new resource discovery response

Resource Discovery response was udpated to be compliance with
OIC Specification. This change is to correctly parse the
discovery response.

Change-Id: I3c16f0ed827f5f993def01e7741c592b1ad1926b
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1614
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
9 years agoAdd Destructor to free new allocated resource in Ctor.
Jamal Haidar [Sat, 4 Jul 2015 11:59:23 +0000 (17:29 +0530)]
Add Destructor to free new allocated resource in Ctor.

~Middle() and ~RestInput() destrcutors added which deletes allocated
memory in Ctors.

Change-Id: I29823cde6c7b28325fde9b40f088f83994ebc6a5
Signed-off-by: Jamal Haidar <jamal.haidar@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1522
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agocsdk: Fixes cppcheck issue in security dir.
Ravi Nanjundappa [Wed, 1 Jul 2015 13:41:29 +0000 (19:11 +0530)]
csdk: Fixes cppcheck issue in security dir.

This patch fixes the the below issue reported by cppcheck tool in security dir:
"(error) Possible null pointer dereference: jsonObj - otherwise it is
 redundant to check if jsonObj is null at line 259
(error) Possible null pointer dereference: jsonStr1 - otherwise it is
redundant to check if jsonStr1 is null at line 132"

Null value check of jsonObj and jsonStr1 are removed as it in unnecessary here.

Change-Id: I6c0676a58780afea3026c3e1332c8ecac7c0dd1e
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1508
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[CA] RI sample occlient fix for not able to send get unicast data
koushik.girijala [Fri, 3 Jul 2015 07:18:02 +0000 (12:48 +0530)]
[CA] RI sample occlient fix for not able to send get unicast data

fixed OCconectivity type and port number adding to uri

Change-Id: Ie99e66dd6c7840008d9f0cfc41089d183907c585
Signed-off-by: koushik.girijala <g.koushik@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1503
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Abhishek Pandey <abhi.siso@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoUpdated android BLE code
jihwan.seo [Mon, 6 Jul 2015 08:48:28 +0000 (17:48 +0900)]
Updated android BLE code

I have replaced previous property and permission code
with Property_Notify which mentioned OIC ble spec.
(https://workspace.openinterconnect.org/
 apps/org/workgroup/oswg/download.php/1568/
 OIC_BLE_Transport_Profile.pdf)

Change-Id: I7002ba70c9f0d267ef9f695c0cb3ee3688dd9a77
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1532
Reviewed-by: Abhishek Sharma <ce.abhishek@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoUpdated the comments as per Jira IOT-573
sanilgupta [Wed, 1 Jul 2015 06:41:05 +0000 (12:11 +0530)]
Updated the comments as per Jira IOT-573

Please update

Change-Id: Idd318b1f6d2359deb1653b323d35159ffb9fbd8f
Signed-off-by: sanilgupta <sanil.g@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1473
Reviewed-by: Ravi Nanjundappa <nravi.n@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoReplaced printf with Serial.println() in arduino CASample
vimala.v [Thu, 9 Jul 2015 11:54:41 +0000 (17:24 +0530)]
Replaced printf with Serial.println() in arduino CASample

Change-Id: I8ab085b2ca330789255d8397d42cf483a9d97187
Signed-off-by: vimala.v <vimala.v@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1600
Reviewed-by: Abhishek Pandey <abhi.siso@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix Android TinyDtls build issue in Debug mode
jnashok [Fri, 10 Jul 2015 08:10:18 +0000 (17:10 +0900)]
Fix Android TinyDtls build issue in Debug mode

For Android build currently debug.c is not included.
In this case NDEBUG flag must be defined.
Provided a correct fix

Change-Id: Icaa4364a3e87bc33e9e7165977838ba1ea328506
Signed-off-by: jnashok <jn.ashok@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1618
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Abhishek Pandey <abhi.siso@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoResolved compilation issues of BLE adapter in Tizen and Arduino
vimala.v [Thu, 9 Jul 2015 08:39:46 +0000 (14:09 +0530)]
Resolved compilation issues of BLE adapter in Tizen and Arduino

Change-Id: If9c4d1ade926733a3959808e9b3cfc6880e91cb3
Signed-off-by: vimala.v <vimala.v@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1594
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoMerge branch 'master' into resource-manipulation
hunje.yeon [Fri, 10 Jul 2015 04:40:19 +0000 (13:40 +0900)]
Merge branch 'master' into resource-manipulation

Update the recent changes of 'master' branch into 'resource-manipulation' branch

Change-Id: I24c60962d6e6c6d2b80af0333bd5f011b5083f27
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
9 years agoUpdated gitignore to ignore dependencies folder
Sachin Agrawal [Fri, 10 Jul 2015 00:39:06 +0000 (17:39 -0700)]
Updated gitignore to ignore dependencies folder

Ignore 'dep' folder created in iotivity tree when
android build is invoked.

Change-Id: Ibd9630a9d4327c44518d632fb8f39ffd3509b9f3
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1615
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoResource Client updated
Jay Sharma [Thu, 9 Jul 2015 14:31:26 +0000 (20:01 +0530)]
Resource Client updated

- Updated Doxygen comments
- Updated ResourceClient APIs
- Updated Exception handling in Resource Client

Change-Id: Ie299c18d47732c21588dbba8678bb3d3e4b905ac
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1605
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoSample Client and Server Application
Jay Sharma [Thu, 9 Jul 2015 15:54:13 +0000 (21:24 +0530)]
Sample Client and Server Application

- Sample client using the Resource Client APIs (Resource Broker & Resource Cache)
- Sample Server using Server Builder APIs

Change-Id: Ibdafb01f8a9c40c52d9a9175c5e5ddd4c5a43eb6
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1607
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoadd new test cases for resource container
Minji Park [Thu, 9 Jul 2015 13:54:00 +0000 (22:54 +0900)]
add new test cases for resource container

Change-Id: Ie5c917b14c24782b2ec0b08cf9f820bfbbac371b
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1604
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix failure to respond when SRM says Access Denied.
Mandeep Shetty [Thu, 9 Jul 2015 17:15:11 +0000 (10:15 -0700)]
Fix failure to respond when SRM says Access Denied.

The enum types for forbidden request and unauthorized request in
CAResponseResult_t added as part of security where misisng in a sanity
check switch case. This caused the forbidden and unauthorized response
codes to be classified as invalid.

Change-Id: Idc53a50422e3d5e43a847395a2389da351ea6baf
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1610
Reviewed-by: Erich Keane <erich.keane@intel.com>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
Tested-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoUpdated android code based on OcConnectivityType changes due to IPv6 support
Rahul Rahul [Thu, 2 Jul 2015 19:23:14 +0000 (12:23 -0700)]
Updated android code based on OcConnectivityType changes due to IPv6 support

Change-Id: Ic3c332dc72c5ab87f971b346eae0cb5456ac58a7
Signed-off-by: Rahul Rahul <rahul.rahul@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1495
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Bernie Keany <bernie.keany@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoAdding GuiClient example for android
Rahul Rahul [Mon, 6 Jul 2015 22:59:04 +0000 (15:59 -0700)]
Adding GuiClient example for android

Change-Id: I4c0930032ccfc7814965f152846d16561bd3ed76
Signed-off-by: Rahul Rahul <rahul.rahul@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1543
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFixed Tizen CASample to select proper Transport type.
vimala.v [Thu, 9 Jul 2015 10:37:22 +0000 (16:07 +0530)]
Fixed Tizen CASample to select proper Transport type.

Change-Id: I74c8cc3a768501c8620b9f558a1e15da04d79e08
Signed-off-by: vimala.v <vimala.v@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1596
Reviewed-by: Abhishek Sharma <ce.abhishek@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[Tizen][DTLS] Fix for broken DTLS build in Tizen
Abhishek Sharma [Thu, 9 Jul 2015 11:05:26 +0000 (16:35 +0530)]
[Tizen][DTLS] Fix for broken DTLS build in Tizen

Fixed broken DTLS build in Tizen

Change-Id: If281be0640fd11a830655102bc9cd091a82a0df8
Signed-off-by: Abhishek Sharma <ce.abhishek@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1599
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agomodify the preprocessor to stop the thread in ipadapter
hyuna0213.jo [Thu, 9 Jul 2015 05:19:58 +0000 (14:19 +0900)]
modify the preprocessor to stop the thread in ipadapter

In case I use a ndk-build for android sample build,
the MULTI_THREAD is not defined.
because preprocessor was defined within Sconscript.
so I modified the code to stop the send thread.

Change-Id: I732fad2120fe243b6b976230aa395fdbb385dda1
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1588
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Naga Ashok Jampani <jn.ashok@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[Tizen][BLE] Fix for broken BLE build
Abhishek Sharma [Thu, 9 Jul 2015 12:09:08 +0000 (17:39 +0530)]
[Tizen][BLE] Fix for broken BLE build

Fixed broken BLE build for Tizen

Change-Id: I508404f97ef5ef19f1b9820519e44c1d911158da
Signed-off-by: Abhishek Sharma <ce.abhishek@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1601
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix memory leak in policyengine
Jamal Haidar [Thu, 9 Jul 2015 07:56:49 +0000 (13:26 +0530)]
Fix memory leak in policyengine

Temp allocated memory in policyengine is unsed and not freed before
exit.

Change-Id: I1a1f3587c521b83ba764248f00547a2e8997c865
Signed-off-by: Jamal Haidar <jamal.haidar@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1592
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
Tested-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoUpdate Resource Container
Minji Park [Thu, 9 Jul 2015 11:02:06 +0000 (20:02 +0900)]
Update Resource Container

- modify Bundle Resource and samples
- update container for checking config file loaded and listresources

Change-Id: Ib37cfcfd1f4f24ce9573d744abaed057e0b813ae
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1595
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agothings-manager: sampleapp: fix name of musicplayer
Hauke Mehrtens [Mon, 29 Jun 2015 21:07:39 +0000 (23:07 +0200)]
things-manager: sampleapp: fix name of musicplayer

The musicplayer should be named MusicplayerApp as it is referenced
under that name some lines below.

Change-Id: I351ee4316bbb19a67a0afc16882cb2192a2ff07f
Signed-off-by: Hauke Mehrtens <hauke.mehrtens@lantiq.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1445
Reviewed-by: Erich Keane <erich.keane@intel.com>
Reviewed-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd destroy function into primitive service timer
ChaJiwon [Thu, 9 Jul 2015 08:08:15 +0000 (17:08 +0900)]
Add destroy function into primitive service timer

When ExpiryTimer's destructor called, ExpiryTimer requests destroy to ExpiryTimer_impl.
ExpiryTimer_impl makes a decision for destroying instance or not.

Change-Id: Ib93dec7ff76ef96923bf34f5e645a8d0c2b5dfdc
Signed-off-by: ChaJiwon <jw_wonny.cha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1593
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoJavadoc for Java Bundle-API, Modified public access API
Markus Jung [Wed, 8 Jul 2015 13:26:56 +0000 (22:26 +0900)]
Javadoc for Java Bundle-API, Modified public access API

Change-Id: Ie1e50a3f3edb5f59ee331fabfcf8aee160d692f8
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1589
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoChanged discovery JSON for spec compliance to contain device ID.
Mandeep Shetty [Tue, 7 Jul 2015 22:35:12 +0000 (15:35 -0700)]
Changed discovery JSON for spec compliance to contain device ID.

New json schema does not have properties field for resources.
Everything is now a property.
Device ID as string UUID is included in discovery responses once per
response as opposed to being a part of every resource earlier.

Device Ids as part of every resource rep is also accepted and will be
used in resource construction if present.
Refactored filtering and encoding for resource into separate functions.
Removed unnecessary repeated strcmp() to figure out type of virtual
uri.

Change-Id: Ib995e819c8ab63aae6abff956941698d6919f9c4
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/934
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoAdd comments on bundle API headers for doxygen
Minji Park [Wed, 8 Jul 2015 07:59:27 +0000 (16:59 +0900)]
Add comments on bundle API headers for doxygen

Change-Id: I1bc859e37631a28fac7ce92d87b38c730c8457e6
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1579
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoResource container build check for external libraries
Markus Jung [Wed, 8 Jul 2015 06:56:37 +0000 (15:56 +0900)]
Resource container build check for external libraries

There is now a check for libcurl and the Java environment.
If the external libraries are not available, instructions how to
install are provided.

Change-Id: Iee24b49f86ca64887cc84687d78998917177ce0a
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1576
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix string copy issue in Credential resource unit test.
Ankur Bansal [Tue, 7 Jul 2015 07:26:56 +0000 (12:56 +0530)]
Fix string copy issue in Credential resource unit test.

Update getCredList to correctly pass length of destination buffer while
using OICStrcpy.

Change-Id: I4763d295fc1da92831956bf9ed4a34e90718c7f3
Signed-off-by: Ankur Bansal <ankur.b1@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1553
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoIntegrated single/multi thread for interface controller and connectivity manager.
jw1103.kim [Mon, 20 Apr 2015 12:17:44 +0000 (21:17 +0900)]
Integrated single/multi thread for interface controller and connectivity manager.

Merged serperated files by using #SINGLE_THREAD and #MULTI_THREAD flags.

Signed-off-by: jw1103.kim <jw1103.kim@samsung.com>
Signed-off-by: Ashok Channa <ashok.channa@samsung.com>
Change-Id: I2d7b38d86226bdfc03c7a7b12626c2c4459ad305
Signed-off-by: jw1103.kim <jw1103.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/783
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoModify exception class and include guards of broker.
jyong2.kim [Wed, 8 Jul 2015 05:09:59 +0000 (14:09 +0900)]
Modify exception class and include guards of broker.

add exception for subscribe presence.
fix bug about Initialize of DevicePresence.

Change-Id: I4588e213e7b8a56e06a280225d00ce4583909a37
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1572
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoChange thread model to std::thread
ChaJiwon [Wed, 8 Jul 2015 06:25:28 +0000 (15:25 +0900)]
Change thread model to std::thread

Use condition variable to check expired time.
Add lock_guard to insert & cancel timerCBList.
Change Singleton instance pointer from shared pointer to pointer.

Change-Id: I0fc13809777691396140910eac6648b0ea5cfe57
Signed-off-by: ChaJiwon <jw_wonny.cha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1570
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoupdate Resource Container
Minji Park [Wed, 8 Jul 2015 05:58:37 +0000 (14:58 +0900)]
update Resource Container

- update listBundleResources api
- modify unregisterResource in the container and sample bundles
- rearrange the order of methods in resourcecontainerImpl source code

Change-Id: Id7e0d401b96bafd6c781950258c10789cba40319
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1573
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoModify resourceCacheManager
YounghyunJoo [Wed, 8 Jul 2015 06:03:28 +0000 (15:03 +0900)]
Modify resourceCacheManager

add function that erases the cache subscriber on the cache subscriber list when cancelResourceCache() is called
modify "InvalidParameter" name to "InvalidParmeterExecption"

Change-Id: Ide08a397036bbe1daf2922e1cff9f59a968dbe8c
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1574
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agothings-manager: Fix cppcheck issues in TMSampleApp for tizen
Ravi Nanjundappa [Fri, 3 Jul 2015 11:11:27 +0000 (16:41 +0530)]
things-manager: Fix cppcheck issues in TMSampleApp for tizen

This patch fixes the below issues
reported by cppcheck tool in TMSampleApp dir for tizen.
"(error) Possible null pointer dereference: popup_fields ...."

It is invliad to set the member of popup_field to NULL if
popup_field itself is NULL.
Removed such statements from the code.

Change-Id: Ie1457662cb2727e5bab5e21886db6bece2f356a7
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1511
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Harish Marappa <h.marappa@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoBundle deactivation
Markus Jung [Tue, 7 Jul 2015 11:04:39 +0000 (20:04 +0900)]
Bundle deactivation

Implemented bundle deactivation which includes the removal of registered resources.
Modified ContainerTest to load, start and stop different bundles and test the
bundle activation/deactviation.

Change-Id: I5149851278aa457bee5f86c039f8f3a8320b8652
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1568
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd type class for ResourceAttriutes
coderhyme [Wed, 8 Jul 2015 04:00:50 +0000 (13:00 +0900)]
Add type class for ResourceAttriutes

The class helps distinguish types between Values

Change-Id: I7a02c290bb6b1f3fb7d26ef7cb1087268afa36ac
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1569
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoadding functions in Server Builder
Rami Jung [Tue, 7 Jul 2015 13:53:26 +0000 (22:53 +0900)]
adding functions in Server Builder
  setAttributeUpdatedHandler
  removeAddAttributeUpdatedHandler

Change-Id: I13bb7578b6bd92823c96d56866ae456030bacb3a
Signed-off-by: Rami Jung <rami.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1562
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agosoft-sensor-manager: Fixes cppcheck issue for arduino SampleApp
Ravi Nanjundappa [Fri, 3 Jul 2015 11:06:22 +0000 (16:36 +0530)]
soft-sensor-manager: Fixes cppcheck issue for arduino SampleApp

This patch fixes the the below issue reported by cppcheck tool
in stack dir: "(error) Possible null pointer dereference:
entityHandlerRequest - otherwise it is redundant to check if
entityHandlerRequest is null at line 114"

Dereferencing of entityHandlerRequest->resJSONPayload is done if
flag includes OC_REQUEST_FLAG.

The patch also includes removal of some unnecessary blank lines

Change-Id: I8d9d7c40df5602b9d55de8d948871a2c485798a2
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1510
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Minji Park <minjii.park@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoArrange Cache module code and logic.
jyong2.kim [Tue, 7 Jul 2015 10:49:30 +0000 (19:49 +0900)]
Arrange Cache module code and logic.

add namespace OIC::Service.
change parameter and return type of interfaces.
add exception handle in interfaces.
arrange duplicated code and logic.
add updateResourceCache().

Change-Id: I71302bc7cc0351626dd67790e2b4bf787c5b881e
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1558
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoresource container unit tests, updates for container
Minji Park [Tue, 7 Jul 2015 05:41:35 +0000 (14:41 +0900)]
resource container unit tests, updates for container

- unit tests for resource container
- update SConscript
- update bundleinfo and configuration in container

Change-Id: I0c92b15cb1229e5f16a7a7db18aab3cc32778bcc
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1555
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoUsing build() as name to create a new instance of BundleInfo
Markus Jung [Tue, 7 Jul 2015 09:58:33 +0000 (18:58 +0900)]
Using build() as name to create a new instance of BundleInfo

Change-Id: Ib3408ff18a3fe872feffad4acc214feaa2a4926a
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1556
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix build fail of broker module.
jyong2.kim [Tue, 7 Jul 2015 11:00:40 +0000 (20:00 +0900)]
Fix build fail of broker module.

fix syntax error.
add expiryTimer's script in common sconscript.

Change-Id: I396c2249cc68568e81885f1e05a40cccf7f68662
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1560
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: kwon doil <doil.kwon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix for a previous check-in related to secure resources
Sachin Agrawal [Tue, 7 Jul 2015 20:35:30 +0000 (13:35 -0700)]
Fix for a previous check-in related to secure resources

In case where resources are not SECURE, port does not need to be set.

Change-Id: Ic1559534ccd8b002ecd862775ca8a07aa62b356f
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1563
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoUpdated C++ SDK for discovering secure resources
Sachin Agrawal [Mon, 6 Jul 2015 23:51:54 +0000 (16:51 -0700)]
Updated C++ SDK for discovering secure resources

On discovering secure resources, OCResource object needs to be
updated with 'secure' flag and appropriate port for secure resource.

Change-Id: I0a09ae1e6d9bcc73b7d97b9dcaae02955d63cb2d
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1545
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: sandeep sharma <sandeep.s9@samsung.com>
Reviewed-by: Woochul Shim <woochul.shim@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agointegrated caretransmission single/multi thread
hyuna0213.jo [Mon, 11 May 2015 04:50:55 +0000 (13:50 +0900)]
integrated caretransmission single/multi thread

Merged serperated files by using #SINGLE_THREAD flags

Change-Id: I8c0162b6220a221146ffa1428f25612aa0cfc0c4
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/950
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agofixed Android Sample App build issue
jihwan.seo [Tue, 7 Jul 2015 12:16:05 +0000 (21:16 +0900)]
fixed Android Sample App build issue

to import Log was missed
so it was not built

Change-Id: I702b220bddd9ba0243a47eeca718326eb17fa9f6
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1561
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix defects of IOT-534 in Things Manager
Jihun Ha [Tue, 7 Jul 2015 00:40:56 +0000 (09:40 +0900)]
Fix defects of IOT-534 in Things Manager

Exception handling logic is added in group application.
startPresence for enabling presence check is added in speaker and musicplayer apps.

Change-Id: I12f6589154e27d288417d3fdd6413b867499a2bf
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1547
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd handling for error case in GroupManager::getActionSetfromString.
Ankur Bansal [Sat, 4 Jul 2015 13:08:08 +0000 (18:38 +0530)]
Add handling for error case in GroupManager::getActionSetfromString.

Delete action in case something went wrong during parsing.

Change-Id: I0e72db223ef21d0e89351d238532e168b2ca1177
Signed-off-by: Ankur Bansal <ankur.b1@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1523
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix a potential crash in PPM, in case of incomlete xml.
Ankur Bansal [Mon, 6 Jul 2015 12:07:32 +0000 (17:37 +0530)]
Fix a potential crash in PPM, in case of incomlete xml.

Handle the case when pluginInfo tag is missing in the Configuration
file.

Change-Id: I0bc8e14a875a71bd2254d5ef917b3dc7652339f8
Signed-off-by: Ankur Bansal <ankur.b1@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1538
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Younghyun Joo <yh_.joo@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix wrong unittests in RequestHandlerTest
coderhyme [Tue, 7 Jul 2015 02:21:47 +0000 (11:21 +0900)]
Fix wrong unittests in RequestHandlerTest

The tests regarding AcceptanceMethod

Change-Id: Iaa18464b9059887c4ab229e8a5f2ca44bdad221f
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1549
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoReplace setAttribute with non-template methods.
coderhyme [Sat, 4 Jul 2015 07:51:07 +0000 (16:51 +0900)]
Replace setAttribute with non-template methods.

To extract a common interface that manipulates attributes.
And add invokeOCFunc that takes multiple OCStackResult values considered as success.

Change-Id: I39fa49525e95739b7fdbbc06384782453e156f65
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1548
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoModify header file name in the Resource Cache codes
YounghyunJoo [Mon, 6 Jul 2015 05:59:05 +0000 (14:59 +0900)]
Modify header file name in the Resource Cache codes

rename PrimitiveTimer to ExpiryTimer

Change-Id: Ie1dda93d0857537b4b704b38a2c2bf51d7a3196c
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1528
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoApplied to "expiryTimer" for "ResourceBroker"
doil.kwon [Fri, 3 Jul 2015 08:21:23 +0000 (17:21 +0900)]
Applied to "expiryTimer" for "ResourceBroker"

- Header's name is changed(primitiveTimer->expiryTimer)

- Added contents about expiryTimer in SConscript

- Modified variable's name about ExpiryTimer class

- Changed "relative path" to "absolute path" about included path

Change-Id: I4f5b3c125a7450f332d333f761c4010048ff7838
Signed-off-by: doil.kwon <doil.kwon@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1505
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoUsing relative links in configuration files. Implemented listBundles to retrieve...
Markus Jung [Mon, 6 Jul 2015 06:46:53 +0000 (15:46 +0900)]
Using relative links in configuration files. Implemented listBundles to retrieve the current bundles available in the resource container.

Change-Id: Ia5d2f2b7e16cb2eb5f37bd866f33d437c03eb033
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1530
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoApplied IoTivity code style template on all Java source files
Markus Jung [Mon, 6 Jul 2015 06:01:47 +0000 (15:01 +0900)]
Applied IoTivity code style template on all Java source files

Change-Id: I8a72cc1d99e8705add20124f506013cb900110f2
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1529
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix delete array memory issue
Jamal Haidar [Fri, 26 Jun 2015 13:14:23 +0000 (18:44 +0530)]
Fix delete array memory issue

Memory assigned with new array is deleted with non-array delete

Change-Id: I7e3411104d805bab66a863fb2814e93def897def
Signed-off-by: Jamal Haidar <jamal.haidar@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1429
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>