diff --git a/distribution/emm-community/pom.xml b/distribution/emm-community/pom.xml new file mode 100644 index 0000000..034e5c5 --- /dev/null +++ b/distribution/emm-community/pom.xml @@ -0,0 +1,70 @@ + + + + + + + io.entgra.community + distribution + 5.0.0-SNAPSHOT + ../pom.xml + + + 4.0.0 + entgra-emm-community + pom + Entgra EMM - Community Distribution + Entgra EMM Community Distribution + + + + + org.apache.maven.plugins + maven-assembly-plugin + + + 2-dist + package + + single + + + false + UTF-8 + + ${basedir}/src/assembly/filter.properties + + \ + + ${basedir}/src/assembly/bin.xml + + + 0775 + 0775 + 0644 + 0644 + + + + + + + + + diff --git a/distribution/emm-community/src/assembly/bin.xml b/distribution/emm-community/src/assembly/bin.xml new file mode 100644 index 0000000..204d8b7 --- /dev/null +++ b/distribution/emm-community/src/assembly/bin.xml @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + ]> + + bin + + zip + + false + + + + ../../p2-profile/emm/target/${entgra-iot-core} + ${entgra-emm-community} + + **/repository/conf/deployment.toml + + + + + + + src/conf/deployment.toml + ${entgra-emm-community}/repository/conf/ + + + + diff --git a/distribution/emm-community/src/assembly/filter.properties b/distribution/emm-community/src/assembly/filter.properties new file mode 100644 index 0000000..e69de29 diff --git a/distribution/emm-community/src/conf/deployment.toml b/distribution/emm-community/src/conf/deployment.toml new file mode 100644 index 0000000..8473704 --- /dev/null +++ b/distribution/emm-community/src/conf/deployment.toml @@ -0,0 +1,311 @@ +[server] +hostname = "localhost" +#offset=0 +base_path = "${carbon.protocol}://${carbon.host}:${carbon.management.port}" +#discard_empty_caches = false +server_role = "default" + +[database_configuration] +enable_h2_console = "true" + +[super_admin] +username = "admin" +password = "admin" +create_admin_account = true + +[user_store] +type = "database_unique_id" + +[database.apim_db] +type = "h2" +url = "jdbc:h2:./repository/database/WSO2AM_DB;AUTO_SERVER=TRUE;DB_CLOSE_ON_EXIT=FALSE" +username = "wso2carbon" +password = "wso2carbon" + +[database.shared_db] +type = "h2" +url = "jdbc:h2:./repository/database/WSO2SHARED_DB;DB_CLOSE_ON_EXIT=FALSE" +username = "wso2carbon" +password = "wso2carbon" + +[keystore.tls] +file_name = "wso2carbon.jks" +type = "JKS" +password = "wso2carbon" +alias = "wso2carbon" +key_password = "wso2carbon" + +#[keystore.primary] +#file_name = "wso2carbon.jks" +#type = "JKS" +#password = "wso2carbon" +#alias = "wso2carbon" +#key_password = "wso2carbon" + +#[keystore.internal] +#file_name = "wso2carbon.jks" +#type = "JKS" +#password = "wso2carbon" +#alias = "wso2carbon" +#key_password = "wso2carbon" + +[[apim.gateway.environment]] +name = "Default" +type = "hybrid" +display_in_api_console = true +description = "This is a hybrid gateway that handles both production and sandbox token traffic." +show_as_token_endpoint_url = true +service_url = "https://localhost:${mgt.transport.https.port}/services/" +username= "${admin.username}" +password= "${admin.password}" +ws_endpoint = "ws://localhost:9099" +wss_endpoint = "wss://localhost:8099" +http_endpoint = "http://localhost:${http.nio.port}" +https_endpoint = "https://localhost:${https.nio.port}" +websub_event_receiver_http_endpoint = "http://localhost:9021" +websub_event_receiver_https_endpoint = "https://localhost:8021" + +[apim.sync_runtime_artifacts.gateway] +gateway_labels =["Default"] + +#[apim.cache.gateway_token] +#enable = true +#expiry_time = "900s" + +#[apim.cache.resource] +#enable = true +#expiry_time = "900s" + +#[apim.cache.km_token] +#enable = false +#expiry_time = "15m" + +#[apim.cache.recent_apis] +#enable = false + +#[apim.cache.scopes] +#enable = true + +#[apim.cache.publisher_roles] +#enable = true + +#[apim.cache.jwt_claim] +#enable = true +#expiry_time = "15m" + +#[apim.cache.tags] +#expiry_time = "2m" + +[apim.analytics] +enable = false +config_endpoint = "https://localhost:8080/auth/v1" +auth_token = "" + +#[apim.key_manager] +#service_url = "https://localhost:${mgt.transport.https.port}/services/" +#username = "$ref{super_admin.username}" +#password = "$ref{super_admin.password}" +#pool.init_idle_capacity = 50 +#pool.max_idle = 100 +#key_validation_handler_type = "default" +#key_validation_handler_type = "custom" +#key_validation_handler_impl = "org.wso2.carbon.apimgt.keymgt.handlers.DefaultKeyValidationHandler" + +#[apim.idp] +#server_url = "https://localhost:${mgt.transport.https.port}" +#authorize_endpoint = "https://localhost:${mgt.transport.https.port}/oauth2/authorize" +#oidc_logout_endpoint = "https://localhost:${mgt.transport.https.port}/oidc/logout" +#oidc_check_session_endpoint = "https://localhost:${mgt.transport.https.port}/oidc/checksession" + +#[apim.jwt] +#enable = true +#encoding = "base64" # base64,base64url +#generator_impl = "org.wso2.carbon.apimgt.keymgt.token.JWTGenerator" +#claim_dialect = "http://wso2.org/claims" +#convert_dialect = false +#header = "X-JWT-Assertion" +#signing_algorithm = "SHA256withRSA" +#enable_user_claims = true +#claims_extractor_impl = "org.wso2.carbon.apimgt.impl.token.ExtendedDefaultClaimsRetriever" + +[apim.oauth_config] +# ------------------Enabled for IOT/EMM --------------------------- +enable_outbound_auth_header = true +#auth_header = "Authorization" +#revoke_endpoint = "https://localhost:${https.nio.port}/revoke" +#enable_token_encryption = false +#enable_token_hashing = false + +#[apim.devportal] +#url = "https://localhost:${mgt.transport.https.port}/devportal" +#enable_application_sharing = false +#if application_sharing_type, application_sharing_impl both defined priority goes to application_sharing_impl +#application_sharing_type = "default" #changed type, saml, default #todo: check the new config for rest api +#application_sharing_impl = "org.wso2.carbon.apimgt.impl.SAMLGroupIDExtractorImpl" +#display_multiple_versions = false +#display_deprecated_apis = false +#enable_comments = true +#enable_ratings = true +#enable_forum = true +#enable_anonymous_mode=true +#enable_cross_tenant_subscriptions = true +#default_reserved_username = "apim_reserved_user" + +[apim.cors] +allow_origins = "*" +allow_methods = ["GET","PUT","POST","DELETE","PATCH","OPTIONS"] +allow_headers = ["authorization","Access-Control-Allow-Origin","Content-Type","SOAPAction","apikey","Internal-Key"] +allow_credentials = false + +#[apim.throttling] +#enable_data_publishing = true +#enable_policy_deploy = true +#enable_blacklist_condition = true +#enable_persistence = true +#throttle_decision_endpoints = ["tcp://localhost:5672","tcp://localhost:5672"] + +#[apim.throttling.blacklist_condition] +#start_delay = "5m" +#period = "1h" + +#[apim.throttling.jms] +#start_delay = "5m" + +#[apim.throttling.event_sync] +#hostName = "0.0.0.0" +#port = 11224 + +#[apim.throttling.event_management] +#hostName = "0.0.0.0" +#port = 10005 + +#[[apim.throttling.url_group]] +#traffic_manager_urls = ["tcp://localhost:9611","tcp://localhost:9611"] +#traffic_manager_auth_urls = ["ssl://localhost:9711","ssl://localhost:9711"] +#type = "loadbalance" + +#[[apim.throttling.url_group]] +#traffic_manager_urls = ["tcp://localhost:9611","tcp://localhost:9611"] +#traffic_manager_auth_urls = ["ssl://localhost:9711","ssl://localhost:9711"] +#type = "failover" + +#[apim.workflow] +#enable = false +#service_url = "https://localhost:9445/bpmn" +#username = "$ref{super_admin.username}" +#password = "$ref{super_admin.password}" +#callback_endpoint = "https://localhost:${mgt.transport.https.port}/api/am/admin/v0.17/workflows/update-workflow-status" +#token_endpoint = "https://localhost:${https.nio.port}/token" +#client_registration_endpoint = "https://localhost:${mgt.transport.https.port}/client-registration/v0.17/register" +#client_registration_username = "$ref{super_admin.username}" +#client_registration_password = "$ref{super_admin.password}" + +#data bridge config +#[transport.receiver] +#type = "binary" +#worker_threads = 10 +#session_timeout = "30m" +#keystore.file_name = "$ref{keystore.tls.file_name}" +#keystore.password = "$ref{keystore.tls.password}" +#tcp_port = 9611 +#ssl_port = 9711 +#ssl_receiver_thread_pool_size = 100 +#tcp_receiver_thread_pool_size = 100 +#ssl_enabled_protocols = ["TLSv1","TLSv1.1","TLSv1.2"] +#ciphers = ["SSL_RSA_WITH_RC4_128_MD5","SSL_RSA_WITH_RC4_128_SHA"] + +#[apim.notification] +#from_address = "APIM.com" +#username = "APIM" +#password = "APIM+123" +#hostname = "localhost" +#port = 3025 +#enable_start_tls = false +#enable_authentication = true + +#[apim.token.revocation] +#notifier_impl = "org.wso2.carbon.apimgt.keymgt.events.TokenRevocationNotifierImpl" +#enable_realtime_notifier = true +#realtime_notifier.ttl = 5000 +#enable_persistent_notifier = true +#persistent_notifier.hostname = "https://localhost:2379/v2/keys/jti/" +#persistent_notifier.ttl = 5000 +#persistent_notifier.username = "root" +#persistent_notifier.password = "root" + +[[event_handler]] +name="userPostSelfRegistration" +subscriptions=["POST_ADD_USER"] + +[service_provider] +sp_name_regex = "^[\\sa-zA-Z0-9._-]*$" + +[database.local] +url = "jdbc:h2:./repository/database/WSO2CARBON_DB;DB_CLOSE_ON_EXIT=FALSE" + +[[event_listener]] +id = "token_revocation" +type = "org.wso2.carbon.identity.core.handler.AbstractIdentityHandler" +name = "org.wso2.is.notification.ApimOauthEventInterceptor" +order = 1 +[event_listener.properties] +notification_endpoint = "https://localhost:${mgt.transport.https.port}/internal/data/v1/notify" +username = "${admin.username}" +password = "${admin.password}" +'header.X-WSO2-KEY-MANAGER' = "default" + +#------------- Adding below configurations which are coming from APIM, to avoid replacing by IOT/EMM configurations ---- +[[resource.access_control]] +context="(.*)/keymanager-operations/user-info/claims(.*)" +secure="true" +http_method="GET" +permissions="/permission/admin/manage/identity/usermgt/list" +scopes="internal_user_mgt_list" + +[[resource.access_control]] +context="(.*)/keymanager-operations/user-info/claims/generate" +secure="true" +http_method="POST" +permissions="/permission/admin/manage/identity/usermgt/list" +scopes="internal_user_mgt_list" + +[[resource.access_control]] +context="(.*)/keymanager-operations/dcr/register" +secure="true" +http_method="POST" +permissions="/permission/admin/manage/identity/applicationmgt/create" +scopes="internal_application_mgt_create" + +# ----------------Required for IOT/EMM----------------------- +[[resource.access_control]] +context="(.*)/api/device-mgt/v1.0/(.*)" +secure="true" +http_method="all" + +[[resource.access_control]] +context="(.*)/api-application-registration/(.*)" +secure="true" +http_method="all" + +[[resource.access_control]] +context="(.*)/api/application-mgt-publisher/v1.0/(.*)" +secure="true" +http_method="all" + +[apim.sync_runtime_artifacts.gateway.skip_list] +apis = ["_TokenAPI_.xml", "_API_Application_Registration_.xml", "admin--Android-Mutual-SSL-Configuration-Management.xml", "admin--Android-Mutual-SSL-Device-Management.xml", "admin--Android-Mutual-SSL-Event-Receiver.xml"] +sequences = ["_api_registration_fault_.xml"] + +[transport.https.properties] +maxHttpHeaderSize="16384" + +[transport.http.properties] +maxHttpHeaderSize="16384" + +[oauth.grant_type.jwt_bearer] +grant_handler="org.wso2.carbon.device.mgt.oauth.extensions.handlers.grant.ExtendedJWTGrantHandler" + +[[oauth.custom_grant_type]] +name="access_token" +grant_handler="org.wso2.carbon.device.mgt.oauth.extensions.handlers.grant.AccessTokenGrantHandler" +grant_validator="org.wso2.carbon.device.mgt.oauth.extensions.validators.AccessTokenGrantValidator" diff --git a/distribution/iot-community/pom.xml b/distribution/iot-community/pom.xml new file mode 100644 index 0000000..b62eb03 --- /dev/null +++ b/distribution/iot-community/pom.xml @@ -0,0 +1,70 @@ + + + + + + + io.entgra.community + distribution + 5.0.0-SNAPSHOT + ../pom.xml + + + 4.0.0 + entgra-iot-community + pom + Entgra IoT - Community Distribution + Entgra IoT Community Distribution + + + + + org.apache.maven.plugins + maven-assembly-plugin + + + 2-dist + package + + single + + + false + UTF-8 + + ${basedir}/src/assembly/filter.properties + + \ + + ${basedir}/src/assembly/bin.xml + + + 0775 + 0775 + 0644 + 0644 + + + + + + + + + diff --git a/distribution/iot-community/src/assembly/bin.xml b/distribution/iot-community/src/assembly/bin.xml new file mode 100644 index 0000000..aaef702 --- /dev/null +++ b/distribution/iot-community/src/assembly/bin.xml @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + ]> + + bin + + zip + + false + + + + ../../p2-profile/iot/target/${entgra-iot-core} + ${entgra-iot-community} + + + + + + src/temp.txt + ${entgra-iot-community}/ + + + + diff --git a/distribution/iot-community/src/assembly/filter.properties b/distribution/iot-community/src/assembly/filter.properties new file mode 100644 index 0000000..e69de29 diff --git a/distribution/iot-community/src/temp.txt b/distribution/iot-community/src/temp.txt new file mode 100644 index 0000000..e69de29 diff --git a/distribution/iot-community/target/.plxarc b/distribution/iot-community/target/.plxarc new file mode 100644 index 0000000..67ea6ee --- /dev/null +++ b/distribution/iot-community/target/.plxarc @@ -0,0 +1 @@ +maven-shared-archive-resources \ No newline at end of file diff --git a/distribution/iot-community/target/maven-shared-archive-resources/META-INF/DEPENDENCIES b/distribution/iot-community/target/maven-shared-archive-resources/META-INF/DEPENDENCIES new file mode 100644 index 0000000..d2ec0aa --- /dev/null +++ b/distribution/iot-community/target/maven-shared-archive-resources/META-INF/DEPENDENCIES @@ -0,0 +1,11 @@ +// ------------------------------------------------------------------ +// Transitive dependencies of this project determined from the +// maven pom organized by organization. +// ------------------------------------------------------------------ + +Entgra IoT - Community Distribution + + + + + diff --git a/distribution/iot-community/target/maven-shared-archive-resources/META-INF/LICENSE b/distribution/iot-community/target/maven-shared-archive-resources/META-INF/LICENSE new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/distribution/iot-community/target/maven-shared-archive-resources/META-INF/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/distribution/iot-community/target/maven-shared-archive-resources/META-INF/NOTICE b/distribution/iot-community/target/maven-shared-archive-resources/META-INF/NOTICE new file mode 100644 index 0000000..1074455 --- /dev/null +++ b/distribution/iot-community/target/maven-shared-archive-resources/META-INF/NOTICE @@ -0,0 +1,8 @@ + +Entgra IoT - Community Distribution +Copyright 2021 WSO2 + +This product includes software developed at +The Apache Software Foundation (http://www.apache.org/). + + diff --git a/distribution/iot-community/target/timestamp b/distribution/iot-community/target/timestamp new file mode 100644 index 0000000..a036c8a Binary files /dev/null and b/distribution/iot-community/target/timestamp differ diff --git a/distribution/pom.xml b/distribution/pom.xml new file mode 100644 index 0000000..41e00d0 --- /dev/null +++ b/distribution/pom.xml @@ -0,0 +1,39 @@ + + + + + + + io.entgra.community + community-parent + 5.0.0-SNAPSHOT + ../pom.xml + + + 4.0.0 + distribution + pom + Entgra IoT - Distribution Module + Entgra IoT Distribution Module + + + iot-community + emm-community + + diff --git a/distribution/target/.plxarc b/distribution/target/.plxarc new file mode 100644 index 0000000..67ea6ee --- /dev/null +++ b/distribution/target/.plxarc @@ -0,0 +1 @@ +maven-shared-archive-resources \ No newline at end of file diff --git a/distribution/target/maven-shared-archive-resources/META-INF/DEPENDENCIES b/distribution/target/maven-shared-archive-resources/META-INF/DEPENDENCIES new file mode 100644 index 0000000..cedd1cd --- /dev/null +++ b/distribution/target/maven-shared-archive-resources/META-INF/DEPENDENCIES @@ -0,0 +1,11 @@ +// ------------------------------------------------------------------ +// Transitive dependencies of this project determined from the +// maven pom organized by organization. +// ------------------------------------------------------------------ + +Entgra IoT - Distribution Module + + + + + diff --git a/distribution/target/maven-shared-archive-resources/META-INF/LICENSE b/distribution/target/maven-shared-archive-resources/META-INF/LICENSE new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/distribution/target/maven-shared-archive-resources/META-INF/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/distribution/target/maven-shared-archive-resources/META-INF/NOTICE b/distribution/target/maven-shared-archive-resources/META-INF/NOTICE new file mode 100644 index 0000000..89b84fa --- /dev/null +++ b/distribution/target/maven-shared-archive-resources/META-INF/NOTICE @@ -0,0 +1,8 @@ + +Entgra IoT - Distribution Module +Copyright 2021 WSO2 + +This product includes software developed at +The Apache Software Foundation (http://www.apache.org/). + + diff --git a/distribution/target/timestamp b/distribution/target/timestamp new file mode 100644 index 0000000..5ff0782 Binary files /dev/null and b/distribution/target/timestamp differ diff --git a/iot-core/pom.xml b/iot-core/pom.xml new file mode 100644 index 0000000..ee3864d --- /dev/null +++ b/iot-core/pom.xml @@ -0,0 +1,430 @@ + + + + + + + io.entgra.community + community-parent + 5.0.0-SNAPSHOT + ../pom.xml + + + 4.0.0 + entgra-iot-core + Entgra IoT Core distribution + pom + + + + com.h2database.wso2 + h2-database-engine + + + org.wso2.carbon.devicemgt + org.wso2.carbon.device.mgt.oauth.extensions + + + + + + + org.apache.maven.plugins + maven-antrun-plugin + + + check-pack + process-resources + + run + + + + + + + + + download-pack + process-resources + + run + + + + + + + + + extract-pack + process-resources + + run + + + + + + + + + + create-device-mgt-schema + package + + run + + + + + + + + + + + + + + + + + + + + + + + create-certificate-mgt-schema + package + + run + + + + + + + + + + + + + + + + + + + + + + + + + org.wso2.maven + carbon-p2-plugin + ${carbon.p2.plugin.version} + + + 2-p2-repo-generation + prepare-package + + p2-repo-gen + + + file:${basedir}/target/p2-repo + file:${basedir}/target/p2-repo + true + true + + + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.extensions.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.policy.mgt.server.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.certificate.mgt.api.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.certificate.mgt.cert.admin.api.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.certificate.mgt.server.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.apimgt.webapp.publisher.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.identity.jwt.client.extension.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.webapp.authenticator.framework.server.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.apimgt.application.extension.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.email.sender.feature:${carbon.device.mgt.version} + + + io.entgra.devicemgt:io.entgra.ui.request.interceptor.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.extensions.device.type.deployer.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.extensions.push.notification.provider.mqtt.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.extensions.push.notification.provider.http.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.extensions.push.notification.provider.fcm.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.extensions.push.notification.provider.xmpp.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:io.entgra.server.heart.beat.feature:${carbon.device.mgt.version} + + + + + + org.wso2.carbon.devicemgt:io.entgra.transport.mgt.sms.handler.server.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:io.entgra.transport.mgt.sms.handler.api.feature:${carbon.device.mgt.version} + + + + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.application.mgt.api.feature:${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.application.mgt.server.feature:${carbon.device.mgt.version} + + + + + + + feature-install + prepare-package + + p2-profile-gen + + + default + file:${basedir}/target/p2-repo + file:${basedir}/target/p2-repo + ${basedir}/target/${wso2am}/repository/components + true + + + + org.wso2.carbon.device.mgt.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.device.mgt.extensions.feature.group + ${carbon.device.mgt.version} + + + + + org.wso2.carbon.device.application.mgt.api.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.device.application.mgt.server.feature.group + ${carbon.device.mgt.version} + + + + + + io.entgra.transport.mgt.sms.handler.server.feature.group + ${carbon.device.mgt.version} + + + io.entgra.transport.mgt.sms.handler.api.feature.group + ${carbon.device.mgt.version} + + + + + + org.wso2.carbon.email.sender.feature.group + ${carbon.device.mgt.version} + + + + + org.wso2.carbon.apimgt.application.extension.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.apimgt.webapp.publisher.feature.group + ${carbon.device.mgt.version} + + + + + org.wso2.carbon.certificate.mgt.server.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.certificate.mgt.api.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.certificate.mgt.cert.admin.api.feature.group + ${carbon.device.mgt.version} + + + + + org.wso2.carbon.device.mgt.extensions.device.type.deployer.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.device.mgt.extensions.push.notification.provider.mqtt.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.device.mgt.extensions.push.notification.provider.http.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.device.mgt.extensions.push.notification.provider.fcm.feature.group + ${carbon.device.mgt.version} + + + org.wso2.carbon.device.mgt.extensions.push.notification.provider.xmpp.feature.group + ${carbon.device.mgt.version} + + + + + io.entgra.server.heart.beat.feature.group + ${carbon.device.mgt.version} + + + + + org.wso2.carbon.identity.jwt.client.extension.feature.group + ${carbon.device.mgt.version} + + + + + org.wso2.carbon.policy.mgt.server.feature.group + ${carbon.device.mgt.version} + + + + + io.entgra.ui.request.interceptor.feature.group + ${carbon.device.mgt.version} + + + + + org.wso2.carbon.webapp.authenticator.framework.server.feature.group + ${carbon.device.mgt.version} + + + + + + + + + + com.google.code.maven-replacer-plugin + replacer + 1.5.3 + + + package + + replace + + + + + + ${basedir}/target/${wso2am}/repository/components/default/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info + + + + false + true + + + + + + org.apache.maven.plugins + maven-assembly-plugin + + + 2-dist + package + + single + + + false + UTF-8 + + ${basedir}/src/assembly/filter.properties + + \ + + ${basedir}/src/assembly/bin.xml + + + 0775 + 0775 + 0644 + 0644 + + + + + + + + + diff --git a/iot-core/src/assembly/bin.xml b/iot-core/src/assembly/bin.xml new file mode 100644 index 0000000..d3e55ad --- /dev/null +++ b/iot-core/src/assembly/bin.xml @@ -0,0 +1,99 @@ + + + + + + + + + + + + + + + + + + + + + + + + ]> + + bin + + zip + + false + + + + ${basedir}/target/${wso2am} + ${entgra-iot-core} + + **/repository/conf/tomcat/context.xml + **/repository/conf/deployment.toml + + + + src/core/synapse-configs/default/api + ${entgra-iot-core}/repository/deployment/server/synapse-configs/default/api + + + src/core/conf/tomcat + ${entgra-iot-core}/repository/conf/tomcat + + + src/core/bin + ${entgra-iot-core}/bin + 755 + + + src/core/resources + ${entgra-iot-core}/repository/deployment/server/webapps/authenticationendpoint + + + src/core/resources + ${entgra-iot-core}/repository/deployment/server/webapps/accountrecoveryendpoint + + + + + + src/core/conf/deployment.toml + ${entgra-iot-core}/repository/conf/ + + + + + + ${entgra-iot-core}/repository/components/dropins + + org.wso2.carbon.devicemgt:org.wso2.carbon.device.mgt.oauth.extensions + + + + + + + diff --git a/iot-core/src/assembly/filter.propeties b/iot-core/src/assembly/filter.propeties new file mode 100644 index 0000000..e69de29 diff --git a/iot-core/src/core/bin/iot-server.bat b/iot-core/src/core/bin/iot-server.bat new file mode 100755 index 0000000..413fc6a --- /dev/null +++ b/iot-core/src/core/bin/iot-server.bat @@ -0,0 +1,232 @@ +@echo off +REM --------------------------------------------------------------------------- +REM Copyright 2005-2009 WSO2, Inc. http://www.wso2.org +REM +REM Licensed under the Apache License, Version 2.0 (the "License"); +REM you may not use this file except in compliance with the License. +REM You may obtain a copy of the License at +REM +REM http://www.apache.org/licenses/LICENSE-2.0 +REM +REM Unless required by applicable law or agreed to in writing, software +REM distributed under the License is distributed on an "AS IS" BASIS, +REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +REM See the License for the specific language governing permissions and +REM limitations under the License. + +rem --------------------------------------------------------------------------- +rem Main Script for WSO2 Carbon +rem +rem Environment Variable Prequisites +rem +rem CARBON_HOME Home of CARBON installation. If not set I will try +rem to figure it out. +rem +rem JAVA_HOME Must point at your Java Development Kit installation. +rem +rem JAVA_OPTS (Optional) Java runtime options used when the commands +rem is executed. +rem --------------------------------------------------------------------------- + +rem ----- if JAVA_HOME is not set we're not happy ------------------------------ +:checkJava + +if "%JAVA_HOME%" == "" goto noJavaHome +if not exist "%JAVA_HOME%\bin\java.exe" goto noJavaHome +goto checkServer + +:noJavaHome +echo "You must set the JAVA_HOME variable before running CARBON." +goto end + +rem ----- Only set CARBON_HOME if not already set ---------------------------- +:checkServer +setlocal enabledelayedexpansion +rem %~sdp0 is expanded pathname of the current script under NT with spaces in the path removed +if "%CARBON_HOME%"=="" set CARBON_HOME=%~sdp0.. +SET curDrive=%cd:~0,1% +SET wsasDrive=%CARBON_HOME:~0,1% +if not "%curDrive%" == "%wsasDrive%" %wsasDrive%: + +rem find CARBON_HOME if it does not exist due to either an invalid value passed +rem by the user or the %0 problem on Windows 9x +if not exist "%CARBON_HOME%\bin\version.txt" goto noServerHome + +set AXIS2_HOME=%CARBON_HOME% +goto updateClasspath + +:noServerHome +echo CARBON_HOME is set incorrectly or CARBON could not be located. Please set CARBON_HOME. +goto end + +rem ----- update classpath ----------------------------------------------------- +:updateClasspath +cd %CARBON_HOME% +set CARBON_CLASSPATH= +FOR %%C in ("%CARBON_HOME%\bin\*.jar") DO set CARBON_CLASSPATH=!CARBON_CLASSPATH!;".\bin\%%~nC%%~xC" + +set CARBON_CLASSPATH="%JAVA_HOME%\lib\tools.jar";%CARBON_CLASSPATH%; + +FOR %%D in ("%CARBON_HOME%\lib\commons-lang*.jar") DO set CARBON_CLASSPATH=!CARBON_CLASSPATH!;".\lib\%%~nD%%~xD" + +rem ----- Process the input command ------------------------------------------- + +rem Slurp the command line arguments. This loop allows for an unlimited number +rem of arguments (up to the command line limit, anyway). +set originalArgs=%* + +:setupArgs +if ""%1""=="""" goto doneStart + +if ""%1""==""-run"" goto commandLifecycle +if ""%1""==""--run"" goto commandLifecycle +if ""%1""==""run"" goto commandLifecycle + +if ""%1""==""-restart"" goto commandLifecycle +if ""%1""==""--restart"" goto commandLifecycle +if ""%1""==""restart"" goto commandLifecycle + +if ""%1""==""debug"" goto commandDebug +if ""%1""==""-debug"" goto commandDebug +if ""%1""==""--debug"" goto commandDebug + +if ""%1""==""version"" goto commandVersion +if ""%1""==""-version"" goto commandVersion +if ""%1""==""--version"" goto commandVersion + +if ""%1""==""optimize"" goto profileOptimizer +if ""%1""==""-optimize"" goto profileOptimizer +if ""%1""==""--optimize"" goto profileOptimizer + +shift +goto setupArgs + +rem ----- commandVersion ------------------------------------------------------- +:commandVersion +shift +type "%CARBON_HOME%\bin\version.txt" +type "%CARBON_HOME%\bin\wso2carbon-version.txt" +goto end + +rem ----- commandDebug --------------------------------------------------------- +:commandDebug +shift +set DEBUG_PORT=%1 +if "%DEBUG_PORT%"=="" goto noDebugPort +if not "%JAVA_OPTS%"=="" echo Warning !!!. User specified JAVA_OPTS will be ignored, once you give the --debug option. +set JAVA_OPTS=-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=%DEBUG_PORT% +echo Please start the remote debugging client to continue... +goto findJdk + +:noDebugPort +echo Please specify the debug port after the --debug option +goto end + +rem ----- commandLifecycle ----------------------------------------------------- +:commandLifecycle +goto findJdk + +rem ----- profile optimization then start the server--------------------------------- +:profileOptimizer +setlocal enableDelayedExpansion +set found=false +for %%a in (!originalArgs!) do ( + if !found!==true ( + set profile=-Dprofile=%%a + set found=false + ) + if %%a==-Dprofile ( set found=true + ) +) + +for %%a in (!originalArgs!) do ( + if %%a==--skipConfigOptimization ( + set skipConfigOptimizationOption=%%a + goto runProfileSetup + ) + if %%a==-skipConfigOptimization ( + set skipConfigOptimizationOption=%%a + goto runProfileSetup + ) + if %%a==skipConfigOptimization ( + set skipConfigOptimizationOption=%%a + goto runProfileSetup + ) +) + +:runProfileSetup +call bin\profileSetup.bat %profile% %skipConfigOptimizationOption% +endlocal +goto findJdk + +:doneStart +if "%OS%"=="Windows_NT" @setlocal +if "%OS%"=="WINNT" @setlocal + +rem ---------- Handle the SSL Issue with proper JDK version -------------------- +rem find the version of the jdk +:findJdk + +set CMD=RUN %* + +:checkJdk17 +PATH %PATH%;%JAVA_HOME%\bin\ +for /f tokens^=2-5^ delims^=.-_^" %%j in ('java -fullversion 2^>^&1') do set "JAVA_VERSION=%%j%%k" +if %JAVA_VERSION% LSS 17 goto unknownJdk +if %JAVA_VERSION% GTR 110 goto unknownJdk +goto jdk17 + +:unknownJdk +echo Starting WSO2 Carbon (in unsupported JDK) +echo [ERROR] CARBON is supported only on JDK 1.7, 1.8, 9, 10 and 11 +goto jdk17 + +:jdk17 +goto runServer + +rem ----------------- Execute The Requested Command ---------------------------- + +:runServer +cd %CARBON_HOME% + +rem ------------------ Remove tmp folder on startup ----------------------------- +set TMP_DIR=%CARBON_HOME%\tmp +cd "%TMP_DIR%" +del *.* /s /q > nul +FOR /d %%G in ("*.*") DO rmdir %%G /s /q +cd .. + +rem ---------- Add jars to classpath ---------------- + +set CARBON_CLASSPATH=".\lib\*";%CARBON_CLASSPATH% + +if %JAVA_VERSION% GEQ 110 set CARBON_CLASSPATH=".\lib\endorsed\*";%CARBON_CLASSPATH% + +if %JAVA_VERSION% LEQ 18 set JAVA_VER_BASED_OPTS=-Djava.endorsed.dirs=".\lib\endorsed";"%JAVA_HOME%\jre\lib\endorsed";"%JAVA_HOME%\lib\endorsed" +if %JAVA_VERSION% GEQ 110 set JAVA_VER_BASED_OPTS=--add-opens=java.base/java.net=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport=ALL-UNNAMED + +set CMD_LINE_ARGS=-Xbootclasspath/a:%CARBON_XBOOTCLASSPATH% -Xms256m -Xmx1024m -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="%CARBON_HOME%\repository\logs\heap-dump.hprof" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dcom.sun.management.jmxremote -classpath %CARBON_CLASSPATH% %JAVA_OPTS% %JAVA_VER_BASED_OPTS% +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dcarbon.registry.root=/ -Dcarbon.home="%CARBON_HOME%" -Dinstance.log="" -Dwso2.server.standalone=true -Djava.command="%JAVA_HOME%\bin\java" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Djava.opts="%JAVA_OPTS%" -Djava.io.tmpdir="%CARBON_HOME%\tmp" -Dcatalina.base="%CARBON_HOME%\lib\tomcat" -Dwso2.carbon.xml=%CARBON_HOME%\repository\conf\carbon.xml +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dwso2.registry.xml="%CARBON_HOME%\repository\conf\registry.xml" -Dwso2.user.mgt.xml="%CARBON_HOME%\repository\conf\user-mgt.xml" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dwso2.transports.xml="%CARBON_HOME%\repository\conf\mgt-transports.xml" -Djava.util.logging.config.file="%CARBON_HOME%\repository\conf\etc\logging-bridge.properties" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Dcarbon.config.dir.path="%CARBON_HOME%\repository\conf" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dcomponents.repo="%CARBON_HOME%\repository\components" -Dconf.location="%CARBON_HOME%\repository\conf" -Dcom.atomikos.icatch.file="%CARBON_HOME%\lib\transactions.properties" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dcom.atomikos.icatch.hide_init_file_path="true" -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dorg.apache.jasper.runtime.BodyContentImpl.LIMIT_BUFFER=true -Dcom.sun.jndi.ldap.connect.pool.authentication=simple -Dcom.sun.jndi.ldap.connect.pool.timeout=3000 +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dorg.terracotta.quartz.skipUpdateCheck=true -Dcarbon.classpath=%CARBON_CLASSPATH% -Dfile.encoding=UTF8 -DworkerNode=false -Dcarbon.new.config.dir.path="%CARBON_HOME%\repository\resources\conf" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Djava.endorsed.dirs=%JAVA_ENDORSED% -Dorg.opensaml.httpclient.https.disableHostnameVerification=true -Dhttpclient.hostnameVerifier="DefaultAndLocalhost" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Diot.core.host="localhost" -Diot.core.https.port="9443" -Diot.core.http.port="9763" -Diot.gateway.host="localhost" -Diot.gateway.https.port="8243" -Diot.gateway.http.port="8280" -Diot.gateway.carbon.https.port="9443" -Diot.gateway.carbon.http.port="9763" + +:runJava +echo JAVA_HOME environment variable is set to %JAVA_HOME% +echo CARBON_HOME environment variable is set to %CARBON_HOME% +"%JAVA_HOME%\bin\java" %CMD_LINE_ARGS% org.wso2.carbon.bootstrap.Bootstrap %CMD% +if "%ERRORLEVEL%"=="121" goto runJava +:end +goto endlocal + +:endlocal + +:END diff --git a/iot-core/src/core/bin/iot-server.sh b/iot-core/src/core/bin/iot-server.sh new file mode 100755 index 0000000..c569b12 --- /dev/null +++ b/iot-core/src/core/bin/iot-server.sh @@ -0,0 +1,366 @@ +#!/bin/sh +# ---------------------------------------------------------------------------- +# Copyright 2005-2012 WSO2, Inc. http://www.wso2.org +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ---------------------------------------------------------------------------- +# Main Script for the WSO2 Carbon Server +# +# Environment Variable Prequisites +# +# CARBON_HOME Home of WSO2 Carbon installation. If not set I will try +# to figure it out. +# +# JAVA_HOME Must point at your Java Development Kit installation. +# +# JAVA_OPTS (Optional) Java runtime options used when the commands +# is executed. +# +# NOTE: Borrowed generously from Apache Tomcat startup scripts. +# ----------------------------------------------------------------------------- + +# OS specific support. $var _must_ be set to either true or false. +#ulimit -n 100000 + +cygwin=false; +darwin=false; +os400=false; +mingw=false; +case "`uname`" in +CYGWIN*) cygwin=true;; +MINGW*) mingw=true;; +OS400*) os400=true;; +Darwin*) darwin=true + if [ -z "$JAVA_VERSION" ] ; then + JAVA_VERSION="CurrentJDK" + else + echo "Using Java version: $JAVA_VERSION" + fi + if [ -z "$JAVA_HOME" ] ; then + JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/${JAVA_VERSION}/Home + fi + ;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ]; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '.*/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +# Get standard environment variables +PRGDIR=`dirname "$PRG"` + +# Only set CARBON_HOME if not already set +[ -z "$CARBON_HOME" ] && CARBON_HOME=`cd "$PRGDIR/.." ; pwd` + +# Set AXIS2_HOME. Needed for One Click JAR Download +AXIS2_HOME="$CARBON_HOME" + +# For Cygwin, ensure paths are in UNIX format before anything is touched +if $cygwin; then + [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"` + [ -n "$CARBON_HOME" ] && CARBON_HOME=`cygpath --unix "$CARBON_HOME"` + [ -n "$AXIS2_HOME" ] && CARBON_HOME=`cygpath --unix "$CARBON_HOME"` +fi + +# For OS400 +if $os400; then + # Set job priority to standard for interactive (interactive - 6) by using + # the interactive priority - 6, the helper threads that respond to requests + # will be running at the same priority as interactive jobs. + COMMAND='chgjob job('$JOBNAME') runpty(6)' + system $COMMAND + + # Enable multi threading + QIBM_MULTI_THREADED=Y + export QIBM_MULTI_THREADED +fi + +# For Migwn, ensure paths are in UNIX format before anything is touched +if $mingw ; then + [ -n "$CARBON_HOME" ] && + CARBON_HOME="`(cd "$CARBON_HOME"; pwd)`" + [ -n "$JAVA_HOME" ] && + JAVA_HOME="`(cd "$JAVA_HOME"; pwd)`" + [ -n "$AXIS2_HOME" ] && + CARBON_HOME="`(cd "$CARBON_HOME"; pwd)`" + # TODO classpath? +fi + +if [ -z "$JAVACMD" ] ; then + if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD="$JAVA_HOME/jre/sh/java" + else + JAVACMD="$JAVA_HOME/bin/java" + fi + else + JAVACMD=java + fi +fi + +if [ ! -x "$JAVACMD" ] ; then + echo "Error: JAVA_HOME is not defined correctly." + echo " CARBON cannot execute $JAVACMD" + exit 1 +fi + +# if JAVA_HOME is not set we're not happy +if [ -z "$JAVA_HOME" ]; then + echo "You must set the JAVA_HOME variable before running CARBON." + exit 1 +fi + +if [ -e "$CARBON_HOME/wso2carbon.pid" ]; then + PID=`cat "$CARBON_HOME"/wso2carbon.pid` +fi + +# ----- Process the input command ---------------------------------------------- +args="" +for c in $* +do + if [ "$c" = "--debug" ] || [ "$c" = "-debug" ] || [ "$c" = "debug" ]; then + CMD="--debug" + continue + elif [ "$CMD" = "--debug" ]; then + if [ -z "$PORT" ]; then + PORT=$c + fi + elif [ "$c" = "--stop" ] || [ "$c" = "-stop" ] || [ "$c" = "stop" ]; then + CMD="stop" + elif [ "$c" = "--start" ] || [ "$c" = "-start" ] || [ "$c" = "start" ]; then + CMD="start" + elif [ "$c" = "--version" ] || [ "$c" = "-version" ] || [ "$c" = "version" ]; then + CMD="version" + elif [ "$c" = "--restart" ] || [ "$c" = "-restart" ] || [ "$c" = "restart" ]; then + CMD="restart" + elif [ "$c" = "--test" ] || [ "$c" = "-test" ] || [ "$c" = "test" ]; then + CMD="test" + elif [ "$c" = "--optimize" ] || [ "$c" = "-optimize" ] || [ "$c" = "optimize" ]; then + for option in $*; do + if [ "$option" = "--skipConfigOptimization" ] || [ "$option" = "-skipConfigOptimization" ] || + [ "$option" = "skipConfigOptimization" ]; then + passedSkipConfigOptimizationOption=true + echo "Passed skipConfigOptimization Option: $passedSkipConfigOptimizationOption" + fi + done + + for profile in $*; do + case "$profile" in + *Dprofile=*) + cd $(dirname "$0") + if [ "$passedSkipConfigOptimizationOption" = true ]; then + sh profileSetup.sh $profile --skipConfigOptimization + else + sh profileSetup.sh $profile + fi + echo "Starting the server..." + ;; + esac + done + else + args="$args $c" + fi +done + +if [ "$CMD" = "--debug" ]; then + if [ "$PORT" = "" ]; then + echo " Please specify the debug port after the --debug option" + exit 1 + fi + if [ -n "$JAVA_OPTS" ]; then + echo "Warning !!!. User specified JAVA_OPTS will be ignored, once you give the --debug option." + fi + CMD="RUN" + JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=$PORT" + echo "Please start the remote debugging client to continue..." +elif [ "$CMD" = "start" ]; then + if [ -e "$CARBON_HOME/wso2carbon.pid" ]; then + if ps -p $PID > /dev/null ; then + echo "Process is already running" + exit 0 + fi + fi + export CARBON_HOME="$CARBON_HOME" +# using nohup sh to avoid erros in solaris OS.TODO + nohup sh "$CARBON_HOME"/bin/iot-server.sh $args > /dev/null 2>&1 & + exit 0 +elif [ "$CMD" = "stop" ]; then + export CARBON_HOME="$CARBON_HOME" + kill -term `cat "$CARBON_HOME"/wso2carbon.pid` + exit 0 +elif [ "$CMD" = "restart" ]; then + export CARBON_HOME="$CARBON_HOME" + kill -term `cat "$CARBON_HOME"/wso2carbon.pid` + process_status=0 + pid=`cat "$CARBON_HOME"/wso2carbon.pid` + while [ "$process_status" -eq "0" ] + do + sleep 1; + ps -p$pid 2>&1 > /dev/null + process_status=$? + done + +# using nohup sh to avoid erros in solaris OS.TODO + nohup sh "$CARBON_HOME"/bin/iot-server.sh $args > /dev/null 2>&1 & + exit 0 +elif [ "$CMD" = "test" ]; then + JAVACMD="exec "$JAVACMD"" +elif [ "$CMD" = "version" ]; then + cat "$CARBON_HOME"/bin/version.txt + cat "$CARBON_HOME"/bin/wso2carbon-version.txt + exit 0 +fi + +# ---------- Handle the SSL Issue with proper JDK version -------------------- +java_version=$("$JAVACMD" -version 2>&1 | awk -F '"' '/version/ {print $2}') +java_version_formatted=$(echo "$java_version" | awk -F. '{printf("%02d%02d",$1,$2);}') +if [ $java_version_formatted -lt 0107 ] || [ $java_version_formatted -gt 1100 ]; then + echo " Starting WSO2 Carbon (in unsupported JDK)" + echo " [ERROR] CARBON is supported only on JDK 1.7, 1.8, 9, 10 and 11" +fi + +CARBON_XBOOTCLASSPATH="" +for f in "$CARBON_HOME"/lib/xboot/*.jar +do + if [ "$f" != "$CARBON_HOME/lib/xboot/*.jar" ];then + CARBON_XBOOTCLASSPATH="$CARBON_XBOOTCLASSPATH":$f + fi +done + + +CARBON_CLASSPATH="" +if [ -e "$JAVA_HOME/lib/tools.jar" ]; then + CARBON_CLASSPATH="$JAVA_HOME/lib/tools.jar" +fi +for f in "$CARBON_HOME"/bin/*.jar +do + if [ "$f" != "$CARBON_HOME/bin/*.jar" ];then + CARBON_CLASSPATH="$CARBON_CLASSPATH":$f + fi +done +for t in "$CARBON_HOME"/lib/*.jar +do + CARBON_CLASSPATH="$CARBON_CLASSPATH":$t +done +for t in "$CARBON_HOME"/lib/endorsed/*.jar +do + CARBON_CLASSPATH="$CARBON_CLASSPATH":$t +done + + + +# For Cygwin, switch paths to Windows format before running java +if $cygwin; then + JAVA_HOME=`cygpath --absolute --windows "$JAVA_HOME"` + CARBON_HOME=`cygpath --absolute --windows "$CARBON_HOME"` + AXIS2_HOME=`cygpath --absolute --windows "$CARBON_HOME"` + CLASSPATH=`cygpath --path --windows "$CLASSPATH"` + CARBON_CLASSPATH=`cygpath --path --windows "$CARBON_CLASSPATH"` + CARBON_XBOOTCLASSPATH=`cygpath --path --windows "$CARBON_XBOOTCLASSPATH"` +fi + +# ----- Execute The Requested Command ----------------------------------------- + +echo JAVA_HOME environment variable is set to $JAVA_HOME +echo CARBON_HOME environment variable is set to "$CARBON_HOME" + +cd "$CARBON_HOME" + +TMP_DIR="$CARBON_HOME"/tmp +if [ -d "$TMP_DIR" ]; then +rm -rf "$TMP_DIR"/* +fi + +START_EXIT_STATUS=121 +status=$START_EXIT_STATUS + +if [ -z "$JVM_MEM_OPTS" ]; then + java_version=$("$JAVACMD" -version 2>&1 | awk -F '"' '/version/ {print $2}') + JVM_MEM_OPTS="-Xms256m -Xmx1024m" + if [ "$java_version" \< "1.8" ]; then + JVM_MEM_OPTS="$JVM_MEM_OPTS -XX:MaxPermSize=256m" + fi +fi +echo "Using Java memory options: $JVM_MEM_OPTS" + +#To monitor a Carbon server in remote JMX mode on linux host machines, set the below system property. +# -Djava.rmi.server.hostname="your.IP.goes.here" + +JAVA_VER_BASED_OPTS="" + + +if [ $java_version_formatted -ge 1100 ]; then + JAVA_VER_BASED_OPTS="--add-opens=java.base/java.net=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport=ALL-UNNAMED" +fi + +while [ "$status" = "$START_EXIT_STATUS" ] +do + $JAVACMD \ + -Xbootclasspath/a:"$CARBON_XBOOTCLASSPATH" \ + $JVM_MEM_OPTS \ + -XX:+HeapDumpOnOutOfMemoryError \ + -XX:HeapDumpPath="$CARBON_HOME/repository/logs/heap-dump.hprof" \ + $JAVA_OPTS \ + -Dcom.sun.management.jmxremote \ + -classpath "$CARBON_CLASSPATH" \ + $JAVA_VER_BASED_OPTS \ + -Djava.io.tmpdir="$CARBON_HOME/tmp" \ + -Dcatalina.base="$CARBON_HOME/lib/tomcat" \ + -Dwso2.server.standalone=true \ + -Dcarbon.registry.root=/ \ + -Djava.command="$JAVACMD" \ + -Dcarbon.home="$CARBON_HOME" \ + -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager \ + -Dcarbon.config.dir.path="$CARBON_HOME/repository/conf" \ + -Djava.util.logging.config.file="$CARBON_HOME/repository/conf/etc/logging-bridge.properties" \ + -Dcomponents.repo="$CARBON_HOME/repository/components/plugins" \ + -Dconf.location="$CARBON_HOME/repository/conf"\ + -Dcom.atomikos.icatch.file="$CARBON_HOME/lib/transactions.properties" \ + -Dcom.atomikos.icatch.hide_init_file_path=true \ + -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false \ + -Dorg.apache.jasper.runtime.BodyContentImpl.LIMIT_BUFFER=true \ + -Dcom.sun.jndi.ldap.connect.pool.authentication=simple \ + -Dcom.sun.jndi.ldap.connect.pool.timeout=3000 \ + -Dorg.terracotta.quartz.skipUpdateCheck=true \ + -Djava.security.egd=file:/dev/./urandom \ + -Dfile.encoding=UTF8 \ + -Djava.net.preferIPv4Stack=true \ + -Dcom.ibm.cacheLocalHost=true \ + -Dorg.opensaml.httpclient.https.disableHostnameVerification=true \ + -Dhttpclient.hostnameVerifier=AllowAll \ + -DworkerNode=false \ + -DenableCorrelationLogs=false \ + -Dcarbon.new.config.dir.path="$CARBON_HOME/repository/resources/conf" \ + -Djavax.xml.xpath.XPathFactory:http://java.sun.com/jaxp/xpath/dom=net.sf.saxon.xpath.XPathFactoryImpl \ + -Diot.core.host="localhost" \ + -Diot.core.https.port="9443" \ + -Diot.core.http.port="9763" \ + -Diot.gateway.host="localhost" \ + -Diot.gateway.https.port="8243" \ + -Diot.gateway.http.port="8280" \ + -Diot.gateway.carbon.https.port="9443" \ + -Diot.gateway.carbon.http.port="9763" \ + org.wso2.carbon.bootstrap.Bootstrap $* + status=$? +done diff --git a/iot-core/src/core/conf/deployment.toml b/iot-core/src/core/conf/deployment.toml new file mode 100644 index 0000000..4b63f91 --- /dev/null +++ b/iot-core/src/core/conf/deployment.toml @@ -0,0 +1,311 @@ +[server] +hostname = "localhost" +#offset=0 +base_path = "${carbon.protocol}://${carbon.host}:${carbon.management.port}" +#discard_empty_caches = false +server_role = "default" + +[database_configuration] +enable_h2_console = "true" + +[super_admin] +username = "admin" +password = "admin" +create_admin_account = true + +[user_store] +type = "database_unique_id" + +[database.apim_db] +type = "h2" +url = "jdbc:h2:./repository/database/WSO2AM_DB;AUTO_SERVER=TRUE;DB_CLOSE_ON_EXIT=FALSE" +username = "wso2carbon" +password = "wso2carbon" + +[database.shared_db] +type = "h2" +url = "jdbc:h2:./repository/database/WSO2SHARED_DB;DB_CLOSE_ON_EXIT=FALSE" +username = "wso2carbon" +password = "wso2carbon" + +[keystore.tls] +file_name = "wso2carbon.jks" +type = "JKS" +password = "wso2carbon" +alias = "wso2carbon" +key_password = "wso2carbon" + +#[keystore.primary] +#file_name = "wso2carbon.jks" +#type = "JKS" +#password = "wso2carbon" +#alias = "wso2carbon" +#key_password = "wso2carbon" + +#[keystore.internal] +#file_name = "wso2carbon.jks" +#type = "JKS" +#password = "wso2carbon" +#alias = "wso2carbon" +#key_password = "wso2carbon" + +[[apim.gateway.environment]] +name = "Default" +type = "hybrid" +display_in_api_console = true +description = "This is a hybrid gateway that handles both production and sandbox token traffic." +show_as_token_endpoint_url = true +service_url = "https://localhost:${mgt.transport.https.port}/services/" +username= "${admin.username}" +password= "${admin.password}" +ws_endpoint = "ws://localhost:9099" +wss_endpoint = "wss://localhost:8099" +http_endpoint = "http://localhost:${http.nio.port}" +https_endpoint = "https://localhost:${https.nio.port}" +websub_event_receiver_http_endpoint = "http://localhost:9021" +websub_event_receiver_https_endpoint = "https://localhost:8021" + +[apim.sync_runtime_artifacts.gateway] +gateway_labels =["Default"] + +#[apim.cache.gateway_token] +#enable = true +#expiry_time = "900s" + +#[apim.cache.resource] +#enable = true +#expiry_time = "900s" + +#[apim.cache.km_token] +#enable = false +#expiry_time = "15m" + +#[apim.cache.recent_apis] +#enable = false + +#[apim.cache.scopes] +#enable = true + +#[apim.cache.publisher_roles] +#enable = true + +#[apim.cache.jwt_claim] +#enable = true +#expiry_time = "15m" + +#[apim.cache.tags] +#expiry_time = "2m" + +[apim.analytics] +enable = false +config_endpoint = "https://localhost:8080/auth/v1" +auth_token = "" + +#[apim.key_manager] +#service_url = "https://localhost:${mgt.transport.https.port}/services/" +#username = "$ref{super_admin.username}" +#password = "$ref{super_admin.password}" +#pool.init_idle_capacity = 50 +#pool.max_idle = 100 +#key_validation_handler_type = "default" +#key_validation_handler_type = "custom" +#key_validation_handler_impl = "org.wso2.carbon.apimgt.keymgt.handlers.DefaultKeyValidationHandler" + +#[apim.idp] +#server_url = "https://localhost:${mgt.transport.https.port}" +#authorize_endpoint = "https://localhost:${mgt.transport.https.port}/oauth2/authorize" +#oidc_logout_endpoint = "https://localhost:${mgt.transport.https.port}/oidc/logout" +#oidc_check_session_endpoint = "https://localhost:${mgt.transport.https.port}/oidc/checksession" + +#[apim.jwt] +#enable = true +#encoding = "base64" # base64,base64url +#generator_impl = "org.wso2.carbon.apimgt.keymgt.token.JWTGenerator" +#claim_dialect = "http://wso2.org/claims" +#convert_dialect = false +#header = "X-JWT-Assertion" +#signing_algorithm = "SHA256withRSA" +#enable_user_claims = true +#claims_extractor_impl = "org.wso2.carbon.apimgt.impl.token.ExtendedDefaultClaimsRetriever" + +[apim.oauth_config] +# ------------------Enabled for IOT/EMM --------------------------- +enable_outbound_auth_header = true +#auth_header = "Authorization" +#revoke_endpoint = "https://localhost:${https.nio.port}/revoke" +#enable_token_encryption = false +#enable_token_hashing = false + +#[apim.devportal] +#url = "https://localhost:${mgt.transport.https.port}/devportal" +#enable_application_sharing = false +#if application_sharing_type, application_sharing_impl both defined priority goes to application_sharing_impl +#application_sharing_type = "default" #changed type, saml, default #todo: check the new config for rest api +#application_sharing_impl = "org.wso2.carbon.apimgt.impl.SAMLGroupIDExtractorImpl" +#display_multiple_versions = false +#display_deprecated_apis = false +#enable_comments = true +#enable_ratings = true +#enable_forum = true +#enable_anonymous_mode=true +#enable_cross_tenant_subscriptions = true +#default_reserved_username = "apim_reserved_user" + +[apim.cors] +allow_origins = "*" +allow_methods = ["GET","PUT","POST","DELETE","PATCH","OPTIONS"] +allow_headers = ["authorization","Access-Control-Allow-Origin","Content-Type","SOAPAction","apikey","Internal-Key"] +allow_credentials = false + +#[apim.throttling] +#enable_data_publishing = true +#enable_policy_deploy = true +#enable_blacklist_condition = true +#enable_persistence = true +#throttle_decision_endpoints = ["tcp://localhost:5672","tcp://localhost:5672"] + +#[apim.throttling.blacklist_condition] +#start_delay = "5m" +#period = "1h" + +#[apim.throttling.jms] +#start_delay = "5m" + +#[apim.throttling.event_sync] +#hostName = "0.0.0.0" +#port = 11224 + +#[apim.throttling.event_management] +#hostName = "0.0.0.0" +#port = 10005 + +#[[apim.throttling.url_group]] +#traffic_manager_urls = ["tcp://localhost:9611","tcp://localhost:9611"] +#traffic_manager_auth_urls = ["ssl://localhost:9711","ssl://localhost:9711"] +#type = "loadbalance" + +#[[apim.throttling.url_group]] +#traffic_manager_urls = ["tcp://localhost:9611","tcp://localhost:9611"] +#traffic_manager_auth_urls = ["ssl://localhost:9711","ssl://localhost:9711"] +#type = "failover" + +#[apim.workflow] +#enable = false +#service_url = "https://localhost:9445/bpmn" +#username = "$ref{super_admin.username}" +#password = "$ref{super_admin.password}" +#callback_endpoint = "https://localhost:${mgt.transport.https.port}/api/am/admin/v0.17/workflows/update-workflow-status" +#token_endpoint = "https://localhost:${https.nio.port}/token" +#client_registration_endpoint = "https://localhost:${mgt.transport.https.port}/client-registration/v0.17/register" +#client_registration_username = "$ref{super_admin.username}" +#client_registration_password = "$ref{super_admin.password}" + +#data bridge config +#[transport.receiver] +#type = "binary" +#worker_threads = 10 +#session_timeout = "30m" +#keystore.file_name = "$ref{keystore.tls.file_name}" +#keystore.password = "$ref{keystore.tls.password}" +#tcp_port = 9611 +#ssl_port = 9711 +#ssl_receiver_thread_pool_size = 100 +#tcp_receiver_thread_pool_size = 100 +#ssl_enabled_protocols = ["TLSv1","TLSv1.1","TLSv1.2"] +#ciphers = ["SSL_RSA_WITH_RC4_128_MD5","SSL_RSA_WITH_RC4_128_SHA"] + +#[apim.notification] +#from_address = "APIM.com" +#username = "APIM" +#password = "APIM+123" +#hostname = "localhost" +#port = 3025 +#enable_start_tls = false +#enable_authentication = true + +#[apim.token.revocation] +#notifier_impl = "org.wso2.carbon.apimgt.keymgt.events.TokenRevocationNotifierImpl" +#enable_realtime_notifier = true +#realtime_notifier.ttl = 5000 +#enable_persistent_notifier = true +#persistent_notifier.hostname = "https://localhost:2379/v2/keys/jti/" +#persistent_notifier.ttl = 5000 +#persistent_notifier.username = "root" +#persistent_notifier.password = "root" + +[[event_handler]] +name="userPostSelfRegistration" +subscriptions=["POST_ADD_USER"] + +[service_provider] +sp_name_regex = "^[\\sa-zA-Z0-9._-]*$" + +[database.local] +url = "jdbc:h2:./repository/database/WSO2CARBON_DB;DB_CLOSE_ON_EXIT=FALSE" + +[[event_listener]] +id = "token_revocation" +type = "org.wso2.carbon.identity.core.handler.AbstractIdentityHandler" +name = "org.wso2.is.notification.ApimOauthEventInterceptor" +order = 1 +[event_listener.properties] +notification_endpoint = "https://localhost:${mgt.transport.https.port}/internal/data/v1/notify" +username = "${admin.username}" +password = "${admin.password}" +'header.X-WSO2-KEY-MANAGER' = "default" + +#---- Adding below configurations which are coming from APIM, to avoid replacing by IOT/EMM configurations ---- +[[resource.access_control]] +context="(.*)/keymanager-operations/user-info/claims(.*)" +secure="true" +http_method="GET" +permissions="/permission/admin/manage/identity/usermgt/list" +scopes="internal_user_mgt_list" + +[[resource.access_control]] +context="(.*)/keymanager-operations/user-info/claims/generate" +secure="true" +http_method="POST" +permissions="/permission/admin/manage/identity/usermgt/list" +scopes="internal_user_mgt_list" + +[[resource.access_control]] +context="(.*)/keymanager-operations/dcr/register" +secure="true" +http_method="POST" +permissions="/permission/admin/manage/identity/applicationmgt/create" +scopes="internal_application_mgt_create" + +# ----------------Required for IOT/EMM----------------------- +[[resource.access_control]] +context="(.*)/api/device-mgt/v1.0/(.*)" +secure="true" +http_method="all" + +[[resource.access_control]] +context="(.*)/api-application-registration/(.*)" +secure="true" +http_method="all" + +[[resource.access_control]] +context="(.*)/api/application-mgt-publisher/v1.0/(.*)" +secure="true" +http_method="all" + +[apim.sync_runtime_artifacts.gateway.skip_list] +apis = ["_TokenAPI_.xml", "_API_Application_Registration_.xml"] +sequences = ["_api_registration_fault_.xml"] + +[transport.https.properties] +maxHttpHeaderSize="16384" + +[transport.http.properties] +maxHttpHeaderSize="16384" + +[oauth.grant_type.jwt_bearer] +grant_handler="org.wso2.carbon.device.mgt.oauth.extensions.handlers.grant.ExtendedJWTGrantHandler" + +[[oauth.custom_grant_type]] +name="access_token" +grant_handler="org.wso2.carbon.device.mgt.oauth.extensions.handlers.grant.AccessTokenGrantHandler" +grant_validator="org.wso2.carbon.device.mgt.oauth.extensions.validators.AccessTokenGrantValidator" \ No newline at end of file diff --git a/iot-core/src/core/conf/tomcat/context.xml b/iot-core/src/core/conf/tomcat/context.xml new file mode 100644 index 0000000..dcca984 --- /dev/null +++ b/iot-core/src/core/conf/tomcat/context.xml @@ -0,0 +1,75 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/iot-core/src/core/resources/extensions/cookie-policy-content.jsp b/iot-core/src/core/resources/extensions/cookie-policy-content.jsp new file mode 100644 index 0000000..a4f3d05 --- /dev/null +++ b/iot-core/src/core/resources/extensions/cookie-policy-content.jsp @@ -0,0 +1,155 @@ +<%-- + ~ Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. + ~ + ~ WSO2 Inc. licenses this file to you under the Apache License, + ~ Version 2.0 (the "License"); you may not use this file except + ~ in compliance with the License. + ~ You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--%> + + +
+
+
+
+
+
+ +
+
+

