am c6d5cd18: Merge "[gatekeeperd] verify a password after enrolling successfully" into mnc-dev
* commit 'c6d5cd18f86aa78b769ba06e43963231f05bc809':
[gatekeeperd] verify a password after enrolling successfully
diff --git a/gatekeeperd/gatekeeperd.cpp b/gatekeeperd/gatekeeperd.cpp
index ad16fa5..c0f2279 100644
--- a/gatekeeperd/gatekeeperd.cpp
+++ b/gatekeeperd/gatekeeperd.cpp
@@ -136,6 +136,12 @@
gatekeeper::password_handle_t *handle =
reinterpret_cast<gatekeeper::password_handle_t *>(*enrolled_password_handle);
store_sid(uid, handle->user_id);
+ bool rr;
+
+ // immediately verify this password so we don't ask the user to enter it again
+ // if they just created it.
+ verify(uid, *enrolled_password_handle, sizeof(password_handle_t), desired_password,
+ desired_password_length, &rr);
}
return ret;