platform/upstream/iotivity.git
7 years ago[IOT-2063] provide available endpoints in CAGetNetworkInformation
hyuna0213.jo [Thu, 27 Apr 2017 07:25:34 +0000 (16:25 +0900)]
[IOT-2063] provide available endpoints in CAGetNetworkInformation

Current IoTivity is sending response including all available endpoints,
which is not desired.

Change-Id: Ib0f20bebc92e0fd8a443ba2a98594381746061fa
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19355
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years ago[RE]Fixed Unit test cases for SECURED=1 and TEST=0 flag.
Jay Sharma [Tue, 25 Apr 2017 03:10:20 +0000 (08:40 +0530)]
[RE]Fixed Unit test cases for SECURED=1 and TEST=0 flag.

Bug:https://jira.iotivity.org/browse/IOT-2091
Change-Id: Ie121edeea0e824313a2bc9de906420af12d22055
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19231
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoWindows: Timer APIs are not Security APIs
Dan Mihai [Wed, 19 Apr 2017 22:41:11 +0000 (15:41 -0700)]
Windows: Timer APIs are not Security APIs

There are currently no callers inside IoTivity that are dependent on
these registerTimer and unregisterTimer exports. Also, callers can
get access to these APIs by linking with static lib c_common.

Given these circumstances, one might argue that octbstack.dll should
not exports these two functions. But, they were already exported in
IoTivity 1.2, so they might be important for compatibity with
hypothetical already-existing IoTivity apps on Windows.

Change-Id: I708d8230e3b6e2f631e89fae2d9b3fab41c93108
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19239
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
7 years ago[IOT-1958] CR 22 State Specific Property Access for /doxm Resource
Nathan Heldt-Sheller [Mon, 24 Apr 2017 04:02:04 +0000 (21:02 -0700)]
[IOT-1958] CR 22 State Specific Property Access for /doxm Resource

Implementation of CR 22 feature to deny UPDATE to /doxm if any
Property in the POST representation is read-only in the current
/pstat.dos.s state.

Includes necessary update to the CBOR marshalling code to support
partial Resource representations for /doxm.

Includes updates to provisioning tools to correctly include only the
/doxm Properties being updated in the POST payload.

Change-Id: I610012be5b19e0ac0218f9f8610cab5171187108
Signed-off-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19215
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years agobridging: Remove lib/lib64 path as unsupported on clang
Philippe Coval [Thu, 30 Mar 2017 11:38:52 +0000 (13:38 +0200)]
bridging: Remove lib/lib64 path as unsupported on clang

I believe they are not used since they are built in in compiler (spec),
especialy on compilation step.

Observed issue on GNU/Linux is:

  clang++-3.5 \
  -o out/linux/x86_64/release/bridging/mpm_client/MPMSampleClient.o \
  -c -std=c++0x -Wall -Wextra -Werror -Os -Wall -Wextra -fPIC -m64 -Llib64 \
  (...) MPMSampleClient.cpp
  clang: error: argument unused during compilation: '-Llib64'

Change-Id: Ifaf6f0b4f67d992392ca60e53a2d8fd54e1051fb
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18421
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ossama Othman <ossama.othman@intel.com>
Reviewed-by: George Nash <george.nash@intel.com>
Reviewed-by: Todd Malsbary <todd.malsbary@intel.com>
(cherry picked from commit 53d888e18973eb5e16a174ea75532bf42a3aa576)
Bug: https://jira.iotivity.org/browse/IOT-1745
Reviewed-on: https://gerrit.iotivity.org/gerrit/19149
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Mats Wichmann <mats@linux.com>
7 years agobuild: Enable notification memchecks
Philippe Coval [Sat, 10 Dec 2016 12:02:56 +0000 (13:02 +0100)]
build: Enable notification memchecks

Bug: https://jira.iotivity.org/browse/IOT-1428
Change-Id: I8538c56dbc6ca0498d9603fc77197bf6278b858d
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18889
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: George Nash <george.nash@intel.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2060] Don't force-link with routingmanager
Dan Mihai [Wed, 19 Apr 2017 02:58:48 +0000 (19:58 -0700)]
[IOT-2060] Don't force-link with routingmanager

Don't force all IoTivity modules to link with routingmanager. Many
modules use the copy of routingmanager from the Shared Library
octbstack, so they don't need to link with routingmanager.

Also routingmanager currently calls into connectivity_abstraction, so
it adds unnecessary headaches when having to specify LIBS in the
strict order required by the gcc linker.

Change-Id: I1e262e62fecd0c01528d07170b8f115ba7fecd5e
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19101
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years ago[IOT-2101] Don't automatically assert roles accessing DOXM
Kevin Kane [Mon, 24 Apr 2017 21:11:17 +0000 (14:11 -0700)]
[IOT-2101] Don't automatically assert roles accessing DOXM

During OTM, the DOXM resource is accessed while the SSL lock is
held. Attempting to assert roles causes this lock to be acquired
again, and recursive locking is not supported. Therefore, don't
automatically assert roles when accessing DOXM. Since this
resource seems to only be accessed either anonymously or with an
owner PSK, this shouldn't be needed, anyway.

Change-Id: I4b04d24544a5049d3a91827753d565e118cbf9d5
Signed-off-by: Kevin Kane <kkane@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19237
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Alex Kelley <alexke@microsoft.com>
Reviewed-by: Way Vadhanasin <wayvad@microsoft.com>
Reviewed-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
7 years agoDon't call CA API from sample app.
Dan Mihai [Fri, 14 Apr 2017 19:11:47 +0000 (12:11 -0700)]
Don't call CA API from sample app.

Add OC API wrapper for CASelectCipherSuite.

Change-Id: I473847399eeeca86efc3679848280c4c4419b194
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19023
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agosecurity: Remove unused OicSecSecl structure
Philippe Coval [Mon, 10 Apr 2017 23:19:22 +0000 (08:19 +0900)]
security: Remove unused OicSecSecl structure

Note, the type Id is still present in emu

Change-Id: Ib1c537fb2b96794a5cfb36ebd80ba193a99dfb5d
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18665
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
(cherry picked from commit cf1ff9ac226836509475712208855120617ac3ac)
Reviewed-on: https://gerrit.iotivity.org/gerrit/19219

7 years ago[IOT-2027] Linux: use static octbstack library for tests
Dan Mihai [Tue, 11 Apr 2017 14:37:28 +0000 (07:37 -0700)]
[IOT-2027] Linux: use static octbstack library for tests

Change-Id: I57f3afe1a23bf51d2acbae2bfe27fdd7fa53c1f7
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18823
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoSupport different LIBS for product and unit test
Dan Mihai [Wed, 19 Apr 2017 13:45:48 +0000 (06:45 -0700)]
Support different LIBS for product and unit test

Move the provisioning/SConscript part that applies to product code
into provisioning/src/. That allows provisioning/src/ and
provisioning/unitest/ to link with a different set of LIBS.