+ Entgra IoT Server - Cookie Policy +

+
+
+ <%-- Customizable content. Due to this nature, i18n is not implemented for this section --%> +
+

About Entgra IoT Server

+

Entgra IoT Server is a complete solution that enables device manufacturers and enterprises to connect and manage their devices, build apps, manage events, secure devices and data, and visualize sensor data in a scalable manner. + +

It also offers a complete and secure enterprise mobility management (EMM/MDM) solution that aims to address mobile computing challenges faced by enterprises today. Supporting iOS, Android, and Windows devices, it helps organizations deal with both corporate owned, personally enabled (COPE) and employee-owned devices with the bring your own device (BYOD) concept.

+ +

Entgra IoT Server comes with advanced analytics, enabling users to analyze speed, proximity, and geo-fencing information of devices including details of those in motion and stationary state.

+
+ +

IoT Server uses cookies to provide you with the best user experience, and to securely identify you. You might not be able to access some of the services if you disable cookies.

+
+ +

A browser cookie is a small piece of data that is stored on your device to help websites and mobile apps remember things about you. Other technologies, including Web storage and identifiers associated with your device, may be used for similar purposes. In this policy, we use the term “cookies” to discuss all of these technologies.

+
+

How does IoT Sever process cookies ?

+

IoT Server uses cookies to store and retrieve information on your browser. This information is used to provide a better user experience. Some cookies have the primary purpose of allowing logging in to the system, maintaining sessions, and keeping track of activities you do within the login session.

