Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp2645067pxb; Tue, 12 Oct 2021 10:31:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzoH2Y/zNUYsy2uqOmL2KYngjBnoZbjmb7/6ps5wthKu4qhVG12kho4sPcQT/WoYDmxpOtY X-Received: by 2002:a17:90a:a586:: with SMTP id b6mr7464664pjq.244.1634059899784; Tue, 12 Oct 2021 10:31:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634059899; cv=none; d=google.com; s=arc-20160816; b=XXddP0EffnP01UmXitIlmUjxNs10BJhu8gkfj2WxWNqGpzQDAcjDyxkGNO0uF3QLGN ZjocIJoacZ7siUG+6K2wKvOkf3+A3/O7T8j0r4fa+Ta14Kdpb9wnv33jKCPBNZynZUq3 Wch2BjRS5MdaRClpTP24h0yU+djqRopjUgpmR064NN4p9h1iz5UtuO6RaGWa+pgc/4Cs qJAVPOgrr0qrgWhsKrELj0cfIZ6PuTH4rmZtSXIZEoEHpxMcg5sXAsogGX0rUnzD4NDM AfWQnBT4PizwrVVq+1rihqpL3KJlXaJJ02cjcGlVgtfDE1OmWPkUJZEGbd3I2phdpg4k sTIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=Or7jNzoZit/QjNqVhTBSwHmoM9bRZHGT1R5QKYIzIsc=; b=apXtjh9on/a2q2leR7w69XEyZK3OyUJM041tb/dDxvJUTqdIcol1fsXyWzw5UgmuPn 6wtio2WbsfOl8BkEDOdBQdpTAH7e8cFShLUKDY0Y0RU90hX9+h7F6RgingUgxLqmuRLO eXx23NEYmycXUKQf/3tQiyPgOwz/59HrUlL0qso99OIgguy0KhYIP+waBiBs5d4T0W2V L+Vas9dJ1lI/k9IPxc0polTjNlTF2Tl1OlixyQtmrxHWh/hfCTy6P/8iGoYzI2pGpqso 0n5LR4iDalEcJUncM0Emyvj64TtYiHNav2TxuiK8WpQBW2HN2iJvM2cCKJ8aCktXPi8a qOYw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x23si16211348pgf.148.2021.10.12.10.31.19; Tue, 12 Oct 2021 10:31:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232502AbhJLRcx (ORCPT + 99 others); Tue, 12 Oct 2021 13:32:53 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:36811 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S231756AbhJLRcw (ORCPT ); Tue, 12 Oct 2021 13:32:52 -0400 Received: from cwcc.thunk.org (pool-72-74-133-215.bstnma.fios.verizon.net [72.74.133.215]) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 19CHUkqM025388 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 12 Oct 2021 13:30:47 -0400 Received: by cwcc.thunk.org (Postfix, from userid 15806) id 213D215C00CA; Tue, 12 Oct 2021 13:30:46 -0400 (EDT) Date: Tue, 12 Oct 2021 13:30:46 -0400 From: "Theodore Ts'o" To: Avi Deitcher Cc: linux-ext4@vger.kernel.org Subject: Re: algorithm for half-md4 used in htree directories Message-ID: References: <3A493D20-568A-4D63-A575-5DEEBFAAF41A@dilger.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Mon, Oct 11, 2021 at 07:58:00PM -0700, Avi Deitcher wrote: > Aha. I missed that the seed is injected into buf before passing it > into half_md4_transform. I was looking at it as just the empty buffer > before the first iteration of the loop (or, in my case, since I was > testing with a 6 char filename, the only iteration). > > I will repeat my experiment with that and see if I can tease it out. BTW, if you are looking for a userspace implementation of the hash, it's available in libext2fs in e2fsprogs. Cheers, - Ted