Don't try to decrypt unsupported geli versions

Version 7 is in the wild (at least in FreeBSD 10) and it changed something
about encryption that isn't handled yet:
    http://svnweb.freebsd.org/base?view=revision&revision=238116
presumably earlier versions have other differences I haven't accounted for,
so don't try to read them either.
This commit is contained in:
Jeff Epler 2013-12-04 21:44:06 -06:00
parent 7b16581360
commit f0083a97b6

View file

@ -672,6 +672,8 @@ int main(int argc, char **argv) {
if(!blocksize)
fatal("Blocksize must not be zero");
if(md.md_version != 6)
fatalf("Unsupported version %d", md.md_version);
if(passphrase_file)
set_mkey_from_passfile(passphrase_file, &md);