+

Some cookies used in IoT Server are used to identify you personally. However, the cookie lifetime will end when you log-out ending your session or when your session expires.

+

Some cookies are simply used to give you a more personalised web experience, and these cannot be used to identify you or your activities personally.

+

This Cookie Policy is part of the IoT Server Privacy Policy.

+
+

What does IoT use cookies for ?

+

Cookies are used for two purposes in IoT server

+
    +
  1. Security.
  2. +
  3. Providing a better user experience.
  4. +
+
+

IoT Server uses cookies for the following purposes

+

Preferences

+

IoT Server uses cookies to remember your settings and preferences and to auto-fill the fields to make your interactions with the site easier.

+
    +
  • These cannot be used to identify you personally.
  • +
+

Security

+

IoT Server uses selected cookies to identify and prevent security risks.

+

For example, IoT Server may use cookies to store your session information to prevent others from changing your password without your username and password.

+

IoT Server uses session cookie to maintain your active session.

+

IoT Server may use a temporary cookie when performing multi-factor authentication and federated authentication.

+

IoT Server may use permanent cookies to detect the devices you have logged in previously. This is to to calculate the risk level associated with your current login attempt. Using these cookies protects you and your account from possible attacks.

+

Performance

+

IoT Server may use cookies to allow “Remember Me” functionalities.

