DeviceManager is added.
authorDuyoung Jang <duyoung.jang@samsung.com>
Wed, 7 Aug 2013 02:58:45 +0000 (11:58 +0900)
committerDuyoung Jang <duyoung.jang@samsung.com>
Wed, 7 Aug 2013 02:58:45 +0000 (11:58 +0900)
Change-Id: I4d54d10475694e92389b32b97013542eaee30212
Signed-off-by: Duyoung Jang <duyoung.jang@samsung.com>
CMakeLists.txt
inc/InstallerDefs.h
src/Manager/ConfigurationManager.cpp
src/Manager/DeviceManager.cpp [new file with mode: 0755]
src/Manager/DeviceManager.h [new file with mode: 0755]
src/Step/SystemCheckStep.cpp
src/Step/SystemCheckStep.h
src/Step/UninstallStep.cpp
src/Step/UninstallStep.h [changed mode: 0644->0755]
src/Util/InstallerUtil.cpp
src/Util/InstallerUtil.h

index 6e700d7..9572ea4 100755 (executable)
@@ -47,6 +47,7 @@ SET (${this_target}_SOURCE_FILES
        src/Manager/CompatibilityManager.cpp
        src/Manager/ConfigurationManager.cpp
        src/Manager/DatabaseManager.cpp
+       src/Manager/DeviceManager.cpp
        src/Manager/InstallerManager.cpp
        src/Manager/PermissionManager.cpp
        src/Manager/SignatureManager.cpp
index d540d24..991aa4c 100755 (executable)
@@ -23,7 +23,7 @@
 
 #include "InstallerUtil.h"
 
-#define OSP_INSTALLER_VERSION "version=[20130806.1]"
+#define OSP_INSTALLER_VERSION "version=[20130807.1]"
 
 #define DIR_BIN                                L"/bin"
 #define DIR_INFO                       L"/info"
@@ -256,6 +256,9 @@ enum InstallerError
        INSTALLER_ERROR_FATAL_ERROR = 61,
        INSTALLER_ERROR_OUT_OF_STORAGE = 62,
        INSTALLER_ERROR_OUT_OF_MEMORY = 63,
+       INSTALLER_ERROR_DISABLED = 65,
+       INSTALLER_ERROR_PRIVILEGE_BLACKLIST = 66,
+       INSTALLER_ERROR_SIGNATURE_BLACKLIST = 67,
 
        INSTALLER_ERROR_USER_CANCEL = 141,
        INSTALLER_ERROR_UNMOUNT_FAILED = 142,
index 4932df1..0a89046 100755 (executable)
@@ -556,28 +556,28 @@ ConfigurationManager::CopyData(InstallationContext* pContext) const
        // data
        srcPath = backupPath + DIR_DATA;
        destPath = rootPath + DIR_DATA;
-       InstallerUtil::CopyDirectory(srcPath, destPath);
+       InstallerUtil::CopyDirectory(srcPath, destPath, true);
        InstallerUtil::ChangeDirectoryPermission(destPath, PERM_BASE, true);
        smackManager.SetupPath(packageId, destPath, SMACK_DIR_TYPE_PRIVATE);
 
        // setting
        srcPath = backupPath + DIR_SETTING;
        destPath = rootPath + DIR_SETTING;
-       InstallerUtil::CopyDirectory(srcPath, destPath);
+       InstallerUtil::CopyDirectory(srcPath, destPath, true);
        InstallerUtil::ChangeDirectoryPermission(destPath, PERM_BASE | PERM_WRITE, false);
        smackManager.SetupPath(packageId, destPath, SMACK_DIR_TYPE_SETTINGS_RW);
 
        // shared/data
        srcPath = backupPath + DIR_SHARED_DATA;
        destPath = rootPath + DIR_SHARED_DATA;
-       InstallerUtil::CopyDirectory(srcPath, destPath);
+       InstallerUtil::CopyDirectory(srcPath, destPath, true);
        InstallerUtil::ChangeDirectoryPermission(destPath, PERM_BASE, true);
        smackManager.SetupPath(packageId, destPath, SMACK_DIR_TYPE_PUBLIC_RO);
 
        // shared/trust
        srcPath = backupPath + DIR_SHARED_TRUSTED;
        destPath = rootPath + DIR_SHARED_TRUSTED;
-       InstallerUtil::CopyDirectory(srcPath, destPath);
+       InstallerUtil::CopyDirectory(srcPath, destPath, true);
        InstallerUtil::ChangeDirectoryPermission(destPath, PERM_BASE, true);
        smackManager.SetupPath(packageId, destPath, SMACK_DIR_TYPE_GROUP_RW);
 
diff --git a/src/Manager/DeviceManager.cpp b/src/Manager/DeviceManager.cpp
new file mode 100755 (executable)
index 0000000..5ecfb40
--- /dev/null
@@ -0,0 +1,315 @@
+//
+// Open Service Platform
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// 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.
+//
+/**
+ * @file       DeviceManager.cpp
+ * @brief      This is the implementation file for %DeviceManager class.
+ */
+
+#include <dlfcn.h>
+#include <unique_ptr.h>
+
+#include <FIoRegistry.h>
+#include <FBase_StringConverter.h>
+
+#include "DeviceManager.h"
+#include "InstallerDefs.h"
+
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
+using namespace Tizen::Io;
+
+DeviceManager::DeviceManager(void)
+:__pContext(null)
+,__isMdmEnable(false)
+{
+       if (IsMdmEnable() == true)
+       {
+               __isMdmEnable = true;
+       }
+}
+
+DeviceManager::~DeviceManager(void)
+{
+       if (__isMdmEnable == true)
+       {
+               ReleaseService();
+       }
+}
+
+bool
+DeviceManager::Construct(InstallationContext* pContext)
+{
+       __pContext = pContext;
+
+       return true;
+}
+
+bool
+DeviceManager::IsInstallationDisabled() const
+{
+       if (__isMdmEnable == false)
+       {
+               return false;
+       }
+
+       TryReturn(__pContext, false, "__pContext is null.");
+       TryReturn(__pContext->__packageId.IsEmpty() == false, false, "packageId is empty.");
+
+       std::unique_ptr<char[]> pPackageId(_StringConverter::CopyToCharArrayN(__pContext->__packageId));
+       TryReturn(pPackageId, false, "pPackageId is null.");
+
+       int res = IsInstallationDisabled(pPackageId.get());
+       if (res == 1)
+       {
+               AppLog("[%s] can't be installed.", pPackageId.get());
+               return true;
+       }
+       else
+       {
+               AppLog("[%s] can be installed.", pPackageId.get());
+               return false;
+       }
+}
+
+bool
+DeviceManager::IsUninstallationDisabled() const
+{
+       if (__isMdmEnable == false)
+       {
+               return false;
+       }
+
+       TryReturn(__pContext, false, "__pContext is null.");
+       TryReturn(__pContext->__packageId.IsEmpty() == false, false, "packageId is empty.");
+
+       std::unique_ptr<char[]> pPackageId(_StringConverter::CopyToCharArrayN(__pContext->__packageId));
+       TryReturn(pPackageId, false, "pPackageId is null.");
+
+       int res = IsUninstallationDisabled(pPackageId.get());
+       if (res == 1)
+       {
+               AppLog("[%s] can't be uninstalled.", pPackageId.get());
+               return true;
+       }
+       else
+       {
+               AppLog("[%s] can be uninstalled.", pPackageId.get());
+               return false;
+       }
+}
+
+bool
+DeviceManager::IsPrivilegeBlacklist() const
+{
+       if (__isMdmEnable == false)
+       {
+               return true;
+       }
+
+       TryReturn(__pContext, false, "__pContext is null.");
+       TryReturn(__pContext->__pPrivilegeList, false, "pPrivilegeList is null.");
+
+       return IsPrivilegeBlacklist(__pContext->__pPrivilegeList);
+}
+
+bool
+DeviceManager::IsSignatureBlacklist() const
+{
+       if (__isMdmEnable == false)
+       {
+               return true;
+       }
+
+       TryReturn(__pContext, false, "__pContext is null.");
+       TryReturn(__pContext->__pAuthorCertList, false, "pAuthorCertList is null.");
+
+       return IsSignatureBlacklist(__pContext->__pAuthorCertList);
+}
+
+bool
+DeviceManager::IsMdmEnable() const
+{
+       result r;
+       Registry reg;
+       String section(L"feature");
+       String entry(L"mdm");
+       String value;
+
+       r = reg.Construct(CONFIG_PATH, "r");
+       TryReturn(!IsFailed(r), false, "CONFIG file is not found.");
+
+       r = reg.GetValue(section, entry, value);
+       TryReturn(!IsFailed(r), false, "GetValue is failed. entry = [%ls]", entry.GetPointer());
+
+       AppLog("[%ls is %ls.]", entry.GetPointer(), value.GetPointer());
+
+       if (value == L"on")
+       {
+               if (GetService() == 0)
+               {
+                       return true;
+               }
+       }
+
+       return false;
+}
+
+int
+DeviceManager::GetService() const
+{
+       int ret = 0;
+       void* pHandle = null;
+       char* pErrorMsg = null;
+       int (*mdm_get_service)(void) = null;
+
+       pHandle = dlopen("/usr/lib/libmdm.so.1", RTLD_LAZY | RTLD_GLOBAL);
+       if (!pHandle)
+       {
+               AppLog("dlopen() failed. [%s]", dlerror());
+               return -1;
+       }
+
+       mdm_get_service = reinterpret_cast <int (*)(void)>(dlsym(pHandle, "mdm_get_service"));
+       pErrorMsg = dlerror();
+       if ((pErrorMsg != null) || (mdm_get_service == null))
+       {
+               AppLog("dlsym() failed. [%s]", pErrorMsg);
+               dlclose(pHandle);
+               return -1;
+       }
+
+       AppLog("[mdm] mdm_get_service()");
+       ret = mdm_get_service();
+       AppLog("[mdm] mdm_get_service, result = [%d]", ret);
+
+       dlclose(pHandle);
+
+       return ret;
+}
+
+int
+DeviceManager::ReleaseService() const
+{
+       int ret = 0;
+       void* pHandle = null;
+       char* pErrorMsg = null;
+       int (*mdm_release_service)(void) = null;
+
+       pHandle = dlopen("/usr/lib/libmdm.so.1", RTLD_LAZY | RTLD_GLOBAL);
+       if (!pHandle)
+       {
+               AppLog("dlopen() failed. [%s]", dlerror());
+               return -1;
+       }
+
+       mdm_release_service = reinterpret_cast <int (*)(void)>(dlsym(pHandle, "mdm_release_service"));
+       pErrorMsg = dlerror();
+       if ((pErrorMsg != null) || (mdm_release_service == null))
+       {
+               AppLog("dlsym() failed. [%s]", pErrorMsg);
+               dlclose(pHandle);
+               return -1;
+       }
+
+       AppLog("[mdm] mdm_release_service()");
+       ret = mdm_release_service();
+       AppLog("[mdm] mdm_release_service, result = [%d]", ret);
+
+       dlclose(pHandle);
+
+       return ret;
+}
+
+int
+DeviceManager::IsInstallationDisabled(const char* pPackageId) const
+{
+       int ret = 0;
+       void* pHandle = null;
+       char* pErrorMsg = null;
+       int (*mdm_get_application_installation_disabled)(const char*) = null;
+
+       pHandle = dlopen("/usr/lib/libmdm.so.1", RTLD_LAZY | RTLD_GLOBAL);
+       if (!pHandle)
+       {
+               AppLog("dlopen() failed. [%s]", dlerror());
+               return -1;
+       }
+
+       mdm_get_application_installation_disabled = reinterpret_cast <int (*)(const char*)>(dlsym(pHandle, "mdm_get_application_installation_disabled"));
+       pErrorMsg = dlerror();
+       if ((pErrorMsg != null) || (mdm_get_application_installation_disabled == null))
+       {
+               AppLog("dlsym() failed. [%s]", pErrorMsg);
+               dlclose(pHandle);
+               return -1;
+       }
+
+       AppLog("[mdm] mdm_get_application_installation_disabled(%s)", pPackageId);
+       ret = mdm_get_application_installation_disabled(pPackageId);
+       AppLog("[mdm] mdm_get_application_installation_disabled(%s), result = [%d]", pPackageId, ret);
+
+       dlclose(pHandle);
+
+       return ret;
+}
+
+int
+DeviceManager::IsUninstallationDisabled(const char* pPackageId) const
+{
+       int ret = 0;
+       void* pHandle = null;
+       char* pErrorMsg = null;
+       int (*mdm_get_application_uninstallation_disabled)(const char*) = null;
+
+       pHandle = dlopen("/usr/lib/libmdm.so.1", RTLD_LAZY | RTLD_GLOBAL);
+       if (!pHandle)
+       {
+               AppLog("dlopen() failed. [%s]", dlerror());
+               return -1;
+       }
+
+       mdm_get_application_uninstallation_disabled = reinterpret_cast <int (*)(const char*)>(dlsym(pHandle, "mdm_get_application_uninstallation_disabled"));
+       pErrorMsg = dlerror();
+       if ((pErrorMsg != null) || (mdm_get_application_uninstallation_disabled == null))
+       {
+               AppLog("dlsym() failed. [%s]", pErrorMsg);
+               dlclose(pHandle);
+               return -1;
+       }
+
+       AppLog("[mdm] mdm_get_application_uninstallation_disabled(%s)", pPackageId);
+       ret = mdm_get_application_uninstallation_disabled(pPackageId);
+       AppLog("[mdm] mdm_get_application_uninstallation_disabled(%s), result = [%d]", pPackageId, ret);
+
+       dlclose(pHandle);
+
+       return ret;
+}
+
+bool
+DeviceManager::IsPrivilegeBlacklist(ArrayList* pPrivilegeList) const
+{
+       //mdm_data_t *mdm_get_app_privilege_blacklist(void);
+       return true;
+}
+
+bool
+DeviceManager::IsSignatureBlacklist(IListT<String *>* pSignatureList) const
+{
+       //mdm_data_t *mdm_get_app_signature_blacklist(void);
+       return true;
+}
diff --git a/src/Manager/DeviceManager.h b/src/Manager/DeviceManager.h
new file mode 100755 (executable)
index 0000000..5a9f731
--- /dev/null
@@ -0,0 +1,57 @@
+//
+// Open Service Platform
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// 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.
+//
+/**
+ * @file       DeviceManager.h
+ * @brief      This is the header file for the %DeviceManager class.
+ *
+ * This header file contains the declarations of the %DeviceManager class.
+ */
+#ifndef _DEVICE_MANAGER_H_
+#define _DEVICE_MANAGER_H_
+
+#include "InstallationContext.h"
+
+class DeviceManager
+{
+public:
+       DeviceManager(void);
+       virtual ~DeviceManager(void);
+       bool Construct(InstallationContext* pContext);
+
+       bool IsInstallationDisabled() const;
+       bool IsUninstallationDisabled() const;
+       bool IsPrivilegeBlacklist() const;
+       bool IsSignatureBlacklist() const;
+
+private:
+       bool IsMdmEnable() const;
+       int GetService() const;
+       int ReleaseService() const;
+
+       int IsInstallationDisabled(const char* pPackageId) const;
+       int IsUninstallationDisabled(const char* pPackageId) const;
+       bool IsPrivilegeBlacklist(Tizen::Base::Collection::ArrayList* pPrivilegeList) const;
+       bool IsSignatureBlacklist(Tizen::Base::Collection::IListT<Tizen::Base::String *>* pSignatureList) const;
+
+private:
+       InstallationContext* __pContext;
+       bool __isMdmEnable;
+
+
+}; // DeviceManager
+
+#endif // _DEVICE_MANAGER_H_
index a1d2488..cfc7651 100755 (executable)
@@ -29,6 +29,7 @@
 #include "SystemCheckStep.h"
 #include "ConfigurationManager.h"
 #include "DatabaseManager.h"
+#include "DeviceManager.h"
 
 using namespace Tizen::App;
 using namespace Tizen::App::Package;
@@ -36,7 +37,7 @@ using namespace Tizen::Base;
 using namespace Tizen::Base::Collection;
 
 SystemCheckStep::SystemCheckStep(void)
-:__state(STATE_VERSION_CHECK)
+:__state(STATE_POLICY_CHECK)
 ,__pContext(null)
 {
 }
@@ -56,6 +57,10 @@ SystemCheckStep::Run(InstallationContext* pContext)
        {
                switch (__state)
                {
+               case STATE_POLICY_CHECK:
+                       error = OnStatePolicyCheck();
+                       break;
+
                case STATE_VERSION_CHECK:
                        error = OnStateVersionCheck();
                        break;
@@ -64,10 +69,6 @@ SystemCheckStep::Run(InstallationContext* pContext)
                        error = OnStateBackup();
                        break;
 
-               case STATE_AGENT_TIMER:
-                       error = OnStateAgentTimer();
-                       break;
-
                case STATE_DONE:
                        error = OnStateDone();
                        break;
@@ -97,6 +98,21 @@ SystemCheckStep::GoNextState(void)
 }
 
 InstallerError
+SystemCheckStep::OnStatePolicyCheck(void)
+{
+       InstallerError error = INSTALLER_ERROR_NONE;
+
+       DeviceManager deviceManager;
+       deviceManager.Construct(__pContext);
+
+       bool res = deviceManager.IsInstallationDisabled();
+       TryReturn(res == false, INSTALLER_ERROR_DISABLED, "IsInstallationDisabled() failed.");
+
+       GoNextState();
+       return error;
+}
+
+InstallerError
 SystemCheckStep::OnStateVersionCheck(void)
 {
        InstallerError error = INSTALLER_ERROR_NONE;
@@ -185,15 +201,6 @@ SystemCheckStep::OnStateBackup(void)
 }
 
 InstallerError
-SystemCheckStep::OnStateAgentTimer(void)
-{
-       InstallerError error = INSTALLER_ERROR_NONE;
-
-       GoNextState();
-       return error;
-}
-
-InstallerError
 SystemCheckStep::OnStateDone(void)
 {
        InstallerError error = INSTALLER_ERROR_NONE;
index 6dddf49..c09adcd 100755 (executable)
@@ -45,9 +45,9 @@ public:
 private:
        enum
        {
+               STATE_POLICY_CHECK,
                STATE_VERSION_CHECK,
                STATE_BACKUP,
-               STATE_AGENT_TIMER,
                STATE_DONE
        };
 
@@ -60,9 +60,9 @@ private:
        };
 
        void GoNextState(void);
+       InstallerError OnStatePolicyCheck(void);
        InstallerError OnStateVersionCheck(void);
        InstallerError OnStateBackup(void);
-       InstallerError OnStateAgentTimer(void);
        InstallerError OnStateDone(void);
 
        int CompareVersion(const Tizen::Base::String& oldVersion, const Tizen::Base::String& newVersion);
index 510b0f1..55306e8 100755 (executable)
@@ -32,6 +32,7 @@
 #include "UninstallStep.h"
 #include "InstallerUtil.h"
 #include "CompatibilityManager.h"
+#include "DeviceManager.h"
 
 using namespace Tizen::Base;
 using namespace Tizen::Base::Collection;
@@ -66,9 +67,9 @@ UninstallStep::Run(InstallationContext* pContext)
                        error = OnStateGetPackageInfo();
                        break;
 
-               case STATE_CHECK_APP_RUNNING:
-                       AppLog("[STATE_CHECK_APP_RUNNING]");
-                       error = OnStateCheckAppRunning();
+               case STATE_POLICY_CHECK:
+                       AppLog("[STATE_POLICY_CHECK]");
+                       error = OnStatePolicyCheck();
                        break;
 
                case STATE_TERMINATE_APP:
@@ -195,17 +196,21 @@ UninstallStep::OnStateGetPackageInfo(void)
        }
        delete pList;
 
-       __state = STATE_TERMINATE_APP;
-
+       GoNextState();
        return error;
 }
 
