OLD | NEW |
1 From 2688f00904e4ffd647afcff69bb8fe6df8c5902b Mon Sep 17 00:00:00 2001 | 1 From 2688f00904e4ffd647afcff69bb8fe6df8c5902b Mon Sep 17 00:00:00 2001 |
2 From: Adam Langley <agl@chromium.org> | 2 From: Adam Langley <agl@chromium.org> |
3 Date: Mon, 9 Sep 2013 12:13:24 -0400 | 3 Date: Mon, 9 Sep 2013 12:13:24 -0400 |
4 Subject: [PATCH 43/52] chacha20poly1305 | 4 Subject: [PATCH 43/52] chacha20poly1305 |
5 | 5 |
6 Add support for Chacha20 + Poly1305. | 6 Add support for Chacha20 + Poly1305. |
7 --- | 7 --- |
8 .gitignore | 1 + | 8 .gitignore | 1 + |
9 Configure | 56 +- | 9 Configure | 56 +- |
10 Makefile.org | 6 +- | 10 Makefile.org | 6 +- |
(...skipping 30 matching lines...) Expand all Loading... |
41 create mode 100644 crypto/chacha/chachatest.c | 41 create mode 100644 crypto/chacha/chachatest.c |
42 create mode 100644 crypto/evp/e_chacha20poly1305.c | 42 create mode 100644 crypto/evp/e_chacha20poly1305.c |
43 create mode 100644 crypto/poly1305/Makefile | 43 create mode 100644 crypto/poly1305/Makefile |
44 create mode 100644 crypto/poly1305/poly1305.c | 44 create mode 100644 crypto/poly1305/poly1305.c |
45 create mode 100644 crypto/poly1305/poly1305.h | 45 create mode 100644 crypto/poly1305/poly1305.h |
46 create mode 100644 crypto/poly1305/poly1305_arm.c | 46 create mode 100644 crypto/poly1305/poly1305_arm.c |
47 create mode 100644 crypto/poly1305/poly1305_arm_asm.s | 47 create mode 100644 crypto/poly1305/poly1305_arm_asm.s |
48 create mode 100644 crypto/poly1305/poly1305_vec.c | 48 create mode 100644 crypto/poly1305/poly1305_vec.c |
49 create mode 100644 crypto/poly1305/poly1305test.c | 49 create mode 100644 crypto/poly1305/poly1305test.c |
50 | 50 |
| 51 diff --git a/openssl/ssl/ssl_ciph.c b/openssl/ssl/ssl_ciph.c |
| 52 index db85b29..cebb18a 100644 |
| 53 --- a/ssl/ssl_ciph.c |
| 54 +++ b/ssl/ssl_ciph.c |
| 55 @@ -1442,7 +1442,9 @@ STACK_OF(SSL_CIPHER) *ssl_create_cipher_list(const SSL_MET
HOD *ssl_method, |
| 56 ssl_cipher_apply_rule(0, SSL_kEECDH, 0, 0, 0, 0, 0, CIPHER_ADD, -1, &hea
d, &tail); |
| 57 ssl_cipher_apply_rule(0, SSL_kEECDH, 0, 0, 0, 0, 0, CIPHER_DEL, -1, &hea
d, &tail); |
| 58 |
| 59 - /* AES is our preferred symmetric cipher */ |
| 60 + /* CHACHA20 is fast and safe on all hardware and is thus our preferred |
| 61 + * symmetric cipher, with AES second. */ |
| 62 + ssl_cipher_apply_rule(0, 0, 0, SSL_CHACHA20POLY1305, 0, 0, 0, CIPHER_ADD
, -1, &head, &tail); |
| 63 ssl_cipher_apply_rule(0, 0, 0, SSL_AES, 0, 0, 0, CIPHER_ADD, -1, &head,
&tail); |
| 64 |
| 65 /* Temporarily enable everything else for sorting */ |
51 diff --git a/Configure b/Configure | 66 diff --git a/Configure b/Configure |
52 index 9c803dc..1b95384 100755 | 67 index 9c803dc..1b95384 100755 |
53 --- a/Configure | 68 --- a/Configure |
54 +++ b/Configure | 69 +++ b/Configure |
55 @@ -124,24 +124,24 @@ my $tlib="-lnsl -lsocket"; | 70 @@ -124,24 +124,24 @@ my $tlib="-lnsl -lsocket"; |
56 my $bits1="THIRTY_TWO_BIT "; | 71 my $bits1="THIRTY_TWO_BIT "; |
57 my $bits2="SIXTY_FOUR_BIT "; | 72 my $bits2="SIXTY_FOUR_BIT "; |
58 | 73 |
59 -my $x86_asm="x86cpuid.o:bn-586.o co-586.o x86-mont.o x86-gf2m.o:des-586.o crypt
586.o:aes-586.o vpaes-x86.o aesni-x86.o:bf-586.o:md5-586.o:sha1-586.o sha256-586
.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o:cml
l-x86.o:ghash-x86.o:"; | 74 -my $x86_asm="x86cpuid.o:bn-586.o co-586.o x86-mont.o x86-gf2m.o:des-586.o crypt
586.o:aes-586.o vpaes-x86.o aesni-x86.o:bf-586.o:md5-586.o:sha1-586.o sha256-586
.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o:cml
l-x86.o:ghash-x86.o:"; |
60 +my $x86_asm="x86cpuid.o:bn-586.o co-586.o x86-mont.o x86-gf2m.o:des-586.o crypt
586.o:aes-586.o vpaes-x86.o aesni-x86.o:bf-586.o:md5-586.o:sha1-586.o sha256-586
.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o:cml
l-x86.o:ghash-x86.o:::"; | 75 +my $x86_asm="x86cpuid.o:bn-586.o co-586.o x86-mont.o x86-gf2m.o:des-586.o crypt
586.o:aes-586.o vpaes-x86.o aesni-x86.o:bf-586.o:md5-586.o:sha1-586.o sha256-586
.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o:cml
l-x86.o:ghash-x86.o:::"; |
(...skipping 5655 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5716 + | 5731 + |
5717 +$(POLY1305TEST)$(EXE_EXT): $(POLY1305TEST).o $(DLIBCRYPTO) | 5732 +$(POLY1305TEST)$(EXE_EXT): $(POLY1305TEST).o $(DLIBCRYPTO) |
5718 + @target=$(CHACHATEST); $(BUILD_CMD) | 5733 + @target=$(CHACHATEST); $(BUILD_CMD) |
5719 + | 5734 + |
5720 $(RMDTEST)$(EXE_EXT): $(RMDTEST).o $(DLIBCRYPTO) | 5735 $(RMDTEST)$(EXE_EXT): $(RMDTEST).o $(DLIBCRYPTO) |
5721 @target=$(RMDTEST); $(BUILD_CMD) | 5736 @target=$(RMDTEST); $(BUILD_CMD) |
5722 | 5737 |
5723 -- | 5738 -- |
5724 1.8.4.1 | 5739 1.8.4.1 |
5725 | 5740 |
OLD | NEW |