+
+

Analytics

+

IoT Server as a product does not use cookies for analytical purposes.

+
+

Third party cookies

+

Using IoT Server may cause some third-party cookie being set to your browser. IoT Server has no control over the operation of these cookies. The third-party cookies which maybe set include,

+
    +
  • Any of the social login sites, when IoT Server is configured to use “Social” or “Federated” login, and you opt to do login with your “Social Account”
  • +
  • Any third party federated login
  • +
+

We strongly advise you to refer the respective cookie policies of such sites carefully as IoT Server has no knowledge or use on these cookies.

+
+

What type of cookies does IoT Server use ?

+

IoT Server uses persistent cookies and session cookies. A persistent cookie helps IoT Server to recognize you as an existing user, so you can easily return to WSO2 or interact with IoT Server without signing in again. After you sign in, a persistent cookie stays in your browser and will be read by IoT Server when you return.

+

A session cookie is erased when the user closes the Web browser. It is stored in temporarily and is not retained after the browser is closed. Session cookies do not collect information from the user’s computer.

+
+

How do I control my cookies ?

+

Most browsers allow you to control cookies through settings. However, if you limit the ability of websites to set cookies, you may worsen your overall user experience, since it will no longer be personalized to you. It may also stop you from saving customized settings like login information. Disabling cookies might make you unable to use Authentication and Authorization functionalities offered by IoT Server.