-
 InstallerError
-UninstallStep::OnStateCheckAppRunning(void)
+UninstallStep::OnStatePolicyCheck(void)
 {
        InstallerError error = INSTALLER_ERROR_NONE;
 
+       DeviceManager deviceManager;
+       deviceManager.Construct(__pContext);
+
+       bool res = deviceManager.IsUninstallationDisabled();
+       TryReturn(res == false, INSTALLER_ERROR_DISABLED, "IsUninstallationDisabled() failed.");
+
        GoNextState();
        return error;
 }
old mode 100644 (file)
new mode 100755 (executable)
index ca97334..0fbb2d4
@@ -46,7 +46,7 @@ private:
        enum
        {
                STATE_GET_PACKAGEINFO,
-               STATE_CHECK_APP_RUNNING,
+               STATE_POLICY_CHECK,
                STATE_TERMINATE_APP,
                STATE_START_TIMER,
                STATE_DELETE_DIR,
@@ -55,7 +55,7 @@ private:
 
        void GoNextState(void);
        InstallerError OnStateGetPackageInfo(void);
-       InstallerError OnStateCheckAppRunning(void);
+       InstallerError OnStatePolicyCheck(void);
        InstallerError OnStateTerminateApp(void);
        InstallerError OnStateStartTimer(void);
        InstallerError OnStateRemoveDir(void);
index 8381c57..5e71acd 100755 (executable)
@@ -101,13 +101,20 @@ InstallerUtil::Remove(const Tizen::Base::String& filePath)
 }
 
 bool