The set of LIBs did not change yet. That change is coming up in a
future patch.

Change-Id: I9741db9730971d4567c971985111acfd0aa101f9
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19143
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoDon't use CA thread pool in sample app
Dan Mihai [Sat, 15 Apr 2017 01:14:12 +0000 (18:14 -0700)]
Don't use CA thread pool in sample app

The CA thread pool APIs are not intended to be Public.

Change-Id: Ic212c453c82e639be9f611b4b16a712054475de6
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18987
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoandroid: Use octimer from common lib
Philippe Coval [Thu, 13 Apr 2017 08:19:34 +0000 (17:19 +0900)]
android: Use octimer from common lib

As "extlibs/timer" has been integrated into internal common lib,
It should not be used anymore

Bug: https://jira.iotivity.org/browse/IOT-1889
Change-Id: I458f1a8051c2db742d6fbc46ff7550a7fa962f71
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18903
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Rick Bell <richard.s.bell@intel.com>
7 years agoAdd missing exports from ocpayload.h.
Todd Malsbary [Thu, 20 Apr 2017 18:40:14 +0000 (11:40 -0700)]
Add missing exports from ocpayload.h.

Change-Id: I2dfc580ed736776dfc30efe9991d22d37732c2a4
Signed-off-by: Todd Malsbary <todd.malsbary@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19177
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
7 years agoIOT-1994 Simplify OCStack public header file requirements
Way Vadhanasin [Fri, 14 Apr 2017 14:47:47 +0000 (07:47 -0700)]
IOT-1994 Simplify OCStack public header file requirements

Applications that need to include ocstack.h for access to OC* APIs currently need to bring in
multiple unrelated (and platform-specific) headers. This is because octypes.h, a public type
definition header used by ocstack.h, is including more headers than it needs to. It is more
desirable for applications to bring in only requird headers.

This change reduces the number of required headers from the public surface, specifically ocstack.h,
by taking advantange of IoTivity's requirement that all supported compilers are at least
C++11-compliant. See https://wiki.iotivity.org/compiler_support?s[]=compiler for details.

Before this change, users of ocstack.h must also bring in (this example is from Windows):

    Ocstack.h
    Octypes.h
    Iotivity_config.h
    Ocpresence.h
    Ocstackconfig.h
    Platform_features.h
    Windows\include\memmem.h
    Windows\include\pthread_create.h
    Windows\include\vs12_snprintf.h
    Windows\include\win_sleep.h

After this change, the list becomes:

    Ocstack.h
    Octypes.h
    Ocpresence.h
    Ocstackconfig.h

Arguably ocpresence.h and ocstackconfig.h could be combined into octypes.h since they are just
simple type definitions, just like octypes.h. That work is lower priority as both ocpresence.h
and ocstackconfig.h are already platform independent.

Change-Id: I9943589603453730446b2d616b497fbb235774a5
Signed-off-by: Way Vadhanasin <wayvad@microsoft.com>
(cherry picked from commit 140b6c46e2fc6c6ef896bd9ddac9b190bc9e6fd7)
Reviewed-on: https://gerrit.iotivity.org/gerrit/18869
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Mats Wichmann <mats@linux.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
7 years agoIoT-1516: Return error when WSARecvMsg() fails.
Soemin Tjong [Mon, 17 Apr 2017 23:11:29 +0000 (16:11 -0700)]
IoT-1516: Return error when WSARecvMsg() fails.

https://jira.iotivity.org/browse/IOT-1516?

Change-Id: I5c16b47c9a462ac0b8d9f47cfaea89a5f84baeeb
Signed-off-by: Soemin Tjong <stjong@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19021
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
7 years agoAdd missing OCGetPersistentStorageHandler export.
Todd Malsbary [Thu, 20 Apr 2017 18:38:49 +0000 (11:38 -0700)]
Add missing OCGetPersistentStorageHandler export.

Change-Id: Ie152c247ad7b824fc854376d5d5c8b1e1ab70aab
Signed-off-by: Todd Malsbary <todd.malsbary@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19175
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
7 years ago[IOT-2090] Linux: Fix the link order of c_common and logger
Dan Mihai [Thu, 20 Apr 2017 01:53:58 +0000 (18:53 -0700)]
[IOT-2090] Linux: Fix the link order of c_common and logger

Don't prepend logger after c_common has been prepended, because the
linker wants c_common followed by logger in its command line.

Change-Id: I6cc0c6bfdb2d7e47609d98db8be42fc9e878b1ba
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19145
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoLinking against version of libcoap in favor of the version in extlibs.
Ziran Sun [Tue, 18 Apr 2017 12:55:22 +0000 (13:55 +0100)]
Linking against version of libcoap in favor of the version in extlibs.

Bug: https://jira.iotivity.org/browse/IOT-2055
Change-Id: I3ca9b87ab33aeeb18607c582f2bdccfaa18b3d2f
Signed-off-by: Ziran Sun <ziran.sun@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19063
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
7 years ago[IOT-2053] Discoverable & Secure SVRs
Nathan Heldt-Sheller [Fri, 21 Apr 2017 18:28:46 +0000 (11:28 -0700)]
[IOT-2053] Discoverable & Secure SVRs

Implements CR1616 which requires all SVRs to be marked "Discoverable",
and also to expose a Secure Endpoint.

Change-Id: I0cae25b0ac83ac194fd03ed45245bcb9afc98eeb
Signed-off-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19201
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years agoWindows: Remove octbstack_static.lib
Dan Mihai [Thu, 20 Apr 2017 16:28:27 +0000 (09:28 -0700)]
Windows: Remove octbstack_static.lib

octbstack_static.lib was identical to octbstack_internal.lib.

IoTivity sample apps and apps outside IoTivity are using
octbstack.lib, so they don't need octbstack_internal.lib.

Change-Id: I6ffef4ba6ee1ea90e852c707a6c58a7f8e93c1f9
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19163
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoRename octbstack_test
Dan Mihai [Thu, 20 Apr 2017 16:07:18 +0000 (09:07 -0700)]
Rename octbstack_test

Rename octbstack_test to octbstack_internal - consistent with other
*_internal LIBS.

Change-Id: Id9a4ee7642e5f06f7172b5ee8794a537fb7de547
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19161
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoMinor SConscript clean-up
Dan Mihai [Wed, 19 Apr 2017 05:34:43 +0000 (22:34 -0700)]
Minor SConscript clean-up

Reduce the redundancy between the sets of LIBS for Darwin and
Windows, in preparation for more significant changes.

Change-Id: I4aaed0527e62857127058c3b09e91da816c3f1c4
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19111
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agobuild: Use whereis instead of which
Philippe Coval [Wed, 29 Mar 2017 12:46:54 +0000 (14:46 +0200)]
build: Use whereis instead of which

This was needed for Tizen

Change-Id: I0273e51b9faccbb5ddc86959935654676890e7c6
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18853
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
7 years agotizen: Use tag and not upstream branch
Philippe Coval [Wed, 19 Oct 2016 18:09:52 +0000 (20:09 +0200)]
tizen: Use tag and not upstream branch

