[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#530784: partman-crypto: preseeding of the dm-crypt passphrase failed



(resent because of a typo in the bug number)

Quoting Gabriel Sailer (Gabriel.Sailer@gmx.net):
> Hallo,
> late but not to late i hope i have a patch to allow preseeding
> the crypto passphrase. I tried it successfull with only preseeding
> the passphrase with the following preseeding file:

Eh....that was indeed as simple as dropping (commenting) the lines
that reset the debconf value....

Is there any objection for me to commit this? I'm not very familiar
with all this code, but I don't see what it could harm.

This probably deserves a small addition to the installation manual
too, at least adding the following to the example preseed file...


CC'ing Frans to get advice about documenting the new "feature".

> 
> > ####################################################################
> > # Disk Partitioning/Boot loader
> > ####################################################################
> >
> > # dm-crypt passphrase
> > d-i     partman-crypto/passphrase       password        This_is_a
> > very_long_and_secret_passphrase!
> > d-i     partman-crypto/passphrase-again password        This_is_a
> > very_long_and_secret_passphrase!
> I appended the patch. Attention: there is no warning or something else
> because the installation should not be interrupted by an acknowledgment).


> --- blockdev-keygen	2009-07-09 20:44:06.000000000 +0200
> +++ blockdev-keygen.new	2009-07-09 20:44:47.000000000 +0200
> @@ -36,14 +36,16 @@
>  	pass_ok=0
>  	while [ $pass_ok -eq 0 ]; do
>  		templ="partman-crypto/passphrase"
> -		db_set $templ ""
> -		db_fset $templ seen false
> +# we want to use the crypto passphrase from preseed file
> +#		db_set $templ ""
> +#		db_fset $templ seen false
>  		db_subst $templ DEVICE "$description"
>  		db_input critical $templ
>  
>  		templ="partman-crypto/passphrase-again"
> -		db_set $templ ""
> -		db_fset $templ seen false
> +# we want to use the crypto passphrase from preseed file
> +#		db_set $templ ""
> +#		db_fset $templ seen false
>  		db_input critical $templ
>  
>  		db_go || return 1


-- 





----- End forwarded message -----




Reply to: