Add the new verifypw command to vold/cryptfs
This vold command returns 0 if the given password matches the password
used to decrypt the device on boot. It returns 1 if they don't match,
and it returns -1 on an internal error, and -2 if the device is not encrypted.
Also check the uid of the sender of the command and only allow the root and
system users to issue cryptfs commands.
Change-Id: I5e5ae3b72a2d7814ae68c2d49aa9deb90fb1dac5
diff --git a/ResponseCode.h b/ResponseCode.h
index a858b99..402e35b 100644
--- a/ResponseCode.h
+++ b/ResponseCode.h
@@ -48,6 +48,7 @@
// action did not take place.
static const int CommandSyntaxError = 500;
static const int CommandParameterError = 501;
+ static const int CommandNoPermission = 502;
// 600 series - Unsolicited broadcasts
static const int UnsolicitedInformational = 600;