Change-Id: Ib45d37341fe326d42e9bdd8a81a6d479623fd8c0
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/13463
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
(cherry picked from commit 011113fe0236d3473c17c071aeb98dc75cdeb317)
Reviewed-on: https://gerrit.iotivity.org/gerrit/19053
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Mats Wichmann <mats@linux.com>
7 years agoModify cloud dashboard for sign-up
Minji Park [Mon, 17 Apr 2017 11:16:36 +0000 (20:16 +0900)]
Modify cloud dashboard for sign-up

- change sign-up page to insert oauth provider manually
- sign-out bug fixed

Change-Id: Ie9bd0bae006a1cdc7bfabd5686e51da15c9d22d5
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19025
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
(cherry picked from commit de0208f8b65281318d5382e1c50b1021b589c3a5)
Reviewed-on: https://gerrit.iotivity.org/gerrit/19045

7 years agostatistical defects fixed
Jung Seungho [Mon, 17 Apr 2017 08:12:10 +0000 (17:12 +0900)]
statistical defects fixed

Change-Id: Id600550ead3fc240e6d266c945650792754dba21
Signed-off-by: Jung Seungho <shonest.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19047
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years ago[IOT-1958] CR 22 State Specific Property Access for /pstat Resource
Nathan Heldt-Sheller [Sun, 16 Apr 2017 06:57:57 +0000 (23:57 -0700)]
[IOT-1958] CR 22 State Specific Property Access for /pstat Resource

Implementation of CR 22 feature to deny UPDATE to /pstat if any
Property in the POST representation is read-only in the current
/pstat.dos.s state.

Includes necessary update to the CBOR marshalling code to support
partial Resource representations for /pstat.

Includes updates to provisioning tools to correctly include only the
/pstat Properties being updated in the POST payload.

This same change must be implemented for each SVR.

- patch set 2&3: rebased
- patch set 4: fixed a few comments and trigger jenkins
- patch set 5&6: rebased
- patch set 7: addressed Greg's review comments

Change-Id: Ie86fcc1edf4b2370ffcb755c78f1289252dcb516
Signed-off-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18989
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years agotizen: Build easy-setup sample app package
Philippe Coval [Thu, 20 Apr 2017 07:01:36 +0000 (09:01 +0200)]
tizen: Build easy-setup sample app package

Bug: https://jira.iotivity.org/browse/IOT-2026
Change-Id: I2c7531d7412f02f26bb5d2d57b9771f0be3d64a8
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19159
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2050] Fix insecure port while posting owner ACL
Dmitriy Zhuravlev [Fri, 14 Apr 2017 15:59:20 +0000 (18:59 +0300)]
[IOT-2050] Fix insecure port while posting owner ACL

Endpoint port changed to secure port

Change-Id: If392847cc463f3f104f41198858752b50a4a3034
Signed-off-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19037
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Andrii Shtompel <a.shtompel@samsung.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
7 years agoAdd check secure port info from EndPoints for Provisioning manager.
Ziran Sun [Fri, 7 Apr 2017 15:09:52 +0000 (16:09 +0100)]
Add check secure port info from EndPoints for Provisioning manager.

With OCF1.0 in place, secure and port are removed from policy schema.
These information are now available in EndPoints. Add support for this.
Otherwise provision discovery fails for format vnd_cbor.

Bug: https://jira.iotivity.org/browse/IOT-1987
Change-Id: I999aca98c6e7c5ba16dc1c63e7348c977daf8924
Signed-off-by: Ziran Sun <ziran.sun@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18605
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
(cherry picked from commit 6eb82077e7b85dc4fd9778967aff562f3a2824e7)
Reviewed-on: https://gerrit.iotivity.org/gerrit/19121
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoModify RE cache callback function.
KIM JungYong [Wed, 19 Apr 2017 05:29:51 +0000 (14:29 +0900)]
Modify RE cache callback function.

https://jira.iotivity.org/browse/IOT-2093

RE cache callback was not report error and error code

In this patch,
1. RE cache callback was changed to call on error including error code.
  std::function< void(const RCSResourceAttributes& attrs, int eCode) >
  CacheUpdatedCallback;
2. Related unit test and sample was updated.
3. Related other service was updated.

Change-Id: Iafb16d3025c491c45e70bbe347ce72b61a82aae2
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19109
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoResource: Change default vaule of acceptVersion and acceptFormat.
Ziran Sun [Fri, 14 Apr 2017 08:39:39 +0000 (09:39 +0100)]
Resource: Change default vaule of acceptVersion and acceptFormat.

Change-Id: Ic63cb9217c9a10b3e38ecd244d12b9cfc552d4ad
Signed-off-by: Ziran Sun <ziran.sun@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19061
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Todd Malsbary <todd.malsbary@intel.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years ago[IOT-2058] Close doubled secure session
Dmitriy Zhuravlev [Tue, 18 Apr 2017 13:36:32 +0000 (16:36 +0300)]
[IOT-2058] Close doubled secure session

Add checking whether secure session exists before creating new

Change-Id: Ia4c36f6257b01c1d81baf1082eba6d7fcd0e83f2
Signed-off-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19071
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Andrii Shtompel <a.shtompel@samsung.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years ago[IOT-2045] Fix PIN based OTM
Dmitriy Zhuravlev [Thu, 13 Apr 2017 15:10:56 +0000 (18:10 +0300)]
[IOT-2045] Fix PIN based OTM

OTM should be able to use PSK ciphersuite
even if there is no credentials in SVR DB

Change-Id: Icfde495b61f5f726cab2604fd5fc0f5e9e88fff9
Signed-off-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18929
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
(cherry picked from commit e133089b764270a24861c7241e3df956df6a74ff)
Reviewed-on: https://gerrit.iotivity.org/gerrit/19039
Reviewed-by: Andrii Shtompel <a.shtompel@samsung.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years agosecurity: Add unused member to empty struct
Philippe Coval [Fri, 24 Mar 2017 01:56:14 +0000 (02:56 +0100)]
security: Add unused member to empty struct

For clang support just like MSVC

Change-Id: I2afbaae260318874634dd42d2650a87c0731e099
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18331
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
(cherry picked from commit 61667f7dc436f0bf3feb789233897ce2a6a49f11)
Reviewed-on: https://gerrit.iotivity.org/gerrit/18859
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoFix a defect detected by static code analyzer
Jaewook Jung [Fri, 14 Apr 2017 05:12:35 +0000 (14:12 +0900)]
Fix a defect detected by static code analyzer

 - remove a unreachable code
 - add a NULL checking before strcmp()

Change-Id: I459e1ab232d10affd0c0e8b1cbea340ca11fb9a2
Signed-off-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18967
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoFix cloud\aclid.c build break
Dan Mihai [Tue, 18 Apr 2017 22:45:18 +0000 (15:45 -0700)]
Fix cloud\aclid.c build break

