Update devel/git to 2.13.2

Sponsored by:	Rubicon Communications (Netgate)
This commit is contained in:
Renato Botelho 2017-06-27 13:39:53 +00:00
parent 1c4dc0c005
commit a014051a7b
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=444462
5 changed files with 9 additions and 209 deletions

View file

@ -2,8 +2,7 @@
# $FreeBSD$
PORTNAME= git
DISTVERSION= 2.13.1
PORTREVISION= 2
DISTVERSION= 2.13.2
CATEGORIES= devel
MASTER_SITES= KERNEL_ORG/software/scm/git
DISTFILES= ${DISTNAME}${EXTRACT_SUFX} \

View file

@ -1,7 +1,7 @@
TIMESTAMP = 1497014086
SHA256 (git-2.13.1.tar.xz) = 3bc1becd983f77ab154a46801624369dbc40c3dd04b4c4b07ad026f5684688fe
SIZE (git-2.13.1.tar.xz) = 4746640
SHA256 (git-manpages-2.13.1.tar.xz) = e3dd097d06c44f6d8191ae468b6fc401eaf6992f4962041e9c3af4a06335ff70
SIZE (git-manpages-2.13.1.tar.xz) = 407700
SHA256 (git-htmldocs-2.13.1.tar.xz) = eb2a463434a00cc7381788faa29499cd32c19a5437d97d7dcf65b25603b2b411
SIZE (git-htmldocs-2.13.1.tar.xz) = 1108536
TIMESTAMP = 1498482405
SHA256 (git-2.13.2.tar.xz) = 0d10ac3751466f81652b62cbda83cc8d8ffd014911462138e039f176e413dde5
SIZE (git-2.13.2.tar.xz) = 4751380
SHA256 (git-manpages-2.13.2.tar.xz) = 30e1e1313000eb81f0e348e5083758a33703941a60ab111057b46c3dad968b6e
SIZE (git-manpages-2.13.2.tar.xz) = 407684
SHA256 (git-htmldocs-2.13.2.tar.xz) = 54f0d36d375e7f71441994e60c18b6e2cc43581d5827e806e0bddb6904e17dfc
SIZE (git-htmldocs-2.13.2.tar.xz) = 1109048

View file