+

If you have any questions or concerns regarding the use of cookies, please contact the Data Protection Officer of the organization running this IoT Server instance.

+
+

What are the cookies used ?

+ + + + + + + + + + + + + + + + + + + + + + + +
+

Cookie Name

+
+

Purpose

+
+

Retention

+
+

JSESSIONID

+
+

Keeps track of the user session data when you are logged in for providing a better user experience.

+
+

Session

+
+

commonAuthId

+
+

Used for authentication the logged in session.

+
+

Session

+
+

samlssoTokenId

+
+

Used for mapping the logged in users with the SAML token.

+
+

Request

+
+
+

Disclaimer

+

This cookie policy is only for illustrative purposes of the IoT Server product. The content in this policy is technically correct at the time of product shipment. The organization which runs this IoT Server instance has the full authority and responsibility of the effective Cookie Policy.

+
+ <%-- /Customizable content --%> +
+
+ +
+
+ diff --git a/iot-core/src/core/resources/extensions/customAssets/logo.svg b/iot-core/src/core/resources/extensions/customAssets/logo.svg new file mode 100644 index 0000000..7986a8d --- /dev/null +++ b/iot-core/src/core/resources/extensions/customAssets/logo.svg @@ -0,0 +1,798 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/iot-core/src/core/resources/extensions/header.jsp b/iot-core/src/core/resources/extensions/header.jsp new file mode 100644 index 0000000..1aebcff --- /dev/null +++ b/iot-core/src/core/resources/extensions/header.jsp @@ -0,0 +1,194 @@ + +<%-- +~ Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. +~ +~ WSO2 Inc. licenses this file to you under the Apache License, +~ Version 2.0 (the "License"); you may not use this file except +~ in compliance with the License. +~ You may obtain a copy of the License at +~ +~ http://www.apache.org/licenses/LICENSE-2.0 +~ +~ Unless required by applicable law or agreed to in writing, +~ software distributed under the License is distributed on an +~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +~ KIND, either express or implied. See the License for the +~ specific language governing permissions and limitations +~ under the License. +--%> + + + +<%@ page import="java.io.File" %> +<%@ page import="java.io.FileReader" %> +<%@ page import="org.json.simple.parser.JSONParser"%> +<%@ page import="org.json.simple.JSONObject"%> +<%@ page import="java.net.URI"%> +<%@ page import="org.apache.commons.lang.StringUtils"%> + +<%@ page import="org.wso2.carbon.identity.application.authentication.endpoint.util.AuthenticationEndpointUtil" %> +<%@ page import="org.wso2.carbon.identity.mgt.endpoint.util.IdentityManagementEndpointUtil" %> + +<% + String tenant = request.getParameter("tenantDomain"); + if (tenant == null) { + String cb = request.getParameter("callback"); + cb = StringUtils.replace(cb, " ", ""); + if (cb != null) { + URI uri = new URI(cb); + String decodedValue = uri.getQuery(); + String[] params = decodedValue.split("&"); + for (String param : params) { + if (param.startsWith("tenantDomain=")) { + String[] keyVal = param.split("="); + tenant = keyVal[1]; + } + } + } + } + + String headerTitle = "IOT Server"; + String pageTitle = "Entgra IOT Server"; + String footerText = "Entgra IOT Server"; + String faviconSrc = "libs/theme/assets/images/favicon.ico"; + String logoSrc = null; + String logoHeight = "50"; + String logoWidth = "50"; + String logoAltText = ""; + File customCSSFile = null; + String customCSS = ""; + String tenantThemeDirectoryName = ""; + boolean showCookiePolicy = true; + boolean showPrivacyPolicy = true; + String cookiePolicyText = null; + String privacyPolicyText = null; + + if (tenant != null) { + String current = new File(".").getCanonicalPath(); + String tenantConfLocation = "/repository/deployment/server/jaggeryapps/devportal/site/public/tenant_themes/"; + tenantThemeDirectoryName = tenant; + String tenantThemeFile = current + tenantConfLocation + tenantThemeDirectoryName + "/login/" + "loginTheme.json"; + customCSS = current + tenantConfLocation + tenantThemeDirectoryName + "/login/css/" + "loginTheme.css"; + File directory = new File(current + tenantConfLocation + tenantThemeDirectoryName); + if (directory != null && directory.exists() && directory.isDirectory()) { + File themeFile = new File(tenantThemeFile); + customCSSFile = new File(customCSS); + if (themeFile != null && themeFile.exists() && themeFile.isFile()) { + FileReader fr = new FileReader(themeFile); + JSONParser parser = new JSONParser(); + Object obj = parser.parse(fr); + JSONObject jsonObject = (JSONObject) obj; + + pageTitle = (String)jsonObject.get("title") != null ? (String)jsonObject.get("title") : "Entgra IOT Server"; + + JSONObject headerThemeObj = (JSONObject)jsonObject.get("header"); + if (headerThemeObj != null) { + headerTitle = (String)(headerThemeObj.get("title")) != null ? (String)(headerThemeObj.get("title")) : "IOT Server"; + } + + JSONObject footerThemeObj = (JSONObject)jsonObject.get("footer"); + if (footerThemeObj != null) { + footerText = (String)(footerThemeObj.get("name")); + } + + JSONObject faviconThemeObj = (JSONObject)jsonObject.get("favicon"); + if (faviconThemeObj != null) { + String fileName = (String)(faviconThemeObj.get("src")); + if (!StringUtils.isEmpty(fileName)) { + faviconSrc = "/devportal/site/public/tenant_themes/" + tenantThemeDirectoryName + "/login/images/" + + fileName; + } + } + + JSONObject logoThemeObj = (JSONObject)jsonObject.get("logo"); + if (logoThemeObj != null) { + String fileName = (String)(logoThemeObj.get("src")); + if (!StringUtils.isEmpty(fileName)) { + logoSrc = "/devportal/site/public/tenant_themes/" + tenantThemeDirectoryName + "/login/images/" + + fileName; + } + logoHeight = (String)(logoThemeObj.get("height")) != null ? (String)(logoThemeObj.get("height")) : logoHeight; + logoWidth = (String)(logoThemeObj.get("width")) != null ? (String)(logoThemeObj.get("width")) : logoWidth; + logoAltText = (String)(logoThemeObj.get("alt")); + } + + JSONObject cookiePolicyThemeObj = (JSONObject)jsonObject.get("cookie-policy"); + if (cookiePolicyThemeObj != null) { + showCookiePolicy = (Boolean)(cookiePolicyThemeObj.get("visible")); + cookiePolicyText = (String)cookiePolicyThemeObj.get("text"); + } + + JSONObject privacyPolicyThemeObj = (JSONObject)jsonObject.get("privacy-policy"); + if (privacyPolicyThemeObj != null) { + showPrivacyPolicy = (Boolean)(privacyPolicyThemeObj.get("visible")); + privacyPolicyText = (String)privacyPolicyThemeObj.get("text"); + } + } + } + } + request.setAttribute("headerTitle", headerTitle); + request.setAttribute("pageTitle", pageTitle); + request.setAttribute("footerText", footerText); + request.setAttribute("faviconSrc", faviconSrc); + request.setAttribute("showCookiePolicy", showCookiePolicy); + request.setAttribute("showPrivacyPolicy", showPrivacyPolicy); + request.setAttribute("cookiePolicyText", cookiePolicyText); + request.setAttribute("privacyPolicyText", privacyPolicyText); + request.setAttribute("logoSrc", logoSrc); + request.setAttribute("logoHeight", logoHeight); + request.setAttribute("logoWidth", logoWidth); + request.setAttribute("logoAltText", logoAltText); + + if (customCSSFile != null && customCSSFile.exists() && customCSSFile.isFile()) { + String cssRelativePath = "/devportal/site/public/tenant_themes/" + tenantThemeDirectoryName + "/login/css/" + "loginTheme.css"; + request.setAttribute("customCSS", cssRelativePath); + } else { + request.setAttribute("customCSS", ""); + } + +%> + + + + + + + + + +<%=request.getAttribute("pageTitle")%> + +<% + String cssPath = request.getAttribute("customCSS") + ""; + if (!StringUtils.isEmpty(cssPath)) { +%> + rel="stylesheet" type="text/css"> +<% } +%> + + diff --git a/iot-core/src/core/resources/extensions/privacy-policy-content.jsp b/iot-core/src/core/resources/extensions/privacy-policy-content.jsp new file mode 100644 index 0000000..762228c --- /dev/null +++ b/iot-core/src/core/resources/extensions/privacy-policy-content.jsp @@ -0,0 +1,292 @@ +<%-- + ~ Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. + ~ + ~ WSO2 Inc. licenses this file to you under the Apache License, + ~ Version 2.0 (the "License"); you may not use this file except + ~ in compliance with the License. + ~ You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--%> + + +
+
+
+
+
+
+ +
+
+