aclid.c
cacommonutil.h(40): error C2220: warning treated as error -
no 'object' filegenerated
cacommonutil.h(40): warning C4005: 'VERIFY_TRUE': macro redefinition
srmutility.h(72): note: see previous definition of 'VERIFY_TRUE'

Change-Id: Ic629cc9fc5ed074032d9a0a455d9ae4be7312142
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19085
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Omar Maabreh <omarm@microsoft.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoWindows: Start building provisiontests
Dan Mihai [Wed, 12 Apr 2017 01:08:17 +0000 (18:08 -0700)]
Windows: Start building provisiontests

Change-Id: I7200fb8b61cb02f2be0b25e1a663c8ec456919f6
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18781
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years ago[IOT-2012] Windows: rename ocpmapi.lib
Dan Mihai [Tue, 11 Apr 2017 12:35:01 +0000 (05:35 -0700)]
[IOT-2012] Windows: rename ocpmapi.lib

Windows exports ocpmapi APIs from octbstack.dll. IoTivity sample apps
and apps outside IoTivity should link with import library octbstack.lib
rather than the static library ocpmapi.lib. To expose possible
incorrect linking with ocpmapi.lib, rename it to ocpmapi_internal.lib
on Windows.

Change-Id: Ieec1abc65651c3b69674acc7419c87f8ef50d3a4
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18777
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years ago[IOT-1763] CR 32 Device Onboarding State implementation
Nathan Heldt-Sheller [Fri, 14 Apr 2017 04:20:09 +0000 (21:20 -0700)]
[IOT-1763] CR 32 Device Onboarding State implementation

Implementation of CR 32 "Device Offboarding and Soft Reset".

Note that there are a handful of minor updates still to be
done after the provisioning tool is fully updated, but this
can be done during QA cycle after merge to 1.3-rel. See [IOT-2023].

Note also that the unit tests are not written yet; however,
the critical onboarding path from RFOTM->RFPRO->RFNOP has been
verified using the provisioning tool sample app. See [IOT-2024].

patch set 2,3: rebase
patch set 4,5: address review comments
patch set 6,7: fix jenkins issues
patch set 8: rebase
patch set 9: fix jenkins issues
patch set 10: rebase
patsh set 11: address review comments

Change-Id: I7dc8adb5ad90bd168f3ab485461568b9ab7805e0
Signed-off-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18723
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agobridging: Fix expressions style (to support clang)
Philippe Coval [Fri, 24 Mar 2017 01:56:11 +0000 (02:56 +0100)]
bridging: Fix expressions style (to support clang)

Change-Id: I8e9892f9e370e1bda424b840528079b35830069c
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18891
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ossama Othman <ossama.othman@intel.com>
Reviewed-by: Todd Malsbary <todd.malsbary@intel.com>
7 years agotizen: Use TARGET_ARCH in samples
Philippe Coval [Tue, 18 Apr 2017 12:10:45 +0000 (14:10 +0200)]
tizen: Use TARGET_ARCH in samples

Bug: https://jira.iotivity.org/browse/IOT-2032
Change-Id: I893e8880e5b23d0a6e968244ea21477b1192df01
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19055
Reviewed-by: koushik girijala <g.koushik@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ziran Sun <ziran.sun@samsung.com>
7 years agomake code more stable by change strcpy to strncpy
jinhyuck83.park [Thu, 13 Apr 2017 06:06:58 +0000 (15:06 +0900)]
make code more stable by change strcpy to strncpy
and prevent memory leak by dereferencing allocated object.

Change-Id: Ief21c5a5f9e6f016a9a88948729d636bff3d7650
Signed-off-by: jinhyuck83.park <jinhyuck83.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18881
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
7 years ago[IOT-1949] De-duplicate roles posted to /oic/sec/roles
Greg Zaverucha [Fri, 7 Apr 2017 00:52:16 +0000 (17:52 -0700)]
[IOT-1949] De-duplicate roles posted to /oic/sec/roles

If a role certificate is added a second time to the roles
resource, do not add it again.

Change-Id: Ifce27b93404216fb2bbac5b02aeb414a75f0398c
Signed-off-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18831
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years ago[IOT-1942] Add support for diagnostic payloads.
Todd Malsbary [Tue, 11 Apr 2017 18:42:10 +0000 (11:42 -0700)]
[IOT-1942] Add support for diagnostic payloads.

Bug: https://jira.iotivity.org/browse/IOT-1942
Change-Id: Ia4d761bfc49d646b2e1514844826411df272d5a4
Signed-off-by: Todd Malsbary <todd.malsbary@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18721
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
7 years ago[IOT-2057] Tizen enrollee sample app fix.
Senthil Kumar G S [Tue, 18 Apr 2017 12:17:19 +0000 (17:47 +0530)]
[IOT-2057] Tizen enrollee sample app fix.

Change-Id: Ie22a8c4564acf32dbc6096c7aaeb35f2f7bccd63
Signed-off-by: Senthil Kumar G S <senthil.gs@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19057
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoEnable scene manager unit test on build time.
KIM JungYong [Tue, 18 Apr 2017 05:44:32 +0000 (14:44 +0900)]
Enable scene manager unit test on build time.

Scene manager unit test was blocked before,
in this patch, scene manager unit test was enabled on build time.

Change-Id: I239209f1154f08caab1088ccf3b23c2b5e0ba732
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19041
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoSupport secure network info in CAGetNetworkInformation
hyuna0213.jo [Tue, 18 Apr 2017 09:34:57 +0000 (18:34 +0900)]
Support secure network info in CAGetNetworkInformation

Secured network interface information should be provided

Change-Id: I2fd73fa23759d27e694d81d208aca451cd989fc6
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18969
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
(cherry picked from commit 852a9136741d22948b05146db93c30ba7ec6f98c)
Reviewed-on: https://gerrit.iotivity.org/gerrit/19051
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-1952] Assert roles automatically
Greg Zaverucha [Wed, 5 Apr 2017 19:05:06 +0000 (12:05 -0700)]
[IOT-1952] Assert roles automatically

- Change OCDoRequest to assert role certificates before the first
secure request to a server.

- Move role assertion code out of provisioning to security, so that
ocstack can call it without including all provisioning code. Create
a public API for asserting role certificates OCAssertRoles. Role
assertion code is in new files ocsecurity.c/h

- Revise scenario tests accordingly.

Other changes in this commit:
- Rename a macro "OPTIONAL" in cloud samples since this is defined
in a standard Windows header and causing a build break.

- Fix the --onetest command line option to provisioningTest.py

Change-Id: I915d321bfff0bfd00add3298b07865b0963d9f14
Signed-off-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18833
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
7 years agoextlibs: Use patch as fallback and trap errors
Philippe Coval [Wed, 22 Mar 2017 08:27:25 +0000 (09:27 +0100)]
extlibs: Use patch as fallback and trap errors

This will be helpful for Tizen and others OS.

