From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=3.0 tests=AWL,BAYES_00,BODY_8BITS, MAILING_LIST_MULTI,NICE_REPLY_A,RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 1D72B1F4B4 for ; Mon, 21 Sep 2020 22:49:38 +0000 (UTC) Received: from localhost ([::1]:53448 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kKUcq-0006UW-Ri for normalperson@yhbt.net; Mon, 21 Sep 2020 18:49:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38524) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kKUcn-0006Sr-Ja for bug-gnulib@gnu.org; Mon, 21 Sep 2020 18:49:33 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:38626) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kKUcn-00062g-4R; Mon, 21 Sep 2020 18:49:33 -0400 Received: from c-71-198-222-86.hsd1.ca.comcast.net ([71.198.222.86]:59014 helo=[172.16.16.102]) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1kKUcm-0005ev-J2; Mon, 21 Sep 2020 18:49:32 -0400 Subject: Re: gc-pbkdf2-sha1 is deprecated To: Bruno Haible , bug-gnulib@gnu.org References: <4725cba4-3dc2-314a-0e1d-fb48c1a51540@gnu.org> <61d0906e-aa38-8c92-8d9f-ece85a8dccbf@gnu.org> <1671692.6njsL75u0N@omega> From: Bruce Korb Message-ID: <15f388d6-fd18-178d-e58c-6199e950086c@gnu.org> Date: Mon, 21 Sep 2020 15:49:30 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 MIME-Version: 1.0 In-Reply-To: <1671692.6njsL75u0N@omega> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-BeenThere: bug-gnulib@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Gnulib discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnulib-bounces+normalperson=yhbt.net@gnu.org Sender: "bug-gnulib" gnu-pw-mgr fatal error: gc_pbkdf2_hmac returned error code 5 (5 --> GC_INVALID_HASH) I think they work differently.     rc = gc_pbkdf2_hmac(GC_SHA1,                         hash_source, hash_src_len,                         salt,        salt_len,                         OPT_VALUE_PBKDF2,// <-- pbkdf2 reprocessing count                         hash_output, hash_out_len);     if (rc != GC_OK)         die(GNU_PW_MGR_EXIT_INVALID, pbkdf2_err_fmt, rc); On 9/18/20 9:32 AM, Bruno Haible wrote: > Hi Bruce, > >> Next question: what do I do about crypto/gc-pbkdf2-sha1? It is labeled >> as "deprecated", but I need a function that produces precisely the same >> result. It really doesn't matter to me that folks have figured out how >> to jigger a file to produce an arbitrary sha1 sum. I only need a fairly >> random result from summing a few tens of bytes of text. So as long as >> "deprecate" doesn't mean it's going away, I'm fine. > It may go away, because the module crypto/gc-pbkdf2 contains more generic > API to do the same thing: gc_pbkdf2_hmac with first argument GC_SHA1. > > Bruno > >