git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Disable OpenSSL SHA1 implementation by default

From
Jeff King <peff@peff.net>
Date
Feb 22, 2010, 11:23 UTC
Message-ID
<20100222112326.GA21929@coredump.intra.peff.net>
In-Reply-To
<20100222110814.GA3247@progeny.tock>
On Mon, Feb 22, 2010 at 05:08:14AM -0600, Jonathan Nieder wrote:
> The OpenSSL SHA-1 routine is about as fast as block-sha1, but linking
> to libcrypto slows down the startup of git commands by an appreciable
> amount.  Use the BLK_SHA1 implementation by default instead.

What is your definition of "about as fast"? I benchmarked up to a 20% slow-down a while back:

  http://article.gmane.org/gmane.comp.version-control.git/126995

Now my complaint then was specifically about removing openssl sha1 support entirely, and I have no problem with setting OPENSSL_SHA1 in my build options, but it does make sense to me that the default should be whatever is fastest for most people. And that means benchmarking blk_sha1 versus the libcrypto linking slow-down on several machines to get actual numbers.

Unfortunately, I think we may end up with an apples-to-oranges comparison, as sha1-heavy tasks are affected one way, and scripted many-git-invocation tasks the other way.

> Typed “make NO_OPENSSL=1” for the umpteenth time today, but this time
> I thought I should something about it.
echo 'NO_OPENSSL=1' >config.mak ?
Show 5 quoted lines
> -ifndef NO_OPENSSL
> +ifdef OPENSSL_TLS
> +	BASIC_CFLAGS += -DOPENSSL_TLS
> +	USE_OPENSSL = Yes
> +endif
Doesn't this flip the default for using TLS on imap-send?
-Peff
Previous: Jonathan NiederNext: Jonathan Nieder
Message 2 of 7 in “Disable OpenSSL SHA1 implementation by default”
  1. Disable OpenSSL SHA1 implementation by defaultJonathan Nieder, Feb 22, 2010
  2. Jeff KingFeb 22, 2010
  3. Jonathan NiederFeb 22, 2010
  4. Mark LodatoFeb 26, 2010
  5. Jeff KingFeb 26, 2010
  6. Mark LodatoFeb 26, 2010
  7. Jeff KingFeb 26, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.