Return-Path: Received: from maude.comedia.it (mail.comedia.it [77.93.254.181]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mail.saout.de (Postfix) with ESMTPS for ; Fri, 6 Nov 2009 09:13:05 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by maude.comedia.it (Postfix) with ESMTP id 7AD0A86F21 for ; Fri, 6 Nov 2009 09:13:04 +0100 (CET) Received: from maude.comedia.it ([127.0.0.1]) by localhost (maude.comedia.it [127.0.0.1]) (amavisd-new, port 10025) with LMTP id ZAiFrMuUm2Fx for ; Fri, 6 Nov 2009 09:13:04 +0100 (CET) Date: Fri, 6 Nov 2009 09:13:04 +0100 From: Luca Berra Message-ID: <20091106081304.GB11527@maude.comedia.it> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Disposition: inline Subject: Re: [dm-crypt] dm-crypt Digest, Vol 5, Issue 5 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: dm-crypt@saout.de On Fri, Nov 06, 2009 at 09:32:15AM +0700, Hans Hallan wrote: >Dear all, >I have succeed in encrypting hard disk with cryptsetup. >Now, I want to modify mkinitrd with automatically passphrase. >I found this line in /sbin/mkinitrd: > >echo Setting up disk encryption: /dev/sda4 >plymouth ask-for-password --command "cryptsetup luksOpen /dev/sda4 >luks-sda4" > >the second line ask me to type the passphrase, >is there anybody know how to make it automatically ? like: > >echo "passphrase" | cryptsetup luksOpen /dev/sda4 root ? >I have tried this command and make new initrd but it did not work. >It sound weird but, that is what I am asked to do. it does not sound weird, it sounds incredibly stupid, besides that try looking at the --key-file option of cryptsetup L.