If lib is bundled as "imported git patch"
then application of "duplicated ocf.patch as git patch",
is not needed anymore, and relies on scons.

To Tizen maintainers:
From now on let's maintain only one version in tree,
ealier versions of git patches can be reverted,
For reference check:
https://wiki.iotivity.org/tizen#maintenance_tips

Bug: https://jira.iotivity.org/browse/IOT-1745
Change-Id: I0598ddd5c846a2286218879d57381ec2f20c17a4
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18661
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ziran Sun <ziran.sun@samsung.com>
7 years agotizen: Enable BT for Tizen:2.4 by default
Philippe Coval [Wed, 12 Apr 2017 07:42:50 +0000 (16:42 +0900)]
tizen: Enable BT for Tizen:2.4 by default

It was reported that BT got disabled for Tizen:2.4,
after investigation it appeared that Tizen:2.4 is defined as tizen=2.3
https://build.tizen.org/project/show?project=Tizen%3A2.4%3AMobile

So instead BT is disabled for Tizen:2.2 (defined as tizen=2.1)
https://build.tizen.org/project/prjconf?project=Tizen%3A2.2%3ABase

Bug: https://jira.iotivity.org/browse/IOT-2030
Change-Id: I0ebd08f383c396d913cdbd89801131b544534d23
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18811
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Ziran Sun <ziran.sun@samsung.com>
7 years agoFix build fail on notification with MQ.
KIM JungYong [Tue, 18 Apr 2017 03:59:27 +0000 (12:59 +0900)]
Fix build fail on notification with MQ.

When building of notificaiton with MQ, build failed
because related API call invalid(removed) function.

in this patch, removed function was changed.

Change-Id: Ib97a5c966f4bd8907bfecbfd1463340574c2063c
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/19031
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoUpdate tizen build for multiple ownership
m.parves [Sun, 9 Apr 2017 01:02:26 +0000 (07:02 +0600)]
Update tizen build for multiple ownership

1. Add parameter for multiple owner in iotivity.spec
2. Pass this parameter value to scons from spec

Bug: https://jira.iotivity.org/browse/IOT-2009

Change-Id: Idc39544911674ace14fd5ec8169413cd517a14e9
Signed-off-by: m.parves <m.parves@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18683
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Mushfiqul Islam <i.mushfiq@samsung.com>
Reviewed-by: Randeep Singh <randeep.s@samsung.com>
7 years ago[IOT-2011] linker changes for oc_logger
Dan Mihai [Fri, 7 Apr 2017 20:29:14 +0000 (13:29 -0700)]
[IOT-2011] linker changes for oc_logger

Windows currently has several different copies of oc_logger code and
data in a single process. Other platforms are using a single copy of
shared library oc_logger, in each process/app.

It's better to avoid differences across platforms, because otherwise
changes tested on one platform might not work on the other platforms.

Linker behavior unchanged by this patch:
----------------------------------------

1. On non-Windows platforms: IoTivity sample apps, and apps outside
   IoTivity, link with oc_logger.

2. On Windows: IoTivity sample apps, and apps outside IoTivity,
   continue to link with octbstack.lib.

Linker behavior changed by this patch:
----------------------------------------

1. On all platforms: IoTivity internal tests link with the static LIB
   oc_logger_internal.

2. On Windows: IoTivity sample apps, and apps outside IoTivity,
   no longer link directly with oc_logger.lib. They obtain access to
   oc_logger APIs by linking with octbstack.lib.

3. On Windows: Octbstack.dll links with the static LIB
   oc_logger_internal, and exports public oc_logger APIs.

Change-Id: I3ca36ffcbebea7822918998ac3fced1c5071726e
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18769
Reviewed-by: Todd Malsbary <todd.malsbary@intel.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
7 years ago[IOT-2013] Windows: export C RD APIs from octbstack.dll
Dan Mihai [Mon, 10 Apr 2017 23:57:41 +0000 (16:57 -0700)]
[IOT-2013] Windows: export C RD APIs from octbstack.dll

Windows currently has several different copies of the implementation
for these APIs. Other platforms are using a single copy of shared
library resource_directory, in each process/app.

It's better to avoid differences across platforms, because otherwise
changes tested on one platform might not work on the other platforms.

Note that the C++ APIs for resource_directory clients remain inside
the static resource_directory.lib, so there can be multiple copies of
the C++ API implementation in each Windows process.

Change-Id: I07683359c265989d9921cd28da6ccd83d30f06af
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18775
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
7 years ago[IOT-1986] Windows: Workaround race condition linking with oc_logger.lib
Soemin Tjong [Thu, 13 Apr 2017 19:23:08 +0000 (12:23 -0700)]
[IOT-1986] Windows: Workaround race condition linking with oc_logger.lib

Temporary solution for similar issue as described in:
https://gerrit.iotivity.org/gerrit/#/c/18767/

Change-Id: Ib02c0e77b3700aed89111ce95e131db121e7acdd
Signed-off-by: Soemin Tjong <stjong@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18937
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
7 years agoFix a defect detected by static code analyzer.
Jaehong Jo [Fri, 14 Apr 2017 02:06:03 +0000 (11:06 +0900)]
Fix a defect detected by static code analyzer.

Add null check and remove strcpy in
oic_malloc_tests.cpp, ocstack.c, oickeepalive.c

Change-Id: I7303374ce2ff6ee68ab01e844dbef4dd46a4cf1a
Signed-off-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18953
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
7 years agoFix a defect detected by static code analyzer
Jaewook Jung [Fri, 14 Apr 2017 02:34:00 +0000 (11:34 +0900)]
Fix a defect detected by static code analyzer

Because the size of the struct CAEndpoint_t is 184 bytes,
it is better to pass a pointer of it if call-by-value is not
necessary.

Change-Id: I680cb11ba6ad18613370a76333002d7784a23178
Signed-off-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18955
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: jaehyun Cho <jaehyun3.cho@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoFix a defect detected by static code analyzer
Jaewook Jung [Thu, 13 Apr 2017 05:55:15 +0000 (14:55 +0900)]
Fix a defect detected by static code analyzer

unsigned int is always greater than or equal to zero.

Change-Id: I2aa83c4a224e5bbaf22882ccb131161850dcee57
Signed-off-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18879
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agotizen: Use octimer from common lib
Philippe Coval [Wed, 12 Apr 2017 07:44:54 +0000 (16:44 +0900)]
tizen: Use octimer from common lib

Change-Id: I09c24097a319dd390d6cc99488cd88c603acc21c
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18887
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoFix for double free in RE cache unit test.
KIM JungYong [Thu, 13 Apr 2017 07:05:28 +0000 (16:05 +0900)]
Fix for double free in RE cache unit test.

[Problem]
When RE cache unit test is terminated,
always will crash af double free.

[Reason]
double freed valiable is shared pointer of mock object.
this pointer will remove twice on release of mock object and shared pointer.

[Fix]
Deleter as non-operation was added on the creation of shared pointer.