-InstallerUtil::Copy(const String& srcFilePath, const String& destFilePath)
+InstallerUtil::Copy(const String& srcFilePath, const String& destFilePath, bool failIfExist)
 {
        int bufSize = 4096;
        int readBytes = 0;
        result r = E_SUCCESS;
 
-       // AppLog("+ Copy(): src=[%ls], dest=[%ls]", srcFilePath.GetPointer(), destFilePath.GetPointer());
+       if (failIfExist == true)
+       {
+               if (File::IsFileExist(destFilePath) == true)
+               {
+                       AppLog("Copy(): des=[%ls]: skip", destFilePath.GetPointer());
+                       return true;
+               }
+       }
 
        File srcFile;
        File destFile;
@@ -136,7 +143,7 @@ InstallerUtil::Copy(const String& srcFilePath, const String& destFilePath)
 }
 
 bool
-InstallerUtil::CopyDirectory(const String& srcFilePath, const String& destFilePath)
+InstallerUtil::CopyDirectory(const String& srcFilePath, const String& destFilePath, bool failIfExist)
 {
        result r = E_SUCCESS;
        bool res = false;
@@ -185,12 +192,12 @@ InstallerUtil::CopyDirectory(const String& srcFilePath, const String& destFilePa
                {
                        // file
                        Directory::Create(destFilePath, true);
-                       InstallerUtil::Copy(srcEntryDir, destEntryDir);
+                       InstallerUtil::Copy(srcEntryDir, destEntryDir, failIfExist);
                }
                else
                {
                        Directory::Create(destEntryDir, true);
-                       CopyDirectory(srcEntryDir, destEntryDir);
+                       CopyDirectory(srcEntryDir, destEntryDir, failIfExist);
                }
        }
 
index 9293210..253a52b 100755 (executable)
@@ -51,8 +51,8 @@ public:
        virtual ~InstallerUtil(void);
 
        static bool Remove(const Tizen::Base::String& filePath);
-       static bool Copy(const Tizen::Base::String& srcFilePath, const Tizen::Base::String& destFilePath);
-       static bool CopyDirectory(const Tizen::Base::String& srcFilePath, const Tizen::Base::String& destFilePath);
+       static bool Copy(const Tizen::Base::String& srcFilePath, const Tizen::Base::String& destFilePath, bool failIfExist = false);
+       static bool CopyDirectory(const Tizen::Base::String& srcFilePath, const Tizen::Base::String& destFilePath, bool failIfExist = false);
        static bool IsSymlink(const Tizen::Base::String& filePath);
        static bool GetRealPath(const Tizen::Base::String& filePath, Tizen::Base::String& realPath);