+ Entgra IOT Server - Privacy Policy +

+
+
+ <%-- Customizable content. Due to this nature, i18n is not implemented for this section --%> +
+

About Entgra IOT Server

+

Entgra IoT Server is a complete solution that enables device + manufacturers and enterprises to connect and manage their devices, + build apps, manage events, secure devices and data, and visualize + sensor data in a scalable manner.

+

It also offers a complete and secure Enterprise Mobility Management + (EMM/MDM) solution that aims to address mobile computing challenges + faced by enterprises today. Supporting iOS, Android, and Windows + devices, it helps organizations deal with both Corporate Owned, + Personally Enabled (COPE) and employee-owned devices with the Bring + Your Own Device (BYOD) concept.

+

Entgra IoT Server comes with advanced analytics, enabling users to + analyze speed, proximity, and geo-fencing information of devices + including details of those in motion and stationary state.

+
+

Privacy Policy

+

This policy describes how Entgra IoT Server 4.0.0 captures your + personal information, the purposes of collection, and information + about the retention of your personal information.

+

Please note that this policy is for reference only, and is applicable + for the software as a product. Entgra and its developers have no + access to the information held within Entgra IoT Server 4.0.0.Please + see the Disclaimer section for more information. Entities, + organisations or individuals controlling the use and administration of + Entgra IoT Server 4.0.0 should create their own privacy policies + setting out the manner in which data is controlled or processed by the + respective entity, organisation or individual.

