From: sangwan.kwon Date: Mon, 24 Jul 2017 08:54:37 +0000 (+0900) Subject: Revert "Add CryptsetupEngine" X-Git-Tag: submit/tizen/20170724.094119~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=842d4ed10985953d402ff43e55fe2798656edd18;p=platform%2Fcore%2Fsecurity%2Fode.git Revert "Add CryptsetupEngine" - Since arch64 build failed, this commit be reverted. This reverts commit 0ec77b9d13e306ef2846c9ef7de8fd3888878e2b. Conflicts: server/engine/encryption/cryptsetup-engine.cpp Change-Id: I166fcafa9aa24e9d3076ec8f6a39041fb42f7719 --- diff --git a/packaging/ode.spec b/packaging/ode.spec index fe3f58f..75181d7 100755 --- a/packaging/ode.spec +++ b/packaging/ode.spec @@ -19,7 +19,6 @@ BuildRequires: pkgconfig(key-manager) BuildRequires: pkgconfig(cynara-client) BuildRequires: pkgconfig(cynara-session) BuildRequires: pkgconfig(openssl) -BuildRequires: pkgconfig(libcryptsetup) %description The ode package provides a daemon which is responsible for encrypting/decryption storages and secure erasing. diff --git a/server/CMakeLists.txt b/server/CMakeLists.txt index 7c0ee26..4b781c2 100644 --- a/server/CMakeLists.txt +++ b/server/CMakeLists.txt @@ -29,7 +29,6 @@ SET(SERVER_SRCS main.cpp engine/encryption/ext4-engine.cpp engine/encryption/dmcrypt-engine.cpp engine/encryption/ecryptfs-engine.cpp - engine/encryption/cryptsetup-engine.cpp engine/erase/mmc-engine.cpp key-manager/key-store.cpp key-manager/key-manager.cpp @@ -46,7 +45,6 @@ SET(DEPENDENCY klay cynara-client cynara-session openssl - libcryptsetup ) SET(SERVER_NAME ${PROJECT_NAME}d) diff --git a/server/engine/encryption/cryptsetup-engine.h b/server/engine/encryption/cryptsetup-engine.h deleted file mode 100644 index 55c4658..0000000 --- a/server/engine/encryption/cryptsetup-engine.h +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) 2017 Samsung Electronics Co., Ltd All Rights Reserved - * - * 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 - */ - -#ifndef __CRYPTSETUP_ENGINE_H__ -#define __CRYPTSETUP_ENGINE_H__ - -#include -#include - -namespace ode { - -class CryptsetupEngine final { -public: - enum class DeviceType { - PLAIN, - LUKS, - }; - - CryptsetupEngine(const std::string &devicePath); - CryptsetupEngine(const CryptsetupEngine &) = delete; - CryptsetupEngine(CryptsetupEngine &&) = delete; - ~CryptsetupEngine(); - - CryptsetupEngine &operator=(const CryptsetupEngine &) = delete; - CryptsetupEngine &operator=(CryptsetupEngine &&) = delete; - - // TODO make it common among engines - typedef std::vector data; - - void format(DeviceType type, const data &key); - - // create new mapping, returns mapping path - std::string open(DeviceType type, const std::string &name, const data &key); - - static void close(const std::string &name); - - bool isKeyMetaSet(); - const data getKeyMeta(); - void setKeyMeta(const data &data); - void clearKeyMeta(); - -private: - std::string devPath; -}; - -} // namespace ode -#endif // __CRYPTSETUP_ENGINE_H__