Change-Id: I6434795fd011312b1a9bcb5ecf0d092aab19b487
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18893
Reviewed-by: Jay Sharma <jay.sharma@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoRemove some properties in oic.r.devconf resource
Jihun Ha [Wed, 12 Apr 2017 10:49:52 +0000 (19:49 +0900)]
Remove some properties in oic.r.devconf resource

Problem:
 Some of properties in oic.r.devconf resource has a duplicated meaning with
other existing resource's one like oic.wk.con and oic.wk.p. For OCF spec,
such a duplication should be avoided as possible.

Way to resolve:
All properties EXCEPT device name("dn") property are removed.
Later, some properties can be defined in oic.r.devconf with spec update.

Change-Id: I935b3d46773aa97a846335ad36f4f866269e05d0
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18793
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agofix unsafe functions(strcpy, sprintf)
bg.chun [Fri, 14 Apr 2017 04:11:54 +0000 (13:11 +0900)]
fix unsafe functions(strcpy, sprintf)

fix strcpy -> strncpy
fix sprinrf -> snprintf

Change-Id: Ic228e3735fe3b329ec3116a393406892d0f127e2
Signed-off-by: bg.chun <bg.chun@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18961
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Jaewook Jung <jw0213.jung@samsung.com>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoRemove unused dependencies to RD LIB
Dan Mihai [Mon, 10 Apr 2017 15:02:30 +0000 (08:02 -0700)]
Remove unused dependencies to RD LIB

Change-Id: Id40c4b20433ad5e514657495ffac17fee6df61db
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18773
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Todd Malsbary <todd.malsbary@intel.com>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
7 years ago[IOT-2035] Build jni code before samples
George Nash [Thu, 13 Apr 2017 22:11:42 +0000 (15:11 -0700)]
[IOT-2035] Build jni code before samples

Changed tabs to spaces to match with conventions
used elsewhere.

Change-Id: Ic5cfb104b0dd224d8bb88118f66d5ea1370ab2ad
Signed-off-by: George Nash <george.nash@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18941
Reviewed-by: Larry Sachs <larry.j.sachs@intel.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Rick Bell <richard.s.bell@intel.com>
7 years ago[IOT-2034] Updating Enrollee sample app for Tizen
Jay Sharma [Thu, 13 Apr 2017 14:09:57 +0000 (19:39 +0530)]
[IOT-2034] Updating Enrollee sample app for Tizen

Change-Id: I06468c436db5a883f747772841413a1afef9d23a
Signed-off-by: Harish Kumar Marappa <h.marappa@samsung.com>
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18921
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoFix for JIRA IOT-2044.
Senthil Kumar G S [Thu, 13 Apr 2017 15:00:51 +0000 (20:30 +0530)]
Fix for JIRA IOT-2044.

Handled "GetStringUTFChars received NULL jstring" error

Change-Id: I67aecab98e496ec715e634246d4ee32efc44aa8b
Signed-off-by: Senthil Kumar G S <senthil.gs@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18927
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agotizen: Set parallelize build up to (nproc / 2)
Philippe Coval [Wed, 12 Apr 2017 23:05:21 +0000 (08:05 +0900)]
tizen: Set parallelize build up to (nproc / 2)

Some systems faced internal compiler errors when overloaded

Bug: https://jira.iotivity.org/browse/IOT-2026
Change-Id: I898a76d894ec63a7945ec3ea668a0095b7fb2468
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18905
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2008] Wrapping OCGetLinkLocalZoneId by ifdef IP_ADAPTER
bg.chun [Fri, 7 Apr 2017 02:25:33 +0000 (11:25 +0900)]
[IOT-2008] Wrapping OCGetLinkLocalZoneId by ifdef IP_ADAPTER

Wrapping OCGetLinkLocalZoneId by ifdef IP_ADAPTER
because real implementation located on ca ipadapter.
It makes BLE only stack build fail.

Change-Id: Ifd2ccaa0ba3ea62967186a69c670694f2b5d5d81
Signed-off-by: bg.chun <bg.chun@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18965
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years ago[RI] Tizen Csdk sample build fix for 32 bit machine
Veeraj Khokale [Thu, 13 Apr 2017 10:50:05 +0000 (16:20 +0530)]
[RI] Tizen Csdk sample build fix for 32 bit machine

Tizen Csdk sample build fix for 32 bit machine

Change-Id: I73a1a6866a17bb1eff7f797e6dd361a2b9bfd583
Signed-off-by: koushik.girijala <g.koushik@samsung.com>
Signed-off-by: Veeraj Khokale <veeraj.sk@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18915
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoFix a sconscript for enrollee unit test
Jihun Ha [Thu, 13 Apr 2017 11:03:47 +0000 (20:03 +0900)]
Fix a sconscript for enrollee unit test

Add a line for enabling unittest for enrollee

Change-Id: Ia1e88d4a17f0a69d09cf65da8368b5af24c1686f
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18695
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2016][IOT-1623] UUID check and use MBEDTLS_MD_MAX_SIZE
Greg Zaverucha [Mon, 10 Apr 2017 20:05:24 +0000 (13:05 -0700)]
[IOT-2016][IOT-1623] UUID check and use MBEDTLS_MD_MAX_SIZE

Use MBEDTLS_MD_MAX_SIZE for buffer lengths in pHash.
Don't allow wildcard UUID in CSRs

Change-Id: Ifad48945250087d8dc92fb346cfc986f68888352
Signed-off-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18829
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
7 years ago[IOT-2037] Resolved android crash
Randeep Singh [Thu, 13 Apr 2017 08:43:33 +0000 (14:13 +0530)]
[IOT-2037] Resolved android crash

Change-Id: I9c54cc3fea321ad2f5b657eb0784ef707070dace
Signed-off-by: Randeep Singh <randeep.s@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18895
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Senthil Kumar G S <senthil.gs@samsung.com>
Reviewed-by: George Nash <george.nash@intel.com>
Reviewed-by: Larry Sachs <larry.j.sachs@intel.com>
Reviewed-by: Rick Bell <richard.s.bell@intel.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2034] Fix for Tizen Enrollee sample build issue.
Jay Sharma [Thu, 13 Apr 2017 14:59:43 +0000 (20:29 +0530)]
[IOT-2034] Fix for Tizen Enrollee sample build issue.

Change-Id: I40f6e2ee5ffa91fdc4b746a94ecd35d07e5fa6d9
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Signed-off-by: Harish Kumar Marappa <h.marappa@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18925
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2033] Update simple base app to enable BLE Advertisement by default.
jihwan.seo [Thu, 13 Apr 2017 10:20:56 +0000 (19:20 +0900)]
[IOT-2033] Update simple base app to enable BLE Advertisement by default.

Change-Id: I382ecdbd7cdcc2f60da3e5f6389c786f8d6ebc9f
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18909
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2010] Move PMGenerateQuery export to octbstack_product_secured.def
Alex Kelley [Fri, 7 Apr 2017 20:02:07 +0000 (13:02 -0700)]
[IOT-2010] Move PMGenerateQuery export to octbstack_product_secured.def

