Do you really want/need to use Expect? Because that seems very complicated a solution, to me. There is certainly an option for cryptsetup that allows you to provide the passphrase on command-line or in a file.
I've just looked at the cryptsetup man page, and I see there is a --key-file option.
In reply to Re: Expect for cryptsetup
by grondilu
in thread Expect for cryptsetup
by theo@ubuntucy.org
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |