diff options
author | Jacob Keeler <jacob.keeler@livioradio.com> | 2019-03-06 09:52:37 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-06 09:52:37 -0500 |
commit | 2e433d4810c1a9a4a78550b6caa0a27ff03259ef (patch) | |
tree | af6364654091f0d7a708e638729b10f83e1b7ec1 | |
parent | ba7bd475d6099d8a1f3d4c9b2de9317070c84718 (diff) | |
parent | 24be2c57bb2965d29c86f6891346b6491bcf08e6 (diff) | |
download | sdl_core-2e433d4810c1a9a4a78550b6caa0a27ff03259ef.tar.gz |
Merge pull request #2827 from smartdevicelink/feature/protect_published_services
App Services Fixes
9 files changed, 122 insertions, 88 deletions
diff --git a/src/components/application_manager/include/application_manager/app_service_manager.h b/src/components/application_manager/include/application_manager/app_service_manager.h index 5a345e60fb..d6d13a209a 100644 --- a/src/components/application_manager/include/application_manager/app_service_manager.h +++ b/src/components/application_manager/include/application_manager/app_service_manager.h @@ -126,22 +126,22 @@ class AppServiceManager { std::vector<smart_objects::SmartObject> GetAllServices(); void GetProviderByType(const std::string& service_type, + bool mobile_consumer, ApplicationSharedPtr& app, bool& hmi_service); void GetProviderByID(const std::string& service_id, + bool mobile_consumer, ApplicationSharedPtr& app, bool& hmi_service); - std::pair<std::string, AppService> ActiveServiceByType( - std::string service_type); + AppService* ActiveServiceByType(std::string service_type); - std::pair<std::string, AppService> EmbeddedServiceForType( - std::string service_type); + AppService* EmbeddedServiceForType(std::string service_type); - std::pair<std::string, AppService> FindServiceByName(std::string name); + AppService* FindServiceByName(std::string name); - std::pair<std::string, AppService> FindServiceByID(std::string service_id); + AppService* FindServiceByID(std::string service_id); std::string DefaultServiceByType(std::string service_type); @@ -162,6 +162,8 @@ class AppServiceManager { private: ApplicationManager& app_manager_; resumption::LastState& last_state_; + + sync_primitives::RecursiveLock published_services_lock_; std::map<std::string, AppService> published_services_; void AppServiceUpdated( @@ -169,10 +171,11 @@ class AppServiceManager { const mobile_apis::ServiceUpdateReason::eType update_reason, smart_objects::SmartObject& msg_params); void GetProviderFromService(const AppService& service, + bool mobile_consumer, ApplicationSharedPtr& app, bool& hmi_service); - std::pair<std::string, AppService> FindServiceByPolicyAppID( - std::string policy_app_id, std::string type); + AppService* FindServiceByPolicyAppID(std::string policy_app_id, + std::string type); std::string GetPolicyAppID(AppService service); }; diff --git a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_perform_app_service_interaction_request_from_hmi.cc b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_perform_app_service_interaction_request_from_hmi.cc index c384e73d33..2b66993d8f 100644 --- a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_perform_app_service_interaction_request_from_hmi.cc +++ b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_perform_app_service_interaction_request_from_hmi.cc @@ -79,7 +79,7 @@ void ASPerformAppServiceInteractionRequestFromHMI::Run() { std::string service_id = msg_params[strings::service_id].asString(); auto service = application_manager_.GetAppServiceManager().FindServiceByID(service_id); - if (service.first.empty()) { + if (!service) { smart_objects::SmartObject response_params; response_params[strings::info] = "The requested service ID does not exist"; SendResponse(false, @@ -99,9 +99,8 @@ void ASPerformAppServiceInteractionRequestFromHMI::Run() { } // Only activate service if it is not already active - bool activate_service = - request_service_active && - !service.second.record[strings::service_active].asBool(); + bool activate_service = request_service_active && + !service->record[strings::service_active].asBool(); if (activate_service) { application_manager_.GetAppServiceManager().ActivateAppService(service_id); } diff --git a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/get_app_service_data_request.cc b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/get_app_service_data_request.cc index b54071068f..0d387785ee 100644 --- a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/get_app_service_data_request.cc +++ b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/get_app_service_data_request.cc @@ -70,16 +70,16 @@ void GetAppServiceDataRequest::Run() { std::string service_type = (*message_)[strings::msg_params][strings::service_type].asString(); - bool subscribe = false; - if ((*message_)[strings::msg_params].keyExists(strings::subscribe)) { - subscribe = (*message_)[strings::msg_params][strings::subscribe].asBool(); - } - ApplicationSharedPtr app = application_manager_.application(connection_key()); - - if (subscribe) { + if ((*message_)[strings::msg_params].keyExists(strings::subscribe)) { + bool subscribe = + (*message_)[strings::msg_params][strings::subscribe].asBool(); auto& ext = AppServiceAppExtension::ExtractASExtension(*app); - ext.SubscribeToAppService(service_type); + if (subscribe) { + ext.SubscribeToAppService(service_type); + } else { + ext.UnsubscribeFromAppService(service_type); + } } SendProviderRequest(mobile_apis::FunctionID::GetAppServiceDataID, diff --git a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/on_app_service_data_notification.cc b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/on_app_service_data_notification.cc index a016d1fe16..2c6ba414e0 100644 --- a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/on_app_service_data_notification.cc +++ b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/on_app_service_data_notification.cc @@ -61,10 +61,27 @@ OnAppServiceDataNotification::~OnAppServiceDataNotification() {} void OnAppServiceDataNotification::Run() { LOG4CXX_AUTO_TRACE(logger_); LOG4CXX_DEBUG(logger_, "Sending OnAppServiceData to consumer"); - MessageHelper::PrintSmartObject(*message_); + + std::string service_id = + (*message_)[strings::msg_params][strings::service_data] + [strings::service_id].asString(); + auto service = + application_manager_.GetAppServiceManager().FindServiceByID(service_id); + + if (!service) { + LOG4CXX_ERROR(logger_, "Service sending OnAppServiceData is not published"); + return; + } else if (!service->record[strings::service_manifest] + [strings::allow_app_consumers].asBool()) { + LOG4CXX_ERROR(logger_, + "Service does not allow for app consumers, skipping mobile " + "OnAppServiceData notification"); + return; + } std::string service_type = - (*message_)[strings::msg_params][strings::service_type].asString(); + (*message_)[strings::msg_params][strings::service_data] + [strings::service_type].asString(); auto subscribed_to_app_service_predicate = [service_type](const ApplicationSharedPtr app) { diff --git a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/perform_app_service_interaction_request.cc b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/perform_app_service_interaction_request.cc index d21c413b29..952d1834fb 100644 --- a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/perform_app_service_interaction_request.cc +++ b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/perform_app_service_interaction_request.cc @@ -66,7 +66,7 @@ void PerformAppServiceInteractionRequest::Run() { std::string service_id = msg_params[strings::service_id].asString(); auto service = application_manager_.GetAppServiceManager().FindServiceByID(service_id); - if (service.first.empty()) { + if (!service) { SendResponse(false, mobile_apis::Result::INVALID_ID, "The requested service ID does not exist"); @@ -81,9 +81,8 @@ void PerformAppServiceInteractionRequest::Run() { } // Only activate service if it is not already active - bool activate_service = - request_service_active && - !service.second.record[strings::service_active].asBool(); + bool activate_service = request_service_active && + !service->record[strings::service_active].asBool(); if (activate_service) { if (app->is_foreground()) { // App is in foreground, we can just activate the service diff --git a/src/components/application_manager/src/app_service_manager.cc b/src/components/application_manager/src/app_service_manager.cc index ed9120ad19..24c21dc201 100644 --- a/src/components/application_manager/src/app_service_manager.cc +++ b/src/components/application_manager/src/app_service_manager.cc @@ -70,6 +70,7 @@ smart_objects::SmartObject AppServiceManager::PublishAppService( std::string str_to_hash = ""; std::string service_id = ""; + published_services_lock_.Acquire(); do { str_to_hash = manifest[strings::service_type].asString() + std::to_string(std::rand()); @@ -104,8 +105,10 @@ smart_objects::SmartObject AppServiceManager::PublishAppService( } app_service.default_service = GetPolicyAppID(app_service) == default_app_id; - published_services_.insert( + auto ret = published_services_.insert( std::pair<std::string, AppService>(service_id, app_service)); + smart_objects::SmartObject& published_record = ret.first->second.record; + published_services_lock_.Release(); smart_objects::SmartObject msg_params; msg_params[strings::system_capability][strings::system_capability_type] = @@ -117,18 +120,17 @@ smart_objects::SmartObject AppServiceManager::PublishAppService( // Activate the new service if it is the default for its service type, or if // no service is active of its service type - std::pair<std::string, AppService> active_service = - ActiveServiceByType(service_type); - if (active_service.first.empty() || app_service.default_service) { + AppService* active_service = ActiveServiceByType(service_type); + if (!active_service || app_service.default_service) { ActivateAppService(service_id); } - return service_record; + return published_record; } bool AppServiceManager::UnpublishAppService(const std::string service_id) { LOG4CXX_AUTO_TRACE(logger_); - + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Service id does not exist in published services"); @@ -141,22 +143,22 @@ bool AppServiceManager::UnpublishAppService(const std::string service_id) { msg_params[strings::system_capability][strings::system_capability_type] = mobile_apis::SystemCapabilityType::APP_SERVICES; - auto record = it->second.record; + auto& record = it->second.record; if (record[strings::service_active].asBool()) { record[strings::service_active] = false; // Activate embedded service, if available auto embedded_service = EmbeddedServiceForType( record[strings::service_manifest][strings::service_type].asString()); - if (!embedded_service.first.empty()) { - embedded_service.second.record[strings::service_active] = true; - AppServiceUpdated(embedded_service.second.record, + if (embedded_service) { + embedded_service->record[strings::service_active] = true; + AppServiceUpdated(embedded_service->record, mobile_apis::ServiceUpdateReason::ACTIVATED, msg_params); } } AppServiceUpdated( - it->second.record, mobile_apis::ServiceUpdateReason::REMOVED, msg_params); + record, mobile_apis::ServiceUpdateReason::REMOVED, msg_params); MessageHelper::BroadcastCapabilityUpdate(msg_params, app_manager_); published_services_.erase(it); @@ -166,6 +168,7 @@ bool AppServiceManager::UnpublishAppService(const std::string service_id) { void AppServiceManager::UnpublishServices(const uint32_t connection_key) { LOG4CXX_AUTO_TRACE(logger_); LOG4CXX_DEBUG(logger_, "Unpublishing all app services: " << connection_key); + sync_primitives::AutoLock lock(published_services_lock_); for (auto it = published_services_.begin(); it != published_services_.end(); ++it) { if (it->second.connection_key == connection_key) { @@ -176,6 +179,7 @@ void AppServiceManager::UnpublishServices(const uint32_t connection_key) { void AppServiceManager::OnAppActivated(ApplicationConstSharedPtr app) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.begin(); // Activate all services published by the app for (; it != published_services_.end(); ++it) { @@ -188,6 +192,7 @@ void AppServiceManager::OnAppActivated(ApplicationConstSharedPtr app) { std::vector<smart_objects::SmartObject> AppServiceManager::GetAllServices() { LOG4CXX_AUTO_TRACE(logger_); std::vector<smart_objects::SmartObject> services; + sync_primitives::AutoLock lock(published_services_lock_); for (auto it = published_services_.begin(); it != published_services_.end(); ++it) { services.push_back(it->second.record); @@ -196,11 +201,12 @@ std::vector<smart_objects::SmartObject> AppServiceManager::GetAllServices() { } void AppServiceManager::GetProviderByType(const std::string& service_type, + bool mobile_consumer, ApplicationSharedPtr& app, bool& hmi_service) { LOG4CXX_AUTO_TRACE(logger_); auto active_service = ActiveServiceByType(service_type); - if (active_service.first.empty()) { + if (!active_service) { LOG4CXX_ERROR(logger_, "There is no active service for the given service type: " << service_type); @@ -208,13 +214,15 @@ void AppServiceManager::GetProviderByType(const std::string& service_type, } LOG4CXX_DEBUG(logger_, "Found provider for service type: " << service_type); - GetProviderFromService(active_service.second, app, hmi_service); + GetProviderFromService(*active_service, mobile_consumer, app, hmi_service); } void AppServiceManager::GetProviderByID(const std::string& service_id, + bool mobile_consumer, ApplicationSharedPtr& app, bool& hmi_service) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Service id does not exist in published services"); @@ -222,13 +230,20 @@ void AppServiceManager::GetProviderByID(const std::string& service_id, } LOG4CXX_DEBUG(logger_, "Found provider with service ID: " << service_id); - GetProviderFromService(it->second, app, hmi_service); + GetProviderFromService(it->second, mobile_consumer, app, hmi_service); } void AppServiceManager::GetProviderFromService(const AppService& service, + bool mobile_consumer, ApplicationSharedPtr& app, bool& hmi_service) { LOG4CXX_AUTO_TRACE(logger_); + if (mobile_consumer && + !service.record[strings::service_manifest][strings::allow_app_consumers] + .asBool()) { + LOG4CXX_ERROR(logger_, "Service does not support app consumers"); + return; + } bool mobile_service = service.mobile_service; if (mobile_service) { app = app_manager_.application(service.connection_key); @@ -240,6 +255,7 @@ void AppServiceManager::GetProviderFromService(const AppService& service, bool AppServiceManager::SetDefaultService(const std::string service_id) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Unable to find published service " << service_id); @@ -254,8 +270,8 @@ bool AppServiceManager::SetDefaultService(const std::string service_id) { if (!default_app_id.empty()) { auto default_service = FindServiceByPolicyAppID(default_app_id, service_type); - if (!default_service.first.empty()) { - default_service.second.default_service = false; + if (default_service) { + default_service->default_service = false; } } service.default_service = true; @@ -268,6 +284,7 @@ bool AppServiceManager::SetDefaultService(const std::string service_id) { bool AppServiceManager::RemoveDefaultService(const std::string service_id) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Unable to find published service " << service_id); @@ -291,6 +308,7 @@ bool AppServiceManager::RemoveDefaultService(const std::string service_id) { bool AppServiceManager::ActivateAppService(const std::string service_id) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Unable to find published service " << service_id); @@ -310,9 +328,9 @@ bool AppServiceManager::ActivateAppService(const std::string service_id) { const std::string service_type = service[strings::service_manifest][strings::service_type].asString(); auto active_service = ActiveServiceByType(service_type); - if (!active_service.first.empty()) { - active_service.second.record[strings::service_active] = false; - AppServiceUpdated(active_service.second.record, + if (active_service) { + active_service->record[strings::service_active] = false; + AppServiceUpdated(active_service->record, mobile_apis::ServiceUpdateReason::DEACTIVATED, msg_params); } @@ -337,6 +355,7 @@ bool AppServiceManager::ActivateAppService(const std::string service_id) { bool AppServiceManager::DeactivateAppService(const std::string service_id) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Unable to find published service " << service_id); @@ -355,9 +374,9 @@ bool AppServiceManager::DeactivateAppService(const std::string service_id) { const std::string service_type = service[strings::service_manifest][strings::service_type].asString(); auto embedded_service = EmbeddedServiceForType(service_type); - if (!embedded_service.first.empty()) { - embedded_service.second.record[strings::service_active] = true; - AppServiceUpdated(embedded_service.second.record, + if (embedded_service) { + embedded_service->record[strings::service_active] = true; + AppServiceUpdated(embedded_service->record, mobile_apis::ServiceUpdateReason::ACTIVATED, msg_params); } @@ -372,54 +391,53 @@ bool AppServiceManager::DeactivateAppService(const std::string service_id) { return true; } -std::pair<std::string, AppService> AppServiceManager::ActiveServiceByType( - std::string service_type) { +AppService* AppServiceManager::ActiveServiceByType(std::string service_type) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); for (auto it = published_services_.begin(); it != published_services_.end(); ++it) { if (it->second.record[strings::service_manifest][strings::service_type] .asString() == service_type && it->second.record[strings::service_published].asBool() && it->second.record[strings::service_active].asBool()) { - return *it; + return &(it->second); } } - AppService empty; - return std::make_pair(std::string(), empty); + return NULL; } -std::pair<std::string, AppService> AppServiceManager::EmbeddedServiceForType( +AppService* AppServiceManager::EmbeddedServiceForType( std::string service_type) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); for (auto it = published_services_.begin(); it != published_services_.end(); ++it) { if (it->second.record[strings::service_manifest][strings::service_type] .asString() == service_type && !it->second.mobile_service) { - return *it; + return &(it->second); } } - AppService empty; - return std::make_pair(std::string(), empty); + return NULL; } -std::pair<std::string, AppService> AppServiceManager::FindServiceByName( - std::string name) { +AppService* AppServiceManager::FindServiceByName(std::string name) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); for (auto it = published_services_.begin(); it != published_services_.end(); ++it) { if (it->second.record[strings::service_manifest][strings::service_name] .asString() == name) { - return *it; + return &(it->second); } } - AppService empty; - return std::make_pair(std::string(), empty); + return NULL; } -std::pair<std::string, AppService> AppServiceManager::FindServiceByPolicyAppID( +AppService* AppServiceManager::FindServiceByPolicyAppID( std::string policy_app_id, std::string type) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); for (auto it = published_services_.begin(); it != published_services_.end(); ++it) { if (it->second.record[strings::service_manifest][strings::service_type] @@ -428,25 +446,22 @@ std::pair<std::string, AppService> AppServiceManager::FindServiceByPolicyAppID( } if (policy_app_id == GetPolicyAppID(it->second)) { - return *it; + return &(it->second); } } - AppService empty; - return std::make_pair(std::string(), empty); + return NULL; } -std::pair<std::string, AppService> AppServiceManager::FindServiceByID( - std::string service_id) { +AppService* AppServiceManager::FindServiceByID(std::string service_id) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Service id does not exist in published services"); - AppService empty; - return std::make_pair(std::string(), empty); + return NULL; } - - return *it; + return &(it->second); } std::string AppServiceManager::DefaultServiceByType(std::string service_type) { @@ -461,6 +476,7 @@ std::string AppServiceManager::DefaultServiceByType(std::string service_type) { void AppServiceManager::SetServicePublished(const std::string service_id, bool service_published) { LOG4CXX_AUTO_TRACE(logger_); + sync_primitives::AutoLock lock(published_services_lock_); auto it = published_services_.find(service_id); if (it == published_services_.end()) { LOG4CXX_ERROR(logger_, "Service id does not exist in published services"); @@ -485,7 +501,7 @@ bool AppServiceManager::UpdateNavigationCapabilities( EnumConversionHelper<mobile_apis::AppServiceType::eType>::EnumToString( mobile_apis::AppServiceType::NAVIGATION, &navi_service_type); auto service = ActiveServiceByType(navi_service_type); - if (service.first.empty()) { + if (!service) { return false; } @@ -496,13 +512,13 @@ bool AppServiceManager::UpdateNavigationCapabilities( out_params[strings::get_way_points_enabled] = false; } - if (!service.second.record[strings::service_manifest].keyExists( + if (!service->record[strings::service_manifest].keyExists( strings::handled_rpcs)) { return true; } smart_objects::SmartObject& handled_rpcs = - service.second.record[strings::service_manifest][strings::handled_rpcs]; + service->record[strings::service_manifest][strings::handled_rpcs]; for (size_t i = 0; i < handled_rpcs.length(); ++i) { if (handled_rpcs[i].asInt() == mobile_apis::FunctionID::SendLocationID) { out_params[strings::send_location_enabled] = true; diff --git a/src/components/application_manager/src/commands/command_request_impl.cc b/src/components/application_manager/src/commands/command_request_impl.cc index c6dbe6972f..8d339d4d14 100644 --- a/src/components/application_manager/src/commands/command_request_impl.cc +++ b/src/components/application_manager/src/commands/command_request_impl.cc @@ -431,12 +431,12 @@ void CommandRequestImpl::SendProviderRequest( std::string service_type = (*msg)[strings::msg_params][strings::service_type].asString(); application_manager_.GetAppServiceManager().GetProviderByType( - service_type, app, hmi_destination); + service_type, true, app, hmi_destination); } else if ((*msg)[strings::msg_params].keyExists(strings::service_id)) { std::string service_id = (*msg)[strings::msg_params][strings::service_id].asString(); application_manager_.GetAppServiceManager().GetProviderByID( - service_id, app, hmi_destination); + service_id, true, app, hmi_destination); } if (hmi_destination) { diff --git a/src/components/application_manager/src/commands/request_from_hmi.cc b/src/components/application_manager/src/commands/request_from_hmi.cc index 823e93cb5e..3c8e75141a 100644 --- a/src/components/application_manager/src/commands/request_from_hmi.cc +++ b/src/components/application_manager/src/commands/request_from_hmi.cc @@ -173,12 +173,12 @@ void RequestFromHMI::SendProviderRequest( std::string service_type = (*msg)[strings::msg_params][strings::service_type].asString(); application_manager_.GetAppServiceManager().GetProviderByType( - service_type, app, hmi_destination); + service_type, false, app, hmi_destination); } else if ((*msg)[strings::msg_params].keyExists(strings::service_id)) { std::string service_id = (*msg)[strings::msg_params][strings::service_id].asString(); application_manager_.GetAppServiceManager().GetProviderByID( - service_id, app, hmi_destination); + service_id, false, app, hmi_destination); } if (hmi_destination) { diff --git a/src/components/interfaces/HMI_API.xml b/src/components/interfaces/HMI_API.xml index 6a7cb8c3d4..3968ef20fb 100644 --- a/src/components/interfaces/HMI_API.xml +++ b/src/components/interfaces/HMI_API.xml @@ -3743,17 +3743,17 @@ </enum> <struct name="AppServiceCapability"> - <param name="updateReason" type="ServiceUpdateReason" mandatory="false"> + <param name="updateReason" type="Common.ServiceUpdateReason" mandatory="false"> <description> Only included in OnSystemCapabilityUpdated. Update reason for service record.</description> </param> - <param name="updatedAppServiceRecord" type="AppServiceRecord" mandatory="true"> + <param name="updatedAppServiceRecord" type="Common.AppServiceRecord" mandatory="true"> <description>Service record for a specific app service provider</description> </param> </struct> <struct name="AppServicesCapabilities"> <description>Capabilities of app services including what service types are supported and the current state of services.</description> - <param name="appServices" type="AppServiceCapability" array="true" mandatory="false"> + <param name="appServices" type="Common.AppServiceCapability" array="true" mandatory="false"> <description>An array of currently available services. If this is an update to the capability the affected services will include an update reason in that item</description> </param> </struct> @@ -3771,22 +3771,22 @@ <struct name="SystemCapabilities"> <description>The systemCapabilityType identifies which data object exists in this struct. For example, if the SystemCapability Type is NAVIGATION then a "navigationCapability" should exist</description> - <param name="systemCapabilityType" type="SystemCapabilityType" mandatory="true"> + <param name="systemCapabilityType" type="Common.SystemCapabilityType" mandatory="true"> <description>Used as a descriptor of what data to expect in this struct. The corresponding param to this enum should be included and the only other para included.</description> </param> - <param name="navigationCapability" type="NavigationCapability" mandatory="false"> + <param name="navigationCapability" type="Common.NavigationCapability" mandatory="false"> <description>Describes extended capabilities for onboard navigation system </description> </param> - <param name="phoneCapability" type="PhoneCapability" mandatory="false"> + <param name="phoneCapability" type="Common.PhoneCapability" mandatory="false"> <description>Describes extended capabilities of the module's phone feature</description> </param> - <param name="videoStreamingCapability" type="VideoStreamingCapability" mandatory="false"> + <param name="videoStreamingCapability" type="Common.VideoStreamingCapability" mandatory="false"> <description>Describes extended capabilities of the module's phone feature</description> </param> - <param name="remoteControlCapability" type="RemoteControlCapabilities" mandatory="false"> + <param name="remoteControlCapability" type="Common.RemoteControlCapabilities" mandatory="false"> <description>Describes extended capabilities of the module's phone feature</description> </param> - <param name="appServicesCapabilities" type="AppServicesCapabilities" mandatory="false"> + <param name="appServicesCapabilities" type="Common.AppServicesCapabilities" mandatory="false"> <description>An array of currently available services. If this is an update to the capability the affected services will include an update reason in that item</description> </param> </struct> |