Change-Id: I8033841aa2217978fbb04cf0ae3494b93bb64f72
Signed-off-by: Alex Kelley <alexke@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18625
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
(cherry picked from commit fb7c36315b96a1bb8cd2f1fe03c6c66ee0b89eac)
Reviewed-on: https://gerrit.iotivity.org/gerrit/18825

7 years ago[IOT-1986] Windows: Work around SCons race condition
Dan Mihai [Fri, 7 Apr 2017 04:39:48 +0000 (21:39 -0700)]
[IOT-1986] Windows: Work around SCons race condition

These sporadic linker errors become even more frequent when adding
more static LIBs into a single target DLL.

Change-Id: I44d2cfeda61a08cbc29cb3d7f685b87ea1cb8b9e
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18767
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Omar Maabreh <omarm@microsoft.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
7 years agoIOT-1583: Fixing libcoap W4 warnings.
Pawel Winogrodzki [Mon, 3 Apr 2017 23:14:33 +0000 (16:14 -0700)]
IOT-1583: Fixing libcoap W4 warnings.

This commit makes sure libcoap doesn't generate any W4
warnings when building with for Windows.

In addition to that automatic libcoap updates are enabled
by default for Jenkins builds and optional for regular
builds.

Change-Id: I676a98bd41c2aeb28fee7d5ed1283145fd306655
Signed-off-by: Pawel Winogrodzki <pawelwi@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18545
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
(cherry picked from commit d3b382c901ee304d4f3466fa33758f5510fdf9d4)
Reviewed-on: https://gerrit.iotivity.org/gerrit/18755
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
7 years agoModified getNetAddress() in SceneUtils
ChaJiWon [Wed, 12 Apr 2017 12:12:46 +0000 (21:12 +0900)]
Modified getNetAddress() in SceneUtils

If network have IPv4 address, it returns IPv4 address.

Change-Id: Iba93339b6a980251194b02d6fa905006a88a0608
Signed-off-by: ChaJiWon <jw_wonny.cha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18675
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoFix bugs for invalid uri in notificaiton service.
KIM JungYong [Thu, 13 Apr 2017 06:15:12 +0000 (15:15 +0900)]
Fix bugs for invalid uri in notificaiton service.

[Problem]
Notification service sync service does not working.

[Reason]
When notification service built with TEST=0 (by default),
Sync resource uri was registered as invalid.

[Fix]
Divided sync resource uri for test, was combined.

Change-Id: I979fd8169afc15cf747796894d98a1be9e9ef853
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18885
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years agoProxy samples: Add support for running with security
Veeraj Khokale [Thu, 23 Mar 2017 06:52:09 +0000 (12:22 +0530)]
Proxy samples: Add support for running with security

1. Add Persistent Storage Handlers in proxy_main.c
   and proxy_client.c.
2. Add svr db files in coap proxy samples directory and
   use them in proxy_client and proxy_main for security
   credentials and ACLs.
3. Include OC_SECURE flag while initiating proxy request
   from client.

Change-Id: Iec7ea2f3a30c2777b86064e3726db25587176c21
Signed-off-by: Veeraj Khokale <veeraj.sk@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18797
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
7 years ago[Resource-Encapsulation] Removed Linux Secured samples.
Jay Sharma [Wed, 12 Apr 2017 07:31:18 +0000 (13:01 +0530)]
[Resource-Encapsulation] Removed Linux Secured samples.

Change-Id: I5c83435c91e669100f52bdf546df6ecbf32f12f7
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18783
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-2029] split scons builder code out of external_libs.scons
George Nash [Tue, 11 Apr 2017 20:23:54 +0000 (13:23 -0700)]
[IOT-2029] split scons builder code out of external_libs.scons

This splits the contents of the external_libs.scons into two
files:
   external_builders.scons
   external_libs.scons

The external_libs.scons script added scons  Psuedo-Builders
'PrepareLib', 'Download', 'UnpackAll', 'Configure',
'InstallHeadFile' and 'InstalLib' to the scons environment
The builder scripts are responsible for downloading, unpacking,
and installing different items throughout the build process.

Additionally the external_libs.scons was also responsible for
building and setting up compilar flags and building external
libraries.

The external_libs.scons used to be called before and after the
android build. Once to setup the Psuedo-Builders and again to
set the compiler flags for the external libraries. Due to some
cleanup for a recent change. The script can no longer be called
multiple times without a scons error.

see: https://gerrit.iotivity.org/gerrit/#/c/18381

Now the Psuedo-Builders are added to the scons environment by
calling external_builders.scons. The external_libs.scons is
used to build the external libraries.

This allows adding the builders that are required for the
android build. While still setting up the build environment
for the external libraries.

Due to the UnpackAll builder using the system path on windows
the external_builders.scons script must be called twice.

Additional Whitespace cleanup changed tabs into spaces to follow
convention of other scons scripts.

Change-Id: I070224425bfd2d4279cd6c9b0c329e393250770a
Signed-off-by: George Nash <george.nash@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18739
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
7 years agoProxy Service: Fix broken build.
Abhishek Sharma [Tue, 21 Mar 2017 09:51:37 +0000 (15:21 +0530)]
Proxy Service: Fix broken build.

Fixed Proxy service build issues.

Change-Id: Ib49bc0e9943d2e967a8373f170e3ecba3a237020
Signed-off-by: Abhishek Sharma <ce.abhishek@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18791
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years ago[Resource-Encapsulation] Fixes for Android and Tizen platform
Jay Sharma [Wed, 12 Apr 2017 04:40:40 +0000 (10:10 +0530)]
[Resource-Encapsulation] Fixes for Android and Tizen platform

   - Java SDK build fix.
   - Android sample Apps fix.
   - Tizen sample Apps fix.

Change-Id: Id9a2e636b2253bfed585cfcfdb9fbd2f7ca1ee75
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18779
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoChange a coap cloud server address to sign-up and sign-in
Jihun Ha [Tue, 11 Apr 2017 08:35:36 +0000 (17:35 +0900)]
Change a coap cloud server address to sign-up and sign-in

An address of coap cloud server for testing is changed to 13.124.29.169.
And an access token issued by github has no expiry time so refreshtoken
is not used anymore.

Change-Id: Ib8ef89bc075114374dd345b79f7205ec99918c7d
Signed-off-by: Jihun Ha <jihun.ha@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18687
Reviewed-by: Heewon Park <h_w.park@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years ago[IOT-1996] Make resource/csdk/connectivity W4 compliant.
Alex Kelley [Mon, 27 Mar 2017 16:38:24 +0000 (09:38 -0700)]
[IOT-1996] Make resource/csdk/connectivity W4 compliant.

