unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#37420: [PATCH] Recommend against SHA-1 for security-related applications
@ 2019-09-16  8:53 Stefan Kangas
  2019-09-16 11:21 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 18+ messages in thread
From: Stefan Kangas @ 2019-09-16  8:53 UTC (permalink / raw)
  To: 37420

[-- Attachment #1: Type: text/plain, Size: 385 bytes --]

SHA-1 has now seen collision attacks:
https://www.zdnet.com/article/sha-1-collision-attacks-are-now-actually-practical-and-a-looming-danger/

We should clarify that these attacks are not only theoretical, and
actively discourage using it in security-related applications in the
Elisp Manual.  The attached patch is an attempt at doing that.

Any comments?

Best regards,
Stefan Kangas

[-- Attachment #2: 0001-Recommend-against-SHA-1-for-security-related-applica.patch --]
[-- Type: text/x-patch, Size: 1646 bytes --]

From 53a42470604e3db6e2f0552eb3481fa64a853458 Mon Sep 17 00:00:00 2001
From: Stefan Kangas <stefankangas@gmail.com>
Date: Mon, 16 Sep 2019 10:45:14 +0200
Subject: [PATCH] Recommend against SHA-1 for security-related applications

* doc/lispref/text.texi (Checksum/Hash): Clarify that SHA-1 is not
collision resistant.
---
 doc/lispref/text.texi | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/doc/lispref/text.texi b/doc/lispref/text.texi
index 7ce54f59c6..949797c3ef 100644
--- a/doc/lispref/text.texi
+++ b/doc/lispref/text.texi
@@ -4710,12 +4710,12 @@ Checksum/Hash
 SHA-1, SHA-2, SHA-224, SHA-256, SHA-384 and SHA-512.  MD5 is the
 oldest of these algorithms, and is commonly used in @dfn{message
 digests} to check the integrity of messages transmitted over a
-network.  MD5 is not collision resistant (i.e., it is possible to
-deliberately design different pieces of data which have the same MD5
-hash), so you should not used it for anything security-related.  A
-similar theoretical weakness also exists in SHA-1.  Therefore, for
-security-related applications you should use the other hash types,
-such as SHA-2.
+network.  MD5 and SHA-1 are not collision resistant (i.e., it is
+possible to deliberately design different pieces of data which have
+the same MD5 or SHA-1 hash), so you should not use them for anything
+security-related.  For security-related applications you should use
+the other hash types, such as SHA-2 (@code{sha224}, @code{sha256},
+@code{sha384} or @code{sha512}).
 
 @defun secure-hash-algorithms
 This function returns a list of symbols representing algorithms that
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2019-10-04 15:33 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-16  8:53 bug#37420: [PATCH] Recommend against SHA-1 for security-related applications Stefan Kangas
2019-09-16 11:21 ` Lars Ingebrigtsen
2019-09-16 20:29   ` Stefan Kangas
2019-09-16 20:34     ` Lars Ingebrigtsen
2019-09-16 21:50       ` Stefan Kangas
2019-09-16 22:25         ` Lars Ingebrigtsen
2019-09-17  9:17           ` Stefan Kangas
2019-09-17  6:05         ` Eli Zaretskii
2019-09-17 13:37           ` Robert Pluim
2019-09-28 10:19             ` Stefan Kangas
2019-09-28 19:55               ` Lars Ingebrigtsen
2019-10-04 15:33                 ` Stefan Kangas
2019-09-17  5:50       ` Eli Zaretskii
2019-09-17  9:09         ` Stefan Kangas
2019-09-17 11:53           ` Eli Zaretskii
2019-09-17 12:08             ` Stefan Kangas
2019-09-17 12:14               ` Stefan Kangas
2019-09-20 18:50       ` Stefan Kangas

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).