Remove boot password from the command line I just tried to remove the boot password on a Android Oreo device using the following command:

$ vdc cryptfs changepw password original_password ""
200 5478 0


Even though the status indicated success (I've previously used this command to change the password without problems), the device does neither accept the original password nor does it boot without putting in a password. The password prompt still shows up.

I'm pretty sure this is only recoverable with a factory reset. (I'll still gladly take alternative hints on how to unlock this ;-))

My question is: How can I remove the boot password using adb without making the device unbootable?

vdc cryptfs clearpw seemed to me, like it would to the job. After reviewing the source, I found out, that it unfortunately only removes the password from  memory. I've also tried setting the password to default_password. This leads to the password still being required on bootup.
vdc cryptfs changepw default current_password default_password


does the trick. Replace current_password with the real current password. 

I believe the new password specified is irrelevant, as the DEFAULT_PASSWORD constant is used anyway. However, the current password seems to be required, atleast when using hardware-based encryption.
(see https://github.com/LineageOS/android_system_vold/blob/61a3249612495e7a5b2a1950859e9eb43dfc4559/cryptfs.cpp#L2858)