@ -1,115 +0,0 @@
From 5d184f468e59cd9c5b51b5c139540015c8e41b18 Mon Sep 17 00:00:00 2001
From: Jeff King <peff@peff.net>
Date: Tue, 6 Jun 2017 15:01:11 -0400
Subject: [PATCH 1/2] sha1dc: ignore indent-with-non-tab whitespace violations
The upstream sha1dc code indents some lines with spaces.
While this doesn't match Git's coding guidelines, it's better
to leave this imported code untouched than to try to make it
match our style. However, we can use .gitattributes to tell
"diff --check" and "git am" not to bother us about it.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
sha1dc/.gitattributes | 1 +
1 file changed, 1 insertion(+)
create mode 100644 sha1dc/.gitattributes
From 6b851e536b05e0c8c61f77b9e4c3e7cedea39ff8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?=
<avarab@gmail.com>
Date: Tue, 6 Jun 2017 15:12:29 +0000
Subject: [PATCH 2/2] sha1dc: update from upstream
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Update sha1dc from the latest version by the upstream
maintainer[1].
See commit a0103914c2 ("sha1dc: update from upstream", 2017-05-20) for
the latest update. That update was done sans some whitespace changes
by upstream, which is why the diff here isn't the same as the upstream
cc46554..e139984.
It also brings in a change[2] upstream made which should hopefully
address the breakage in 2.13.1 on Cygwin, see [3]. Cygwin defines both
_BIG_ENDIAN and _LITTLE_ENDIAN.
Adam Dinwoodie reports on the mailing list that that upstream commit
fixes the issue on Cygwin[4].
1. https://github.com/cr-marcstevens/sha1collisiondetection/commit/e1399840b501a68ac6c8d7ed9a5cb1455480200e
2. https://github.com/cr-marcstevens/sha1collisiondetection/commit/a24eef58c0684078405f8c7a89f9b78271432005
3. <20170606100355.GC25777@dinwoodie.org> (https://public-inbox.org/git/20170606100355.GC25777@dinwoodie.org/)
4. <20170606124323.GD25777@dinwoodie.org> (https://public-inbox.org/git/20170606124323.GD25777@dinwoodie.org/)
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
sha1dc/sha1.c | 30 ++++++++++++++++++++++++------
sha1dc/sha1.h | 6 +++---
2 files changed, 27 insertions(+), 9 deletions(-)
diff --git a/sha1dc/sha1.c b/sha1dc/sha1.c
index 3dff80ac727aa..facea1bb560b5 100644
--- sha1dc/sha1.c
+++ sha1dc/sha1.c
@@ -35,15 +35,33 @@
#ifdef SHA1DC_BIGENDIAN
#undef SHA1DC_BIGENDIAN
#endif
-#if (!defined SHA1DC_FORCE_LITTLEENDIAN) && \
- ((defined(__BYTE_ORDER) && (__BYTE_ORDER == __BIG_ENDIAN)) || \
- (defined(__BYTE_ORDER__) && (__BYTE_ORDER__ == __BIG_ENDIAN__)) || \
- defined(_BIG_ENDIAN) || defined(__BIG_ENDIAN__) || defined(__ARMEB__) || defined(__THUMBEB__) || defined(__AARCH64EB__) || \
- defined(_MIPSEB) || defined(__MIPSEB) || defined(__MIPSEB__) || defined(SHA1DC_FORCE_BIGENDIAN))
+#if (defined(_BYTE_ORDER) || defined(__BYTE_ORDER) || defined(__BYTE_ORDER__))
+
+#if ((defined(_BYTE_ORDER) && (_BYTE_ORDER == _BIG_ENDIAN)) || \
+ (defined(__BYTE_ORDER) && (__BYTE_ORDER == __BIG_ENDIAN)) || \
+ (defined(__BYTE_ORDER__) && (__BYTE_ORDER__ == __BIG_ENDIAN__)) )
#define SHA1DC_BIGENDIAN
+#endif
+
+#else
+
+#if (defined(_BIG_ENDIAN) || defined(__BIG_ENDIAN) || defined(__BIG_ENDIAN__) || \
+ defined(__ARMEB__) || defined(__THUMBEB__) || defined(__AARCH64EB__) || \
+ defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || \
+ defined(__sparc))
+#define SHA1DC_BIGENDIAN
+#endif
-#endif /*ENDIANNESS SELECTION*/
+#endif
+
+#if (defined(SHA1DC_FORCE_LITTLEENDIAN) && defined(SHA1DC_BIGENDIAN))
+#undef SHA1DC_BIGENDIAN
+#endif
+#if (defined(SHA1DC_FORCE_BIGENDIAN) && !defined(SHA1DC_BIGENDIAN))
+#define SHA1DC_BIGENDIAN
+#endif
+/*ENDIANNESS SELECTION*/
#if (defined SHA1DC_FORCE_UNALIGNED_ACCESS || \
defined(__amd64__) || defined(__amd64) || defined(__x86_64__) || defined(__x86_64) || \
diff --git a/sha1dc/sha1.h b/sha1dc/sha1.h
index a0ff5d1305797..1e4e94be54a6d 100644
--- sha1dc/sha1.h
+++ sha1dc/sha1.h
@@ -61,9 +61,9 @@ void SHA1DCInit(SHA1_CTX*);
Function to enable safe SHA-1 hashing:
Collision attacks are thwarted by hashing a detected near-collision block 3 times.
Think of it as extending SHA-1 from 80-steps to 240-steps for such blocks:
- The best collision attacks against SHA-1 have complexity about 2^60,
- thus for 240-steps an immediate lower-bound for the best cryptanalytic attacks would be 2^180.
- An attacker would be better off using a generic birthday search of complexity 2^80.
+ The best collision attacks against SHA-1 have complexity about 2^60,
+ thus for 240-steps an immediate lower-bound for the best cryptanalytic attacks would be 2^180.
+ An attacker would be better off using a generic birthday search of complexity 2^80.
Enabling safe SHA-1 hashing will result in the correct SHA-1 hash for messages where no collision attack was detected,
but it will result in a different SHA-1 hash for messages where a collision attack was detected.