These changes include the following:
- Fix W4 warnings under resource/csdk/connectivity.
- Fix W4 warnings under resource/csdk/connectivity/test.
- Enable /W4 /WX on resource/csdk/connectivity.
- Enable /W4 /WX on resource/csdk/connectivity/test.
- Update build_common/Windows/SConscript.

Change-Id: I98d93f4df6fc938f004ef2f6844ba120bb5e788a
Signed-off-by: Alex Kelley <alexke@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18535
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
(cherry picked from commit 7a811cc5b6ba90a99ada4a86da1632367a52304c)
Reviewed-on: https://gerrit.iotivity.org/gerrit/18749
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
7 years agoSet request timeout to EXCHANGE_LIFETIME of CoAP.
Soemin Tjong [Thu, 6 Apr 2017 22:28:59 +0000 (15:28 -0700)]
Set request timeout to EXCHANGE_LIFETIME of CoAP.

EXCHANGE_LIFETIME value is 247 seconds.

Change-Id: I95b896e8459200fbd1a02598ea1537c96a8eccef
Signed-off-by: Soemin Tjong <stjong@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18591
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Way Vadhanasin <wayvad@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
(cherry picked from commit b024d2ee727fddedc2d6290dfcb5c49433e30523)
Reviewed-on: https://gerrit.iotivity.org/gerrit/18835
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
7 years agohippomocks: Update to latest release (v5.0)
Philippe Coval [Fri, 24 Mar 2017 10:20:01 +0000 (11:20 +0100)]
hippomocks: Update to latest release (v5.0)

Refactor build scripts too

Previously we used revision:
8e210c5808d490b26fff69151c801fa28d291fcb

Since upstream tagged a version, so it's safer to align to it.

Bug: https://jira.iotivity.org/browse/IOT-1745
Change-Id: Ib6674b60f70dbae163feea447273324bf7827d6d
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18365
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: C.J. Collier <cjcollier@linuxfoundation.org>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
7 years agoMerge "Merge branch 'cloud-interface'"
Jee Hyeok Kim [Mon, 10 Apr 2017 10:03:43 +0000 (10:03 +0000)]
Merge "Merge branch 'cloud-interface'"

7 years agoCreate links OCRepPayloadValue for collection resource
uzchoi [Mon, 27 Mar 2017 12:41:29 +0000 (21:41 +0900)]
Create links OCRepPayloadValue for collection resource

By adding the payload definition includes links parameter in linklist
interface for collection. Server application developer should implement
it to comply to OCF specification, but this requires lots of coding work
with holding the policy map info and so on.

This API returns back links parameter which can be set as response
payload for linklist request for collection.
OCRepPayloadValue created by this function has following struct in depth.

 OCRepPayloadValue.arr->objArray[] as each resource links payload
   ..objArray[]->values->obj as policyMap

Patch10 include tcp, tls port in the policy map.
relocate code into occollection.c to better cohesion

Change-Id: I399c5b6e40d0a00f43e106619cdc17ac480ed985
Reviewed-on: https://gerrit.iotivity.org/gerrit/18195
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
7 years agoMerge branch 'cloud-interface'
Jee Hyeok Kim [Fri, 7 Apr 2017 06:05:51 +0000 (15:05 +0900)]
Merge branch 'cloud-interface'

Change-Id: I4560ca5c7cb12782701051e72cca9ec014c14587
Signed-off-by: Jee Hyeok Kim <jihyeok13.kim@samsung.com>
7 years agoFix build break from bad merge
Kevin Kane [Fri, 7 Apr 2017 17:59:39 +0000 (10:59 -0700)]
Fix build break from bad merge

Change-Id: I37004fce7b941bf7ecd37e77defa481974c0bac4
Signed-off-by: Kevin Kane <kkane@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18615
Reviewed-by: Alex Kelley <alexke@microsoft.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
Tested-by: Greg Zaverucha <gregz@microsoft.com>
7 years ago[IOT-1992] Bug in the ocf.patch
ol.beketov [Thu, 6 Apr 2017 12:13:24 +0000 (15:13 +0300)]
[IOT-1992] Bug in the ocf.patch

Bug in the ocf.patch while adding
TLS_ECDH_anon_WITH_AES_128_CBC_SHA
suite to the library(in ssl_cli.c)

Change-Id: I1f97c096e1f67f3b65e44d915ba8b9f115bee586
Signed-off-by: ol.beketov <ol.beketov@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18439
Reviewed-by: Dmitriy Zhuravlev <d.zhuravlev@samsung.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years ago[IOT-1950] Add default ACL for roles resource
Greg Zaverucha [Wed, 29 Mar 2017 22:25:09 +0000 (15:25 -0700)]
[IOT-1950] Add default ACL for roles resource

Update the default ACL to include access to the roles resource.
Fix double-free on error paths in GetDefaultACL.
Update .json/.dat files for samples and unit tests containing the default ACL.
Remove workaround from end-to-end tests.
Add unit test to check default ACL includes ACE for roles resource.

Change-Id: Icff8e64195f1ce75ad6e3b05c8e2de1763eaf653
Signed-off-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18465
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Alex Kelley <alexke@microsoft.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
7 years ago[IOT-2005] Correct PEM encoding of test certs in SSL tests
Kevin Kane [Thu, 6 Apr 2017 16:57:03 +0000 (09:57 -0700)]
[IOT-2005] Correct PEM encoding of test certs in SSL tests

mbedTLS insists on newlines in PEM data, and the lack thereof is
causing SSL adapter tests to fail. Add newlines to the test certs
for correct parsing.

Change-Id: I5c42dbd648bf111ac00f746d4e59fc4a9a224208
Signed-off-by: Kevin Kane <kkane@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18575
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Alex Kelley <alexke@microsoft.com>
Reviewed-by: Way Vadhanasin <wayvad@microsoft.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
7 years ago[IOT-1785] Implement roles from symmetric pair-wise keys
Kevin Kane [Wed, 29 Mar 2017 20:26:01 +0000 (13:26 -0700)]
[IOT-1785] Implement roles from symmetric pair-wise keys

Implement roleId property of an oic.sec.cred object.

Fix error path bugs in CRED<->CBOR code to fail properly if
certain serialization subroutines fail; error codes were
being ignored. Fix error path memory leaks.

Also fix the ACL/ACL2<->CBOR code to use the correct JSON
field names per the schema. Fix error path memory leaks.

Change-Id: Ie9aa8baba5903c482acb3adc6ef617a1ced7db31
Signed-off-by: Kevin Kane <kkane@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18463
Reviewed-by: Alex Kelley <alexke@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
7 years agoRemove uses of WITH_X509
Greg Zaverucha [Thu, 6 Apr 2017 21:32:35 +0000 (14:32 -0700)]
Remove uses of WITH_X509

GetCredEntryByCredId was using WITH_X509 instead of WITH_DTLS,
causing a block of code to not be included in certain build
configurations.

Change-Id: I16c05f38c7d2e317a727d6480289151e30229d71
Signed-off-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/18581
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Reviewed-by: Alex Kelley <alexke@microsoft.com>
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>