+
+

What are the personal information ?

+

Entgra IoT Server 4.0.0 considers anything related to you and by which + you may be identified as your personal information.

+ Signing in to Entgra IoT Server +
    +
  1. + Your user name (except in cases where the user name created by your + employer is under contract) +
  2. +
  3. IP address used to log in
  4. +
  5. Email address
  6. +
+ Enrolling a device with Entgra IoT Server +
    +
  • + Your device ID (e.g., phone or tablet), mobile number, IMEI number, + and IMSI number +
  • +
  • Your device's location
  • +
  • Your device's application list, and memory usage
  • +
  • + Your device's usage statistics, such as RAM, battery level, + connected hotspot details, and memory usage +
  • +
+

However, Entgra IoT Server 4.0.0 also collects the following + information that is not considered personal information, but is used + only for statistical purposes. The reason for this + is that this information can not be used to track you.

+ +
    +
  • City/Country from which you originated the TCP/IP connection
  • +
  • + Time of the day that you logged in (year, month, week, hour or + minute) +
  • +
  • + Type of device that you used to log in (e.g., phone or tablet) +
  • +
  • Operating system and generic browser information
  • +
+ +
+

Collection of your information

+

Entgra IoT Server collects your information only to serve your + access requirements.

+

For example,

+
    +
  • + Entgra IoT Server uses your IP address to detect any + suspicious login attempts to your account. +
  • +
  • + Entgra IoT Server uses attributes like your first name, last + name, etc., to provide a rich and personalized user experience. +
  • +
  • + Entgra IoT Server uses your security questions and answers + only to allow account recovery. +
  • +
+
+

Tracking Technologies

+

Entgra IoT Server collects your information by:

+
    +
  • + Collecting information from the user profile page where you enter + your personal data. +
  • +
  • + Tracking your IP address with HTTP request, HTTP headers, and + TCP/IP. +
  • +
  • Tracking your geographic information with the IP address.
  • +
  • + Tracking your login history with browser cookies. Please see our + cookie policy for more information. +
  • +
+ +
+

Use of your personal information

+

Entgra IoT Server 4.0.0 will only use your personal information for + the purposes for which it was collected (or for a use identified as + consistent with that purpose).

+

Entgra IoT Server 4.0.0 uses your personal information only for the + following purposes.

+
    +
  • + To provide you with a personalized user experience. Entgra IoT + Server 4.0.0 uses your name and uploaded profile pictures for this + purpose. +
  • +
  • + To protect your account from unauthorized access or potential + hacking attempts. Entgra IoT Server 4.0.0 uses HTTP or TCP/IP + Headers for this purpose. +
  • +
  • + This includes: +
      +
    1. IP address
    2. +
    3. Browser fingerprinting
    4. +
    5. Cookies
    6. +
    +
  • +
  • + Derive statistical data for analytical purposes on system + performance improvements. Entgra IoT Server 4.0.0 will not keep any + personal information after statistical calculations. Therefore, the + statistical report has no means of identifying an individual person. +
  • +
  • + Entgra IoT Server 4.0.0 may use: +
      +
    1. IP Address to derive geographic information
    2. +
    3. + Browser fingerprinting to determine the browser technology + or/and version +
    4. +
    +
  • +
+
+

Disclosure of your personal information

+

Entgra IoT Server 4.0.0 only discloses personal information to the + relevant applications (also known as “Service Providers”) that are + registered with Entgra IoT Server 4.0.0. These applications are + registered by the identity administrator of your entity or + organization. Personal information is disclosed only for the purposes + for which it was collected (or for a use identified as consistent with + that purpose) as controlled by such Service Providers, unless you have + consented otherwise or where it is required by law.

+
+ +

Please note that the organisation, entity or individual running Entgra + IoT Server 4.0.0 may be compelled to disclose your personal + information with or without your consent when it is required by law + following due and lawful process.

+
+

Storage of personal information

+
+

Where your personal information is stored

+

Entgra IoT Server 4.0.0 stores your personal information in secured + databases. Entgra IoT Server 4.0.0 exercises proper industry accepted + security measures to protect the database where your personal + information is held.Entgra IoT Server 4.0.0 as a product does not + transfer or share your data with any third parties or locations.

+

Entgra IoT Server 4.0.0 may use encryption to keep your personal data + with an added level of security.

+
+

How long your personal information is retaineds ?

+

Entgra IoT Server 4.0.0 retains your personal data as long as you are + an active user of our system. You can update your personal data at any + time using the given self-care user portals.

+

Entgra IoT Server 4.0.0 may keep hashed secrets to provide you with an + added level of security. This includes:

+
    +
  • Current password
  • +
  • Previously used passwords
  • +
+
+

How can you request a removal of your personal information ?

+

You can request the administrator to delete your account. The + administrator is the administrator of the tenant you are registered + under, or the super-administrator if you do not use the tenant + feature.

+

Additionally, you can request to anonymize all traces of your + activities that Entgra IoT Server 4.0.0 may have retained in logs, + databases or analytical storage.

+
+

More Information

+
+

Changes to this policy

+

Upgraded versions of Entgra IoT Server 4.0.0 may contain changes to + this policy. Revisions to this policy will be packaged within such + upgrades and would only apply to users who choose to use upgraded + versions.

+ +
+

Your choices

+

+ If you are already have an user account within Entgra IoT Server 4.0.0 + ; you have the right to deactivate your account if you find that this + privacy policy is unacceptable to you. +

+

+ If you do not have an account and you do not agree with our privacy + policy, you can chose not to create one. +

+
+

Contact us

+

Please contact Entgra if you have any question or concerns regarding + this privacy policy.

+

contact

+
+

Disclaimer

+

+ Entgra, its employees, partners, and affiliates do not have access to + and do not require, store, process or control any of the data, + including personal data contained in Entgra IoT Server 4.0.0. All + data, including personal data is controlled and processed by the + entity or individual running Entgra IoT Server 4.0.0. Entgra, its + employees partners and affiliates are not a data processor or a data + controller within the meaning of any data privacy regulations. Entgra + does not provide any warranties or undertake any responsibility or + liability in connection with the lawfulness or the manner and purposes + for which Entgra IoT Server 4.0.0 is used by such entities or persons. +

+

+ This privacy policy is for the informational purposes of the entity or + persons running Entgra IoT Server 4.0.0 and sets out the processes and + functionality contained within Entgra IoT Server 4.0.0 regarding + personal data protection. It is the responsibility of entities and + persons running Entgra IoT Server 4.0.0 to create and administer its + own rules and processes governing users’ personal data, Please note + that the creation of such rules and processes may change the use, + storage and disclosure policies contained herein. Therefore users + should consult the entity or persons running Entgra IoT Server 4.0.0 + for its own privacy policy for details governing users’ personal data. +