View file

@ -1,85 +0,0 @@
diff --git a/git-send-email.perl b/git-send-email.perl
index eea0a517f71b6..0d90439d9a8e5 100755
--- git-send-email.perl
+++ git-send-email.perl
@@ -1353,10 +1353,12 @@ sub send_message {
die __("The required SMTP server is not properly defined.")
}
+ require Net::SMTP;
+ my $use_net_smtp_ssl = version->parse($Net::SMTP::VERSION) < version->parse("2.34");
+ $smtp_domain ||= maildomain();
+
if ($smtp_encryption eq 'ssl') {
$smtp_server_port ||= 465; # ssmtp
- require Net::SMTP::SSL;
- $smtp_domain ||= maildomain();
require IO::Socket::SSL;
# Suppress "variable accessed once" warning.
@@ -1368,34 +1370,48 @@ sub send_message {
# Net::SMTP::SSL->new() does not forward any SSL options
IO::Socket::SSL::set_client_defaults(
ssl_verify_params());
- $smtp ||= Net::SMTP::SSL->new($smtp_server,
- Hello => $smtp_domain,
- Port => $smtp_server_port,
- Debug => $debug_net_smtp);
+
+ if ($use_net_smtp_ssl) {
+ require Net::SMTP::SSL;
+ $smtp ||= Net::SMTP::SSL->new($smtp_server,
+ Hello => $smtp_domain,
+ Port => $smtp_server_port,
+ Debug => $debug_net_smtp);
+ }
+ else {
+ $smtp ||= Net::SMTP->new($smtp_server,
+ Hello => $smtp_domain,
+ Port => $smtp_server_port,
+ Debug => $debug_net_smtp,
+ SSL => 1);
+ }
}
else {
- require Net::SMTP;
- $smtp_domain ||= maildomain();
$smtp_server_port ||= 25;
$smtp ||= Net::SMTP->new($smtp_server,
Hello => $smtp_domain,
Debug => $debug_net_smtp,
Port => $smtp_server_port);
if ($smtp_encryption eq 'tls' && $smtp) {
- require Net::SMTP::SSL;
- $smtp->command('STARTTLS');
- $smtp->response();
- if ($smtp->code == 220) {
+ if ($use_net_smtp_ssl) {
+ $smtp->command('STARTTLS');
+ $smtp->response();
+ if ($smtp->code != 220) {
+ die sprintf(__("Server does not support STARTTLS! %s"), $smtp->message);
+ }
+ require Net::SMTP::SSL;
$smtp = Net::SMTP::SSL->start_SSL($smtp,
ssl_verify_params())
- or die "STARTTLS failed! ".IO::Socket::SSL::errstr();
- $smtp_encryption = '';
- # Send EHLO again to receive fresh
- # supported commands
- $smtp->hello($smtp_domain);
- } else {
- die sprintf(__("Server does not support STARTTLS! %s"), $smtp->message);
+ or die sprintf(__("STARTTLS failed! %s"), IO::Socket::SSL::errstr());
+ }
+ else {
+ $smtp->starttls(ssl_verify_params())
+ or die sprintf(__("STARTTLS failed! %s"), IO::Socket::SSL::errstr());
}
+ $smtp_encryption = '';
+ # Send EHLO again to receive fresh
+ # supported commands
+ $smtp->hello($smtp_domain);
}
}

View file

@ -635,6 +635,7 @@ man/man7/gitworkflows.7.gz
%%HTMLDOCS%%%%DOCSDIR%%/RelNotes/2.12.3.txt
%%HTMLDOCS%%%%DOCSDIR%%/RelNotes/2.13.0.txt
%%HTMLDOCS%%%%DOCSDIR%%/RelNotes/2.13.1.txt
%%HTMLDOCS%%%%DOCSDIR%%/RelNotes/2.13.2.txt
%%HTMLDOCS%%%%DOCSDIR%%/RelNotes/2.2.0.txt
%%HTMLDOCS%%%%DOCSDIR%%/RelNotes/2.2.1.txt
%%HTMLDOCS%%%%DOCSDIR%%/RelNotes/2.2.2.txt