summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2019-06-09 16:02:02 +0200
committerDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2019-06-09 16:54:17 +0200
commit16cb5e347fdb45a8529579365f2d8c405c5e90cf (patch)
treec226468fcc736ee5c283ed4ed1985ea579d79bde
parente6a056d93fcaf5d1f2e711b10b4b6532035456a3 (diff)
downloadsystem_core-history/14-07-2019.tar.gz
system_core-history/14-07-2019.tar.bz2
system_core-history/14-07-2019.zip
HACK: gatekeeperd: force software imeplementationhistory/14-07-2019
Without that hack, IGatekeeper::getService() will try to get a service implementing the Gatekeeper HAL. The HAL is supposed to talk to a component that resides in a Trusted Execution Environment (TEE) such as MobiCore. On many Android device, the Trusted Execution Environment is not free software, nor under the control of the user, so it cannot be trusted by the user, and in fact it's better, if possible, to make sure that it does not to run at all in that case. Because of that the proper fix would be either to implement a Gatekeeper HAL that would not depend on nonfree software that cannot be trusted. This could for instance be implemented by: * Using a simple software implementation. * Using the linux kernel keyring for that which can provide good resilience against userspace trying to get key material. See man 7 keyrings for more information on that. * Have a free software Trusted Execution Environment like Google's Trusty or other implementations. See the following documentation for more background information: https://source.android.com/security/authentication/gatekeeper Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
-rw-r--r--gatekeeperd/gatekeeperd.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/gatekeeperd/gatekeeperd.cpp b/gatekeeperd/gatekeeperd.cpp
index 578176578..40a15af13 100644
--- a/gatekeeperd/gatekeeperd.cpp
+++ b/gatekeeperd/gatekeeperd.cpp
@@ -58,12 +58,9 @@ class GateKeeperProxy : public BnGateKeeperService {
public:
GateKeeperProxy() {
clear_state_if_needed_done = false;
- hw_device = IGatekeeper::getService();
-
- if (hw_device == nullptr) {
- ALOGW("falling back to software GateKeeper");
- soft_device.reset(new SoftGateKeeperDevice());
- }
+ ALOGW("Using hacked built-in software GateKeeper");
+ ALOGW("FIXME: Use proper software implementation instead");
+ soft_device.reset(new SoftGateKeeperDevice());
}
virtual ~GateKeeperProxy() {