• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Aucun tag

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

FFFTPのソースコードです。


Commit MetaInfo

Révision4e1b717fd5a0a0a5462642aa3443fbab5265b28d (tree)
l'heure2016-03-05 20:17:14
Auteurs_kawamoto <s_kawamoto@user...>
Commiters_kawamoto

Message de Log

Update OpenSSL to 1.0.2g.

Change Summary

Modification

Binary files a/FFFTP_Eng_Release/FFFTP.exe and b/FFFTP_Eng_Release/FFFTP.exe differ
Binary files a/FFFTP_Eng_Release_64/FFFTP.exe and b/FFFTP_Eng_Release_64/FFFTP.exe differ
Binary files a/Release/FFFTP.exe and b/Release/FFFTP.exe differ
Binary files a/Release_64/FFFTP.exe and b/Release_64/FFFTP.exe differ
--- a/common.h
+++ b/common.h
@@ -81,7 +81,7 @@
8181 // ソフトウェア自動更新
8282 // リリースバージョンはリリース予定年(10進数4桁)+月(2桁)+日(2桁)+通し番号(0スタート2桁)とする
8383 // 2014年7月31日中の30個目のリリースは2014073129
84-#define RELEASE_VERSION_NUM 2016022000 /* リリースバージョン */
84+#define RELEASE_VERSION_NUM 2016030500 /* リリースバージョン */
8585
8686
8787 // SourceForge.JPによるフォーク
--- a/contrib/openssl/CHANGES
+++ b/contrib/openssl/CHANGES
@@ -2,6 +2,138 @@
22 OpenSSL CHANGES
33 _______________
44
5+ Changes between 1.0.2f and 1.0.2g [1 Mar 2016]
6+
7+ * Disable weak ciphers in SSLv3 and up in default builds of OpenSSL.
8+ Builds that are not configured with "enable-weak-ssl-ciphers" will not
9+ provide any "EXPORT" or "LOW" strength ciphers.
10+ [Viktor Dukhovni]
11+
12+ * Disable SSLv2 default build, default negotiation and weak ciphers. SSLv2
13+ is by default disabled at build-time. Builds that are not configured with
14+ "enable-ssl2" will not support SSLv2. Even if "enable-ssl2" is used,
15+ users who want to negotiate SSLv2 via the version-flexible SSLv23_method()
16+ will need to explicitly call either of:
17+
18+ SSL_CTX_clear_options(ctx, SSL_OP_NO_SSLv2);
19+ or
20+ SSL_clear_options(ssl, SSL_OP_NO_SSLv2);
21+
22+ as appropriate. Even if either of those is used, or the application
23+ explicitly uses the version-specific SSLv2_method() or its client and
24+ server variants, SSLv2 ciphers vulnerable to exhaustive search key
25+ recovery have been removed. Specifically, the SSLv2 40-bit EXPORT
26+ ciphers, and SSLv2 56-bit DES are no longer available.
27+ (CVE-2016-0800)
28+ [Viktor Dukhovni]
29+
30+ *) Fix a double-free in DSA code
31+
32+ A double free bug was discovered when OpenSSL parses malformed DSA private
33+ keys and could lead to a DoS attack or memory corruption for applications
34+ that receive DSA private keys from untrusted sources. This scenario is
35+ considered rare.
36+
37+ This issue was reported to OpenSSL by Adam Langley(Google/BoringSSL) using
38+ libFuzzer.
39+ (CVE-2016-0705)
40+ [Stephen Henson]
41+
42+ *) Disable SRP fake user seed to address a server memory leak.
43+
44+ Add a new method SRP_VBASE_get1_by_user that handles the seed properly.
45+
46+ SRP_VBASE_get_by_user had inconsistent memory management behaviour.
47+ In order to fix an unavoidable memory leak, SRP_VBASE_get_by_user
48+ was changed to ignore the "fake user" SRP seed, even if the seed
49+ is configured.
50+
51+ Users should use SRP_VBASE_get1_by_user instead. Note that in
52+ SRP_VBASE_get1_by_user, caller must free the returned value. Note
53+ also that even though configuring the SRP seed attempts to hide
54+ invalid usernames by continuing the handshake with fake
55+ credentials, this behaviour is not constant time and no strong
56+ guarantees are made that the handshake is indistinguishable from
57+ that of a valid user.
58+ (CVE-2016-0798)
59+ [Emilia Käsper]
60+
61+ *) Fix BN_hex2bn/BN_dec2bn NULL pointer deref/heap corruption
62+
63+ In the BN_hex2bn function the number of hex digits is calculated using an
64+ int value |i|. Later |bn_expand| is called with a value of |i * 4|. For
65+ large values of |i| this can result in |bn_expand| not allocating any
66+ memory because |i * 4| is negative. This can leave the internal BIGNUM data
67+ field as NULL leading to a subsequent NULL ptr deref. For very large values
68+ of |i|, the calculation |i * 4| could be a positive value smaller than |i|.
69+ In this case memory is allocated to the internal BIGNUM data field, but it
70+ is insufficiently sized leading to heap corruption. A similar issue exists
71+ in BN_dec2bn. This could have security consequences if BN_hex2bn/BN_dec2bn
72+ is ever called by user applications with very large untrusted hex/dec data.
73+ This is anticipated to be a rare occurrence.
74+
75+ All OpenSSL internal usage of these functions use data that is not expected
76+ to be untrusted, e.g. config file data or application command line
77+ arguments. If user developed applications generate config file data based
78+ on untrusted data then it is possible that this could also lead to security
79+ consequences. This is also anticipated to be rare.
80+
81+ This issue was reported to OpenSSL by Guido Vranken.
82+ (CVE-2016-0797)
83+ [Matt Caswell]
84+
85+ *) Fix memory issues in BIO_*printf functions
86+
87+ The internal |fmtstr| function used in processing a "%s" format string in
88+ the BIO_*printf functions could overflow while calculating the length of a
89+ string and cause an OOB read when printing very long strings.
90+
91+ Additionally the internal |doapr_outch| function can attempt to write to an
92+ OOB memory location (at an offset from the NULL pointer) in the event of a
93+ memory allocation failure. In 1.0.2 and below this could be caused where
94+ the size of a buffer to be allocated is greater than INT_MAX. E.g. this
95+ could be in processing a very long "%s" format string. Memory leaks can
96+ also occur.
97+
98+ The first issue may mask the second issue dependent on compiler behaviour.
99+ These problems could enable attacks where large amounts of untrusted data
100+ is passed to the BIO_*printf functions. If applications use these functions
101+ in this way then they could be vulnerable. OpenSSL itself uses these
102+ functions when printing out human-readable dumps of ASN.1 data. Therefore
103+ applications that print this data could be vulnerable if the data is from
104+ untrusted sources. OpenSSL command line applications could also be
105+ vulnerable where they print out ASN.1 data, or if untrusted data is passed
106+ as command line arguments.
107+
108+ Libssl is not considered directly vulnerable. Additionally certificates etc
109+ received via remote connections via libssl are also unlikely to be able to
110+ trigger these issues because of message size limits enforced within libssl.
111+
112+ This issue was reported to OpenSSL Guido Vranken.
113+ (CVE-2016-0799)
114+ [Matt Caswell]
115+
116+ *) Side channel attack on modular exponentiation
117+
118+ A side-channel attack was found which makes use of cache-bank conflicts on
119+ the Intel Sandy-Bridge microarchitecture which could lead to the recovery
120+ of RSA keys. The ability to exploit this issue is limited as it relies on
121+ an attacker who has control of code in a thread running on the same
122+ hyper-threaded core as the victim thread which is performing decryptions.
123+
124+ This issue was reported to OpenSSL by Yuval Yarom, The University of
125+ Adelaide and NICTA, Daniel Genkin, Technion and Tel Aviv University, and
126+ Nadia Heninger, University of Pennsylvania with more information at
127+ http://cachebleed.info.
128+ (CVE-2016-0702)
129+ [Andy Polyakov]
130+
131+ *) Change the req app to generate a 2048-bit RSA/DSA key by default,
132+ if no keysize is specified with default_bits. This fixes an
133+ omission in an earlier change that changed all RSA/DSA key generation
134+ apps to use 2048 bits by default.
135+ [Emilia Käsper]
136+
5137 Changes between 1.0.2e and 1.0.2f [28 Jan 2016]
6138
7139 *) DH small subgroups
@@ -105,7 +237,7 @@
105237 [Emilia Käsper]
106238
107239 *) In DSA_generate_parameters_ex, if the provided seed is too short,
108- return an error
240+ use a random seed, as already documented.
109241 [Rich Salz and Ismo Puustinen <ismo.puustinen@intel.com>]
110242
111243 Changes between 1.0.2c and 1.0.2d [9 Jul 2015]
--- a/contrib/openssl/NEWS
+++ b/contrib/openssl/NEWS
@@ -5,6 +5,19 @@
55 This file gives a brief overview of the major changes between each OpenSSL
66 release. For more details please read the CHANGES file.
77
8+ Major changes between OpenSSL 1.0.2f and OpenSSL 1.0.2g [1 Mar 2016]
9+
10+ o Disable weak ciphers in SSLv3 and up in default builds of OpenSSL.
11+ o Disable SSLv2 default build, default negotiation and weak ciphers
12+ (CVE-2016-0800)
13+ o Fix a double-free in DSA code (CVE-2016-0705)
14+ o Disable SRP fake user seed to address a server memory leak
15+ (CVE-2016-0798)
16+ o Fix BN_hex2bn/BN_dec2bn NULL pointer deref/heap corruption
17+ (CVE-2016-0797)
18+ o Fix memory issues in BIO_*printf functions (CVE-2016-0799)
19+ o Fix side channel attack on modular exponentiation (CVE-2016-0702)
20+
821 Major changes between OpenSSL 1.0.2e and OpenSSL 1.0.2f [28 Jan 2016]
922
1023 o DH small subgroups (CVE-2016-0701)
--- a/contrib/openssl/README
+++ b/contrib/openssl/README
@@ -1,5 +1,5 @@
11
2- OpenSSL 1.0.2f 28 Jan 2016
2+ OpenSSL 1.0.2g 1 Mar 2016
33
44 Copyright (c) 1998-2015 The OpenSSL Project
55 Copyright (c) 1995-1998 Eric A. Young, Tim J. Hudson
--- a/contrib/openssl/include/openssl/bio.h
+++ b/contrib/openssl/include/openssl/bio.h
@@ -479,7 +479,7 @@ struct bio_dgram_sctp_prinfo {
479479 # define BIO_get_conn_hostname(b) BIO_ptr_ctrl(b,BIO_C_GET_CONNECT,0)
480480 # define BIO_get_conn_port(b) BIO_ptr_ctrl(b,BIO_C_GET_CONNECT,1)
481481 # define BIO_get_conn_ip(b) BIO_ptr_ctrl(b,BIO_C_GET_CONNECT,2)
482-# define BIO_get_conn_int_port(b) BIO_ctrl(b,BIO_C_GET_CONNECT,3,0,NULL)
482+# define BIO_get_conn_int_port(b) BIO_ctrl(b,BIO_C_GET_CONNECT,3,NULL)
483483
484484 # define BIO_set_nbio(b,n) BIO_ctrl(b,BIO_C_SET_NBIO,(n),NULL)
485485
@@ -689,7 +689,7 @@ long BIO_debug_callback(BIO *bio, int cmd, const char *argp, int argi,
689689 long argl, long ret);
690690
691691 BIO_METHOD *BIO_s_mem(void);
692-BIO *BIO_new_mem_buf(void *buf, int len);
692+BIO *BIO_new_mem_buf(const void *buf, int len);
693693 BIO_METHOD *BIO_s_socket(void);
694694 BIO_METHOD *BIO_s_connect(void);
695695 BIO_METHOD *BIO_s_accept(void);
--- a/contrib/openssl/include/openssl/bn.h
+++ b/contrib/openssl/include/openssl/bn.h
@@ -125,6 +125,7 @@
125125 #ifndef HEADER_BN_H
126126 # define HEADER_BN_H
127127
128+# include <limits.h>
128129 # include <openssl/e_os2.h>
129130 # ifndef OPENSSL_NO_FP_API
130131 # include <stdio.h> /* FILE */
@@ -721,8 +722,17 @@ const BIGNUM *BN_get0_nist_prime_521(void);
721722
722723 /* library internal functions */
723724
724-# define bn_expand(a,bits) ((((((bits+BN_BITS2-1))/BN_BITS2)) <= (a)->dmax)?\
725- (a):bn_expand2((a),(bits+BN_BITS2-1)/BN_BITS2))
725+# define bn_expand(a,bits) \
726+ ( \
727+ bits > (INT_MAX - BN_BITS2 + 1) ? \
728+ NULL \
729+ : \
730+ (((bits+BN_BITS2-1)/BN_BITS2) <= (a)->dmax) ? \
731+ (a) \
732+ : \
733+ bn_expand2((a),(bits+BN_BITS2-1)/BN_BITS2) \
734+ )
735+
726736 # define bn_wexpand(a,words) (((words) <= (a)->dmax)?(a):bn_expand2((a),(words)))
727737 BIGNUM *bn_expand2(BIGNUM *a, int words);
728738 # ifndef OPENSSL_NO_DEPRECATED
--- a/contrib/openssl/include/openssl/crypto.h
+++ b/contrib/openssl/include/openssl/crypto.h
@@ -628,7 +628,7 @@ void OPENSSL_init(void);
628628 * into a defined order as the return value when a != b is undefined, other
629629 * than to be non-zero.
630630 */
631-int CRYPTO_memcmp(const void *a, const void *b, size_t len);
631+int CRYPTO_memcmp(const volatile void *a, const volatile void *b, size_t len);
632632
633633 /* BEGIN ERROR CODES */
634634 /*
--- a/contrib/openssl/include/openssl/dh.h
+++ b/contrib/openssl/include/openssl/dh.h
@@ -174,7 +174,7 @@ struct dh_st {
174174 /* DH_check_pub_key error codes */
175175 # define DH_CHECK_PUBKEY_TOO_SMALL 0x01
176176 # define DH_CHECK_PUBKEY_TOO_LARGE 0x02
177-# define DH_CHECK_PUBKEY_INVALID 0x03
177+# define DH_CHECK_PUBKEY_INVALID 0x04
178178
179179 /*
180180 * primes p where (p-1)/2 is prime too are called "safe"; we define this for
--- a/contrib/openssl/include/openssl/opensslconf.h
+++ b/contrib/openssl/include/openssl/opensslconf.h
@@ -41,12 +41,18 @@ extern "C" {
4141 #ifndef OPENSSL_NO_SSL_TRACE
4242 # define OPENSSL_NO_SSL_TRACE
4343 #endif
44+#ifndef OPENSSL_NO_SSL2
45+# define OPENSSL_NO_SSL2
46+#endif
4447 #ifndef OPENSSL_NO_STORE
4548 # define OPENSSL_NO_STORE
4649 #endif
4750 #ifndef OPENSSL_NO_UNIT_TEST
4851 # define OPENSSL_NO_UNIT_TEST
4952 #endif
53+#ifndef OPENSSL_NO_WEAK_SSL_CIPHERS
54+# define OPENSSL_NO_WEAK_SSL_CIPHERS
55+#endif
5056
5157 #endif /* OPENSSL_DOING_MAKEDEPEND */
5258
@@ -92,12 +98,18 @@ extern "C" {
9298 # if defined(OPENSSL_NO_SSL_TRACE) && !defined(NO_SSL_TRACE)
9399 # define NO_SSL_TRACE
94100 # endif
101+# if defined(OPENSSL_NO_SSL2) && !defined(NO_SSL2)
102+# define NO_SSL2
103+# endif
95104 # if defined(OPENSSL_NO_STORE) && !defined(NO_STORE)
96105 # define NO_STORE
97106 # endif
98107 # if defined(OPENSSL_NO_UNIT_TEST) && !defined(NO_UNIT_TEST)
99108 # define NO_UNIT_TEST
100109 # endif
110+# if defined(OPENSSL_NO_WEAK_SSL_CIPHERS) && !defined(NO_WEAK_SSL_CIPHERS)
111+# define NO_WEAK_SSL_CIPHERS
112+# endif
101113 #endif
102114
103115 /* crypto/opensslconf.h.in */
--- a/contrib/openssl/include/openssl/opensslv.h
+++ b/contrib/openssl/include/openssl/opensslv.h
@@ -30,11 +30,11 @@ extern "C" {
3030 * (Prior to 0.9.5a beta1, a different scheme was used: MMNNFFRBB for
3131 * major minor fix final patch/beta)
3232 */
33-# define OPENSSL_VERSION_NUMBER 0x1000206fL
33+# define OPENSSL_VERSION_NUMBER 0x1000207fL
3434 # ifdef OPENSSL_FIPS
35-# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2f-fips 28 Jan 2016"
35+# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2g-fips 1 Mar 2016"
3636 # else
37-# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2f 28 Jan 2016"
37+# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2g 1 Mar 2016"
3838 # endif
3939 # define OPENSSL_VERSION_PTEXT " part of " OPENSSL_VERSION_TEXT
4040
--- a/contrib/openssl/include/openssl/srp.h
+++ b/contrib/openssl/include/openssl/srp.h
@@ -82,16 +82,21 @@ typedef struct SRP_gN_cache_st {
8282 DECLARE_STACK_OF(SRP_gN_cache)
8383
8484 typedef struct SRP_user_pwd_st {
85+ /* Owned by us. */
8586 char *id;
8687 BIGNUM *s;
8788 BIGNUM *v;
89+ /* Not owned by us. */
8890 const BIGNUM *g;
8991 const BIGNUM *N;
92+ /* Owned by us. */
9093 char *info;
9194 } SRP_user_pwd;
9295
9396 DECLARE_STACK_OF(SRP_user_pwd)
9497
98+void SRP_user_pwd_free(SRP_user_pwd *user_pwd);
99+
95100 typedef struct SRP_VBASE_st {
96101 STACK_OF(SRP_user_pwd) *users_pwd;
97102 STACK_OF(SRP_gN_cache) *gN_cache;
@@ -115,7 +120,12 @@ DECLARE_STACK_OF(SRP_gN)
115120 SRP_VBASE *SRP_VBASE_new(char *seed_key);
116121 int SRP_VBASE_free(SRP_VBASE *vb);
117122 int SRP_VBASE_init(SRP_VBASE *vb, char *verifier_file);
123+
124+/* This method ignores the configured seed and fails for an unknown user. */
118125 SRP_user_pwd *SRP_VBASE_get_by_user(SRP_VBASE *vb, char *username);
126+/* NOTE: unlike in SRP_VBASE_get_by_user, caller owns the returned pointer.*/
127+SRP_user_pwd *SRP_VBASE_get1_by_user(SRP_VBASE *vb, char *username);
128+
119129 char *SRP_create_verifier(const char *user, const char *pass, char **salt,
120130 char **verifier, const char *N, const char *g);
121131 int SRP_create_verifier_BN(const char *user, const char *pass, BIGNUM **salt,
--- a/contrib/openssl/include/openssl/ssl.h
+++ b/contrib/openssl/include/openssl/ssl.h
@@ -2713,7 +2713,6 @@ void ERR_load_SSL_strings(void);
27132713 # define SSL_F_SSL3_SETUP_KEY_BLOCK 157
27142714 # define SSL_F_SSL3_SETUP_READ_BUFFER 156
27152715 # define SSL_F_SSL3_SETUP_WRITE_BUFFER 291
2716-# define SSL_F_SSL3_SHUTDOWN 396
27172716 # define SSL_F_SSL3_WRITE_BYTES 158
27182717 # define SSL_F_SSL3_WRITE_PENDING 159
27192718 # define SSL_F_SSL_ADD_CERT_CHAIN 318
Binary files a/dist/amd64/libeay32.dll and b/dist/amd64/libeay32.dll differ
Binary files a/dist/amd64/ssleay32.dll and b/dist/amd64/ssleay32.dll differ
Binary files a/dist/libeay32.dll and b/dist/libeay32.dll differ
Binary files a/dist/ssleay32.dll and b/dist/ssleay32.dll differ
--- a/socketwrapper.c
+++ b/socketwrapper.c
@@ -153,15 +153,15 @@ BOOL LoadOpenSSL()
153153 #ifdef ENABLE_PROCESS_PROTECTION
154154 // 同梱するOpenSSLのバージョンに合わせてSHA1ハッシュ値を変更すること
155155 #if defined(_M_IX86)
156- // ssleay32.dll 1.0.2f
157- RegisterTrustedModuleSHA1Hash("\xB7\xA4\x25\x22\x73\x62\xC9\x0D\xAA\xBD\x1F\x11\x61\x16\x02\x8A\x5C\x23\xDE\x38");
158- // libeay32.dll 1.0.2f
159- RegisterTrustedModuleSHA1Hash("\x89\xE8\x42\x0E\xDE\x75\x31\x94\xF3\xD0\x54\x02\xD1\x29\x89\x28\x89\x41\xDF\x19");
156+ // ssleay32.dll 1.0.2g
157+ RegisterTrustedModuleSHA1Hash("\x96\x60\x94\xD8\x35\xB8\xAC\x1B\xEC\xCB\x45\xAD\x1B\x3E\x4C\x9F\xDC\x78\xA9\xDC");
158+ // libeay32.dll 1.0.2g
159+ RegisterTrustedModuleSHA1Hash("\xBD\x91\xB9\x36\xC1\xC5\x65\x6D\x8F\xAA\xCF\x6F\x84\x8B\xC7\x77\x23\x8D\xE6\x2B");
160160 #elif defined(_M_AMD64)
161- // ssleay32.dll 1.0.2f
162- RegisterTrustedModuleSHA1Hash("\xB0\x89\xBB\x7C\x7A\xC1\x4E\x00\xC6\x9B\xEC\x36\xDE\x6C\xB6\x1F\xBE\x46\x55\x0E");
163- // libeay32.dll 1.0.2f
164- RegisterTrustedModuleSHA1Hash("\xC5\x59\x7B\x0C\x3C\xF6\x8E\xF8\x10\x18\x3D\x59\x8C\x47\x14\xCA\xB6\xD2\x58\x75");
161+ // ssleay32.dll 1.0.2g
162+ RegisterTrustedModuleSHA1Hash("\xF8\x88\xEB\xC1\x2B\xE6\xE4\xFD\xFA\xCA\x9F\xAB\x2F\x46\x47\xC4\x56\x11\xF8\x21");
163+ // libeay32.dll 1.0.2g
164+ RegisterTrustedModuleSHA1Hash("\x70\xAD\x36\x15\xB1\x2C\x82\xAF\xD4\x93\x17\xD4\x82\xC7\x15\x4B\x89\x86\xE3\xE6");
165165 #endif
166166 #endif
167167 g_hOpenSSL = LoadLibrary("ssleay32.dll");