From 76adfc5309936a07218ce53b5ab284d5746fa84c Mon Sep 17 00:00:00 2001 From: Doug Zongker Date: Mon, 13 Jan 2014 10:04:25 -0800 Subject: program to store unencrypted files in an encrypted filesystem uncrypt can read a file on an encrypted filesystem and rewrite it to the same blocks on the underlying (unencrypted) block device. This destroys the contents of the file as far as the encrypted filesystem is concerned, but allows the data to be read without the encryption key if you know which blocks of the raw device to access. uncrypt produces a "block map" file which lists the blocks that contain the file. For unencrypted filesystem, uncrypt will produce the block map without touching the data. Bug: 12188746 Change-Id: Ib7259b9e14dac8af406796b429d58378a00c7c63 --- uncrypt/Android.mk | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 uncrypt/Android.mk (limited to 'uncrypt/Android.mk') diff --git a/uncrypt/Android.mk b/uncrypt/Android.mk new file mode 100644 index 000000000..756bc964c --- /dev/null +++ b/uncrypt/Android.mk @@ -0,0 +1,28 @@ +# Copyright (C) 2014 The Android Open Source Project +# +# 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. + +LOCAL_PATH := $(call my-dir) + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := uncrypt.c + +LOCAL_MODULE := uncrypt + +LOCAL_STATIC_LIBRARIES := \ + libfs_mgr \ + libcutils \ + libc + +include $(BUILD_EXECUTABLE) -- cgit v1.2.3 From 537d34f907a5e984ccad1c88825adc8ae9814834 Mon Sep 17 00:00:00 2001 From: Doug Zongker Date: Thu, 14 Aug 2014 07:59:28 -0700 Subject: change uncrypt to static linking Bug: 17015157 Change-Id: I3c4bdcf4f11d44b617bb731a48413e3707044d1c --- uncrypt/Android.mk | 2 ++ 1 file changed, 2 insertions(+) (limited to 'uncrypt/Android.mk') diff --git a/uncrypt/Android.mk b/uncrypt/Android.mk index 756bc964c..ef3cead34 100644 --- a/uncrypt/Android.mk +++ b/uncrypt/Android.mk @@ -25,4 +25,6 @@ LOCAL_STATIC_LIBRARIES := \ libcutils \ libc +LOCAL_FORCE_STATIC_EXECUTABLE := true + include $(BUILD_EXECUTABLE) -- cgit v1.2.3 From 1a35a586904cd429fd3a6a6c2de64a16ccdf693d Mon Sep 17 00:00:00 2001 From: Doug Zongker Date: Thu, 14 Aug 2014 10:29:54 -0700 Subject: revert uncrypt back to dynamic linking, fix libs Bug: 17029174, 17015157 Change-Id: I1d24f3402875dfb972daa6daef0f385baeff84e9 --- uncrypt/Android.mk | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'uncrypt/Android.mk') diff --git a/uncrypt/Android.mk b/uncrypt/Android.mk index ef3cead34..8d0a7376e 100644 --- a/uncrypt/Android.mk +++ b/uncrypt/Android.mk @@ -20,11 +20,6 @@ LOCAL_SRC_FILES := uncrypt.c LOCAL_MODULE := uncrypt -LOCAL_STATIC_LIBRARIES := \ - libfs_mgr \ - libcutils \ - libc - -LOCAL_FORCE_STATIC_EXECUTABLE := true +LOCAL_STATIC_LIBRARIES := libfs_mgr libcutils include $(BUILD_EXECUTABLE) -- cgit v1.2.3 From f449db2f30235a0c2fef4bc7bc41776e271a60a0 Mon Sep 17 00:00:00 2001 From: Doug Zongker Date: Tue, 26 Aug 2014 09:15:08 -0700 Subject: open misc device in write-only mode Opening the misc block device in read-write mode runs afoul of SELinux, which keeps the wipe code from working. Fix. Also change various things to log to logcat so we can see them happening, for future debugging. Bug: 16715412 Change-Id: Ia14066f0a371cd605fcb544547b58a41acca70b9 --- uncrypt/Android.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'uncrypt/Android.mk') diff --git a/uncrypt/Android.mk b/uncrypt/Android.mk index 8d0a7376e..878d2757e 100644 --- a/uncrypt/Android.mk +++ b/uncrypt/Android.mk @@ -20,6 +20,6 @@ LOCAL_SRC_FILES := uncrypt.c LOCAL_MODULE := uncrypt -LOCAL_STATIC_LIBRARIES := libfs_mgr libcutils +LOCAL_STATIC_LIBRARIES := libfs_mgr liblog libcutils include $(BUILD_EXECUTABLE) -- cgit v1.2.3