+
+ <%-- /Customizable content --%> +
+
+ +
+
+ diff --git a/iot-core/src/core/resources/extensions/product-title.jsp b/iot-core/src/core/resources/extensions/product-title.jsp new file mode 100644 index 0000000..5a14a40 --- /dev/null +++ b/iot-core/src/core/resources/extensions/product-title.jsp @@ -0,0 +1,46 @@ +<%-- + ~ Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. + ~ + ~ WSO2 Inc. licenses this file to you under the Apache License, + ~ Version 2.0 (the "License"); you may not use this file except + ~ in compliance with the License. + ~ You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--%> + + + +<%@ page import="org.apache.commons.lang.StringUtils"%> + +<% if ("IOT Server".equals(request.getAttribute("headerTitle"))) { %> +
+ +

IOT Server

+
+<% } else { + + String logoSrc = (String)request.getAttribute("logoSrc"); + String logoHeight = (String)request.getAttribute("logoHeight"); + String logoWidth = (String)request.getAttribute("logoWidth"); + String logoAltText = (String)request.getAttribute("logoAltText"); + if (!StringUtils.isEmpty(logoSrc)) { +%> +
+ alt=<%=logoAltText%> height=<%=logoHeight%> width=<%=logoWidth%>> +
+<% } else { %> +
+

<%=request.getAttribute("headerTitle")%>

+
+<% } %> +<% } %> diff --git a/iot-core/src/core/resources/extensions/title.jsp b/iot-core/src/core/resources/extensions/title.jsp new file mode 100644 index 0000000..574086b --- /dev/null +++ b/iot-core/src/core/resources/extensions/title.jsp @@ -0,0 +1,23 @@ + +<%-- + ~ Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. + ~ + ~ WSO2 Inc. licenses this file to you under the Apache License, + ~ Version 2.0 (the "License"); you may not use this file except + ~ in compliance with the License. + ~ You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--%> + + + + +WSO2 IOT Server diff --git a/iot-core/src/core/synapse-configs/default/api/_TokenAPI_.xml b/iot-core/src/core/synapse-configs/default/api/_TokenAPI_.xml new file mode 100644 index 0000000..eafd691 --- /dev/null +++ b/iot-core/src/core/synapse-configs/default/api/_TokenAPI_.xml @@ -0,0 +1,44 @@ + + + + + + + + + + + $1 + refresh_token + + + + + + +
+ + + + + + + + + + 60000 + fault + + + + + + + + + + + + + + diff --git a/p2-profile/emm/pom.xml b/p2-profile/emm/pom.xml new file mode 100644 index 0000000..71e6dc2 --- /dev/null +++ b/p2-profile/emm/pom.xml @@ -0,0 +1,141 @@ + + + + + + + io.entgra.community + p2-profile + 5.0.0-SNAPSHOT + ../pom.xml + + + 4.0.0 + entgra-emm-p2-profile + pom + Entgra EMM - p2 profile + Entgra EMM p2 profile + + + + + org.apache.maven.plugins + maven-dependency-plugin + false + + + 1-unpack-entgra-iots + test + + unpack + + + + + io.entgra.community + entgra-iot-core + zip + true + target + + + + + + + + org.wso2.maven + carbon-p2-plugin + + + 2-p2-repo-generation + package + + p2-repo-gen + + + file:${basedir}/target/p2-repo + file:${basedir}/target/p2-repo + true + true + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.mobile.android.feature:${carbon.device.mgt.plugin.version} + + + + + + + + + feature-install + package + + p2-profile-gen + + + default + file:${basedir}/target/p2-repo + file:${basedir}/target/p2-repo + ${basedir}/target/${entgra-iot-core}/repository/components + true + + + org.wso2.carbon.device.mgt.mobile.android.feature.group + ${carbon.device.mgt.plugin.version} + + + + + + + + + + + + com.google.code.maven-replacer-plugin + replacer + 1.5.3 + + + package + + replace + + + + + + ${basedir}/target/${entgra-iot-core}/repository/components/default/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info + + + + false + true + + + + + + + + + diff --git a/p2-profile/iot/pom.xml b/p2-profile/iot/pom.xml new file mode 100644 index 0000000..b5869b3 --- /dev/null +++ b/p2-profile/iot/pom.xml @@ -0,0 +1,142 @@ + + + + + + + io.entgra.community + p2-profile + 5.0.0-SNAPSHOT + ../pom.xml + + + 4.0.0 + entgra-iot-p2-profile + pom + Entgra IoT - p2 profile + Entgra IoT p2 profile + + + + + org.apache.maven.plugins + maven-dependency-plugin + false + + + 1-unpack-entgra-iots + test + + unpack + + + + + io.entgra.community + entgra-iot-core + zip + true + target + + + + + + + + org.wso2.maven + carbon-p2-plugin + ${carbon.p2.plugin.version} + + + 2-p2-repo-generation + package + + p2-repo-gen + + + file:${basedir}/target/p2-repo + file:${basedir}/target/p2-repo + true + true + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.adapter.feature:${carbon.device.mgt.plugin.version} + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.notification.listener.feature:${carbon.device.mgt.plugin.version} + + + + + + feature-install + package + + p2-profile-gen + + + default + file:${basedir}/target/p2-repo + file:${basedir}/target/p2-repo + ${basedir}/target/${entgra-iot-core}/repository/components + true + + + org.wso2.carbon.device.mgt.adapter.feature.group + ${carbon.device.mgt.plugin.version} + + + org.wso2.carbon.device.mgt.notification.listener.feature.group + ${carbon.device.mgt.plugin.version} + + + + + + + + com.google.code.maven-replacer-plugin + replacer + 1.5.3 + + + package + + replace + + + + + + ${basedir}/target/${entgra-iot-core}/repository/components/default/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info + + + + false + true + + + + + + + + + diff --git a/p2-profile/pom.xml b/p2-profile/pom.xml new file mode 100644 index 0000000..9f1f210 --- /dev/null +++ b/p2-profile/pom.xml @@ -0,0 +1,40 @@ + + + + + + + io.entgra.community + community-parent + 5.0.0-SNAPSHOT + ../pom.xml + + + 4.0.0 + p2-profile + pom + Entgra IoT - P2 Profile Module + http://entgra.io + + + iot + emm + + + diff --git a/p2-profile/target/.plxarc b/p2-profile/target/.plxarc new file mode 100644 index 0000000..67ea6ee --- /dev/null +++ b/p2-profile/target/.plxarc @@ -0,0 +1 @@ +maven-shared-archive-resources \ No newline at end of file diff --git a/p2-profile/target/maven-shared-archive-resources/META-INF/DEPENDENCIES b/p2-profile/target/maven-shared-archive-resources/META-INF/DEPENDENCIES new file mode 100644 index 0000000..fb35ea7 --- /dev/null +++ b/p2-profile/target/maven-shared-archive-resources/META-INF/DEPENDENCIES @@ -0,0 +1,11 @@ +// ------------------------------------------------------------------ +// Transitive dependencies of this project determined from the +// maven pom organized by organization. +// ------------------------------------------------------------------ + +Entgra IoT - P2 Profile Module + + + + + diff --git a/p2-profile/target/maven-shared-archive-resources/META-INF/LICENSE b/p2-profile/target/maven-shared-archive-resources/META-INF/LICENSE new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/p2-profile/target/maven-shared-archive-resources/META-INF/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/p2-profile/target/maven-shared-archive-resources/META-INF/NOTICE b/p2-profile/target/maven-shared-archive-resources/META-INF/NOTICE new file mode 100644 index 0000000..b2cab3c --- /dev/null +++ b/p2-profile/target/maven-shared-archive-resources/META-INF/NOTICE @@ -0,0 +1,8 @@ + +Entgra IoT - P2 Profile Module +Copyright 2021 WSO2 + +This product includes software developed at +The Apache Software Foundation (http://www.apache.org/). + + diff --git a/p2-profile/target/timestamp b/p2-profile/target/timestamp new file mode 100644 index 0000000..1e10b78 Binary files /dev/null and b/p2-profile/target/timestamp differ diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..f504547 --- /dev/null +++ b/pom.xml @@ -0,0 +1,370 @@ + + + + + + 4.0.0 + io.entgra.community + community-parent + pom + 5.0.0-SNAPSHOT + Entgra Community Product - Parent + http://entgra.io + Entgra Community Product + + + org.wso2 + wso2 + 2 + + + + iot-core + p2-profile + distribution + + + + + + + org.wso2.carbon.devicemgt + org.wso2.carbon.device.mgt.core + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.device.mgt.common + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.device.mgt.group.core + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.device.mgt.group.common + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.policy.mgt.common + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.policy.mgt.core + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.certificate.mgt.core + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.identity.jwt.client.extension + ${carbon.device.mgt.version} + + + org.wso2.carbon.devicemgt + org.wso2.carbon.device.mgt.oauth.extensions + ${carbon.device.mgt.version} + + + + + com.h2database.wso2 + h2-database-engine + ${orbit.h2.engine.version} + + + + io.entgra.community + entgra-iot-core + ${project.version} + + + + + + + wso2am-4.0.0 + https://github.com/wso2/product-apim/releases/download/v4.0.0/${wso2am}.zip + + entgra-iot-core-${project.version} + entgra-iot-community-${project.version} + entgra-emm-community-${project.version} + + + 5.0.0-SNAPSHOT + + 5.1.2 + + + 1.2.140.wso2v3 + + 6.0.0-SNAPSHOT + + + + + + https://gitlab.com/entgra/product-iots.git + scm:git:https://gitlab.com/entgra/product-iots.git + scm:git:https://gitlab.com/entgra/product-iots.git + HEAD + + + + + + org.apache.maven.wagon + wagon-ssh + 2.1 + + + + + + org.jvnet.maven.incrementalbuild + incremental-build-plugin + 1.3 + + + + incremental-build + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 2.3.1 + + UTF-8 + 1.8 + 1.8 + + + + org.apache.maven.plugins + maven-release-plugin + + clean install + true + + + + org.apache.maven.plugins + maven-deploy-plugin + + + + + + org.apache.felix + maven-scr-plugin + 1.7.2 + + + generate-scr-scrdescriptor + + scr + + + + + + org.apache.felix + maven-bundle-plugin + 2.3.5 + true + + NONE + + + + + org.apache.maven.plugins + maven-source-plugin + 2.1.2 + + + attach-sources + verify + + jar-no-fork + + + + + + org.apache.maven.plugins + maven-assembly-plugin + 3.0.0 + + + org.apache.maven.plugins + maven-project-info-reports-plugin + 2.4 + + + org.codehaus.mojo + build-helper-maven-plugin + 1.8 + + + org.apache.maven.plugins + maven-surefire-plugin + 2.18.1 + + + true + + + + + + + + + wso2.releases + WSO2 internal Repository + http://maven.wso2.org/nexus/content/repositories/releases/ + + true + daily + ignore + + + + wso2.snapshots + Apache Snapshot Repository + http://maven.wso2.org/nexus/content/repositories/snapshots/ + + true + daily + + + false + + + + wso2-nexus + WSO2 internal Repository + http://maven.wso2.org/nexus/content/groups/wso2-public/ + + true + daily + ignore + + + + + + + + + wso2-nexus + WSO2 internal Repository + http://maven.wso2.org/nexus/content/groups/wso2-public/ + + true + daily + ignore + + + + wso2.releases + WSO2 internal Repository + http://maven.wso2.org/nexus/content/repositories/releases/ + + true + daily + ignore + + + + wso2.snapshots + WSO2 Snapshot Repository + http://maven.wso2.org/nexus/content/repositories/snapshots/ + + true + daily + + + false + + + + entgra-nexus + Entgra internal Repository + http://nexus.entgra.io/repository/maven-public/ + + true + daily + ignore + + + + entgra.snapshots + Entgra Snapshot Repository + http://nexus.entgra.io/repository/maven-snapshots/ + + true + daily + + + false + + + + entgra.releases + Entgra internal Repository + http://nexus.entgra.io/repository/maven-releases/ + + true + daily + ignore + + + false + + + + + + maven-snapshots + http://nexus.entgra.io/repository/maven-snapshots/ + + + maven-release + http://nexus.entgra.io/repository/maven-releases/ + + +