From owner-freebsd-geom@freebsd.org Sun Aug 18 13:46:16 2019 Return-Path: Delivered-To: freebsd-geom@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 77225C8084 for ; Sun, 18 Aug 2019 13:46:16 +0000 (UTC) (envelope-from coco@executive-computing.de) Received: from mail.moehre.org (mail.moehre.org [195.96.35.7]) by mx1.freebsd.org (Postfix) with ESMTP id 46BJHW0yWLz4YMx for ; Sun, 18 Aug 2019 13:46:14 +0000 (UTC) (envelope-from coco@executive-computing.de) Received: from mail.moehre.org (unknown [195.96.35.7]) by mail.moehre.org (Postfix) with ESMTP id D1BDD3EF11 for ; Sun, 18 Aug 2019 15:46:06 +0200 (CEST) X-Spam-Flag: NO X-Spam-Score: -100.918 X-Spam-Level: X-Spam-Status: No, score=-100.918 tagged_above=-999 required=5 tests=[ALL_TRUSTED=-1, AWL=0.005, TW_ZF=0.077, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mail.moehre.org ([195.96.35.7]) by mail.moehre.org (mail.moehre.org [195.96.35.7]) (amavisd-new, port 10024) with ESMTP id XtrZku2XJTXq for ; Sun, 18 Aug 2019 15:46:06 +0200 (CEST) Received: from localhost (p5B2F1337.dip0.t-ipconnect.de [91.47.19.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: coco@executive-computing.de) by mail.moehre.org (Postfix) with ESMTPSA id 670973EF0B for ; Sun, 18 Aug 2019 15:46:06 +0200 (CEST) Date: Sun, 18 Aug 2019 15:46:02 +0200 From: Marco Steinbach To: freebsd-geom@freebsd.org Subject: 11.3: GELI attach: Wrong key despite correct passphrase Message-ID: <20190818154602.00003fa8@executive-computing.de> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-w64-mingw32) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 46BJHW0yWLz4YMx X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of coco@executive-computing.de designates 195.96.35.7 as permitted sender) smtp.mailfrom=coco@executive-computing.de X-Spamd-Result: default: False [-2.92 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.996,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-geom@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-0.996,0]; RCVD_COUNT_THREE(0.00)[3]; DMARC_NA(0.00)[executive-computing.de]; NEURAL_HAM_SHORT(-0.72)[-0.723,0]; IP_SCORE(-0.00)[country: DE(-0.01)]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8354, ipnet:195.96.32.0/19, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[55.19.47.91.khpj7ygk5idzvmvt5x4ziurxhy.zen.dq.spamhaus.net : 127.0.0.10] X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Aug 2019 13:46:16 -0000 Hi. I have two bootable SSDs, both installed using a GELI encrypted root on ZFS. Both use the same passphrase, both boot, if I enter that passphrase at GELIs prompt. One contains a GELI encrypted ZFS on root installed using the 11.1-RELEASE installer, which was source upgraded to 12 (without upgrading the zpools). The other also contains a GELI encrypted ZFS on root, but installed using the 11.3-RELEASE installer. This one was source upgraded to 11.3-STABLE r350677. I'd like to copy over data from the 12 to the 11.3 drive, so I put the 12 one into an external USB enclosure. root@bsdbuch:~ # uname -a FreeBSD bsdbuch.c0c0.intra 11.3-STABLE FreeBSD 11.3-STABLE #0 r350677: Sun Aug 18 04:43:08 CEST 2019 root@bsdbuch.c0c0.intra:/usr/obj/usr/src/sys/GENERIC amd64 Internal 11.3 root@bsdbuch:~ # gpart show ada0 => 40 1953525088 ada0 GPT (932G) 40 1024 1 freebsd-boot (512K) 1064 984 - free - (492K) 2048 16777216 2 freebsd-swap (8.0G) 16779264 1936744448 3 freebsd-zfs (924G) 1953523712 1416 - free - (708K) External 12 USB root@bsdbuch:~ # gpart show da0 => 40 1953525088 da0 GPT (932G) 40 409600 1 efi (200M) 409640 1024 2 freebsd-boot (512K) 410664 984 - free - (492K) 411648 4194304 3 freebsd-zfs (2.0G) 4605952 33554432 4 freebsd-swap (16G) 38160384 1915363328 5 freebsd-zfs (913G) 1953523712 1416 - free - (708K) root@bsdbuch:~ # geli attach /dev/da0p5 Enter passphrase: geli: Wrong key for da0p5. I've then imported the bootpool from da0, and mounted it, so I can try using the key in boot/ root@bsdbuch:~ # geli attach -k /bootpool/boot/ada0p5.eli /dev/da0p5 Enter passphrase: geli: Wrong key for da0p5. If I put the 11.3 drive into the external enclosure, and boot from the 12 drive, I can attach the 11.3 GELI provider without error using the exact same passphrase (and without using a key) Am I missing something ? MfG CoCo