135 Commits

Author SHA1 Message Date
wtc%google.com
7438b8e95a Bug 537356: Rename SCSV. In the final RFC, the symbolic name of the SCSV
changed to TLS_EMPTY_RENEGOTIATION_INFO_SCSV.  r=christophe,rrelyea.
Modified Files:
	cmd/ssltap/ssltap.c lib/ssl/ssl.h lib/ssl/ssl3con.c
	lib/ssl/sslproto.h


git-svn-id: svn://10.0.0.236/trunk@259715 18797224-902f-48f8-a5cc-f745e15eee43
2010-02-16 18:56:48 +00:00
wtc%google.com
13cd60e59c Bug 275744: Add new error code SSL_ERROR_RX_UNEXPECTED_UNCOMPRESSED_RECORD
when we detect missing compression.  The patch is contributed by Adam
Langley <agl@chromium.org>.  r=nelson,wtc.
Modified Files:
	cmd/lib/SSLerrs.h lib/ssl/ssl3con.c lib/ssl/sslerr.h


git-svn-id: svn://10.0.0.236/trunk@259586 18797224-902f-48f8-a5cc-f745e15eee43
2010-02-03 03:44:29 +00:00
wtc%google.com
d49496f0ff Bug 537356: Disable the ECC cipher suites for SSL 3.0 renegotiations
because we don't send the elliptic_curves and ec_point_format extensions
in SSL 3.0 client hello.  r=nelson.


git-svn-id: svn://10.0.0.236/trunk@259579 18797224-902f-48f8-a5cc-f745e15eee43
2010-02-03 02:46:15 +00:00
wtc%google.com
3f6d220c28 Bug 537356: server-side SSL_RENEGOTIATE_REQUIRES_XTN code should handle
both client-initiated (ss->ssl3.hs.ws == idle_handshake) and
server-initiated (ss->ssl3.hs.ws == wait_client_hello) renegotiations.
r=kaie,nelson.


git-svn-id: svn://10.0.0.236/trunk@259506 18797224-902f-48f8-a5cc-f745e15eee43
2010-01-29 19:55:42 +00:00
wtc%google.com
fa46d39e9d Bug 537356: In SSL 3.0, send and handle the renegotiation_info extension
but not any other extension.  r=rrelyea.
Modified Files:
	ssl3con.c ssl3ext.c


git-svn-id: svn://10.0.0.236/trunk@259505 18797224-902f-48f8-a5cc-f745e15eee43
2010-01-29 19:20:28 +00:00
kaie%kuix.de
bd4c4b9fa4 Bug 540304, Implement SSL_HandshakeNegotiatedExtension
r=nelson


git-svn-id: svn://10.0.0.236/trunk@259501 18797224-902f-48f8-a5cc-f745e15eee43
2010-01-28 16:14:25 +00:00
nelson%bolyard.com
0bc55de11a Bug 537356: Implement new safe SSL3 & TLS renegotiation, r=wtc
git-svn-id: svn://10.0.0.236/trunk@259500 18797224-902f-48f8-a5cc-f745e15eee43
2010-01-28 06:19:13 +00:00
wtc%google.com
66dfd7adba Bug 536474: Add support for logging pre-master secrets. The patch is
contributed by Adam Langley <agl@chromium.org>.  r=nelson,wtc.
Modified Files:
	ssl3con.c sslimpl.h sslsock.c


git-svn-id: svn://10.0.0.236/trunk@259455 18797224-902f-48f8-a5cc-f745e15eee43
2010-01-22 03:47:42 +00:00
alexei.volkov.bugs%sun.com
d26b36b737 360421 - Implement TLS Server Name Indication for servers. r=nelson
git-svn-id: svn://10.0.0.236/trunk@259396 18797224-902f-48f8-a5cc-f745e15eee43
2010-01-14 22:15:26 +00:00
wtc%google.com
0dd48d5002 Bug 531188: Don't call zlib with 0-length inputs (the avail_in is 0),
otherwise zlib returns Z_BUF_ERROR, which we consider fatal.  The patch is
contributed by Adam Langley of Google <agl@chromium.org>.  r=wtc,nelson.


git-svn-id: svn://10.0.0.236/trunk@259136 18797224-902f-48f8-a5cc-f745e15eee43
2009-12-01 17:59:46 +00:00
wtc%google.com
61c9cc167c Bug 531188: ssl3_DeflateDecompress should set an error code on failure.
Remove an extraneous ssl_ReleaseSpecReadLock(ss) call.  r=agl,nelson.


git-svn-id: svn://10.0.0.236/trunk@259090 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-26 01:51:10 +00:00
wtc%google.com
a75ee146fb Bug 275744: Fix a compilation error on Windows. Need to declare variables
at the beginning of a block.  TBR=nelson.


git-svn-id: svn://10.0.0.236/trunk@259051 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-21 05:31:16 +00:00
wtc%google.com
6159af71f0 Bug 275744: Back out the previous solution of undefining the compress macro
after including zlib.h.  Rename compress to compressor and decompress to
decompressor to avoid the compress macro that may be defined by zconf.h.
r=nelson.
Modified Files:
	ssl3con.c sslimpl.h


git-svn-id: svn://10.0.0.236/trunk@259050 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-21 03:40:49 +00:00
wtc%google.com
7b748542b5 Bug 275744: Make sure the compression of resumed sessions is correct. The
patch is contributed by Adam Langley of Google <agl@chromium.org>.
r=wtc,nelson.


git-svn-id: svn://10.0.0.236/trunk@259049 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-21 03:32:40 +00:00
wtc%google.com
0615d94be7 Bug 275744: Mozilla's zconf.h defines 'compress' as a macro. When NSS is
built as part of Mozilla, the 'compress' member of the ssl3CipherSpec
structure gets renamed.  Undefine 'compress' to avoid that.  r=nelson.


git-svn-id: svn://10.0.0.236/trunk@258982 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-12 05:08:27 +00:00
wtc%google.com
c0ec7fbfae Bug 275744: In client hello, list compression methods in the order of
desirability so that servers that simply pick the first mutually supported
compression method will pick the best compression method.  Add compression
method info to the SSLChannelInfo structure.  Rename SSL3CompressionMethod
to SSLCompressionMethod and add the ssl_ prefix to the enum constants.
Remove an extra comma in strsclnt.c that breaks the concatenation of two
string literals.  r=agl,rrelyea,nelson.
Modified Files:
	cmd/selfserv/selfserv.c cmd/strsclnt/strsclnt.c
	cmd/tstclnt/tstclnt.c lib/ssl/ssl3con.c lib/ssl/ssl3ext.c
	lib/ssl/ssl3prot.h lib/ssl/sslimpl.h lib/ssl/sslinfo.c
	lib/ssl/sslsnce.c lib/ssl/sslt.h tests/ssl/sslstress.txt


git-svn-id: svn://10.0.0.236/trunk@258919 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-07 18:23:06 +00:00
nelson%bolyard.com
089608da06 Bug 526689: (CVE-2009-3555) SSL3 & TLS Renegotiation Vulnerability
Disable SSL 3.x renegotiation by default.  Add new options to re-enable.
r=wtc,rrelyea


git-svn-id: svn://10.0.0.236/trunk@258888 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-06 20:11:29 +00:00
wtc%google.com
7904b372b3 Bug 275744: Implement TLS compression RFC 3749. Add the SSL_ENABLE_DEFLATE
SSL option and the -z command-line option for tstclnt, strsclnt, and
selfserv for enabling the DEFLATE compression method.  The patch is
contributed by Adam Langley <agl@chromium.org> of Google.  r=nelson.
Modified Files:
	cmd/selfserv/selfserv.c cmd/strsclnt/strsclnt.c
	cmd/tstclnt/tstclnt.c lib/ssl/Makefile lib/ssl/ssl.h
	lib/ssl/ssl3con.c lib/ssl/ssl3prot.h lib/ssl/sslerr.h
	lib/ssl/sslimpl.h lib/ssl/sslsock.c


git-svn-id: svn://10.0.0.236/trunk@258862 18797224-902f-48f8-a5cc-f745e15eee43
2009-11-04 17:19:25 +00:00
wtc%google.com
e8653a0f01 Bug 522580: Add the NSS_SecureMemcmp function that performs a constant-time
compare of two memory regions, and use it in libSSL for comparing secret
data.  The patch is contributed by Adam Langley <agl@chromium.org> of
Google.  r=wtc,nelson.
Modified Files:
	lib/ssl/ssl3con.c lib/ssl/sslcon.c lib/ssl/sslgathr.c
	lib/util/nssutil.def lib/util/secport.c lib/util/secport.h


git-svn-id: svn://10.0.0.236/trunk@258699 18797224-902f-48f8-a5cc-f745e15eee43
2009-10-16 17:45:36 +00:00
nelson%bolyard.com
d049b9bded Bug 481216: Fix specific spelling errors in NSS & NSPR, r=timeless
git-svn-id: svn://10.0.0.236/trunk@256449 18797224-902f-48f8-a5cc-f745e15eee43
2009-03-04 21:57:28 +00:00
nelson%bolyard.com
d2e7f8c5a8 Bug 441321: Tolerate incorrect encoding of DSA signatures in SSL 3.0 handshakes
r=wtc.


git-svn-id: svn://10.0.0.236/trunk@256213 18797224-902f-48f8-a5cc-f745e15eee43
2009-02-13 05:23:23 +00:00
nelson%bolyard.com
3bf81e175c Bug 453234: Support for SEED Cipher Suites to TLS RFC 4010
patch by Yeonjung Kang <kang.yeonjung@gmail.com>, r=nelson


git-svn-id: svn://10.0.0.236/trunk@255547 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-17 06:09:22 +00:00
wtc%google.com
997b195396 Bug 426266: Decoupled lib/softoken and lib/ssl. lib/softoken should not
include any headers from lib/ssl.  r=nelson.
Modified Files:
	softoken/pkcs11c.c ssl/manifest.mn ssl/ssl3con.c


git-svn-id: svn://10.0.0.236/trunk@254368 18797224-902f-48f8-a5cc-f745e15eee43
2008-09-22 23:47:00 +00:00
julien.pierre.boogz%sun.com
2294a416d4 Fix for bug 405652 . TLS ClientHello message has incorrect gmt_unix_time . r=nelson
git-svn-id: svn://10.0.0.236/trunk@248035 18797224-902f-48f8-a5cc-f745e15eee43
2008-03-18 01:32:18 +00:00
wtc%google.com
dd1ffe05f6 Bug 419523: Export Cert_NewTempCertificate. Remove unnecessary inclusions
of nssrenam.h.  Remove functions that no longer need to be renamed from
nssrenam.h.  r=rrelyea.
Modified Files:
	cmd/vfychain/vfychain.c lib/certdb/stanpcertdb.c
	lib/crmf/asn1cmn.c lib/crmf/cmmfrec.c lib/crmf/respcmn.c
	lib/nss/nss.def lib/nss/nssrenam.h lib/pkcs12/p12e.c
	lib/pkcs7/certread.c lib/pkcs7/p7decode.c lib/pkcs7/p7encode.c
	lib/smime/cmsutil.c lib/ssl/ssl3con.c lib/ssl/ssl3ecc.c
	lib/ssl/sslnonce.c lib/ssl/sslsnce.c


git-svn-id: svn://10.0.0.236/trunk@247455 18797224-902f-48f8-a5cc-f745e15eee43
2008-03-10 00:01:28 +00:00
wtc%google.com
6289ace530 Bug 403563: implement the TLS session ticket extension (rfc4507bis). The
patch is contributed by Nagendra Modadugu <ngm+mozilla@google.com>.  A
small portion (PKCS #11 code and tests) was written by Wan-Teh Chang
<wtc@google.com>.  r=nelson,wtc
Modified Files:
	cmd/lib/SSLerrs.h cmd/selfserv/selfserv.c
	cmd/strsclnt/strsclnt.c cmd/tstclnt/tstclnt.c
	lib/ssl/manifest.mn lib/ssl/ssl.h lib/ssl/ssl3con.c
	lib/ssl/ssl3ecc.c lib/ssl/ssl3prot.h lib/ssl/sslerr.h
	lib/ssl/sslimpl.h lib/ssl/sslnonce.c lib/ssl/sslsnce.c
	lib/ssl/sslsock.c lib/ssl/sslt.h tests/ssl/sslstress.txt
Added Files:
	lib/ssl/ssl3ext.c


git-svn-id: svn://10.0.0.236/trunk@247232 18797224-902f-48f8-a5cc-f745e15eee43
2008-03-06 20:16:24 +00:00
wtc%google.com
952f1c36a1 Bug 417641: rewrote a || expression as an if statement to eliminate a GCC
warning.  r=nelson.


git-svn-id: svn://10.0.0.236/trunk@246449 18797224-902f-48f8-a5cc-f745e15eee43
2008-02-25 18:50:31 +00:00
julien.pierre.boogz%sun.com
b23b02f2e7 Fix for bug 397486 . Session cache locks not freed on strsclnt shutdown. r=nelson,wtc
git-svn-id: svn://10.0.0.236/trunk@246338 18797224-902f-48f8-a5cc-f745e15eee43
2008-02-23 02:21:47 +00:00
julien.pierre.boogz%sun.com
ccd194c6c8 Fix for bug 403240 . threads hanging in nss_InitLock . Additional changes for Wan-Teh's review for libssl.
git-svn-id: svn://10.0.0.236/trunk@246019 18797224-902f-48f8-a5cc-f745e15eee43
2008-02-20 00:11:16 +00:00
julien.pierre.boogz%sun.com
29443dfc70 Fix for bug 403240 - threads hanging in nss_InitLock . r=wtc,nelson
git-svn-id: svn://10.0.0.236/trunk@245810 18797224-902f-48f8-a5cc-f745e15eee43
2008-02-16 04:38:09 +00:00
nelson%bolyard.com
88d8b4f7a9 Back out last two changes to sslnonce.c.
git-svn-id: svn://10.0.0.236/trunk@245770 18797224-902f-48f8-a5cc-f745e15eee43
2008-02-15 07:39:23 +00:00
julien.pierre.boogz%sun.com
cdaa1bce3d Fix for bug 398680 . Memset extension sender structure. r=nelson
git-svn-id: svn://10.0.0.236/trunk@245267 18797224-902f-48f8-a5cc-f745e15eee43
2008-02-08 22:13:22 +00:00
nelson%bolyard.com
a5e1d31471 Bug 392846 - Do not send hello extensions when using SSL v3.0, r=kengert
git-svn-id: svn://10.0.0.236/trunk@232832 18797224-902f-48f8-a5cc-f745e15eee43
2007-08-22 06:12:02 +00:00
julien.pierre.bugs%sun.com
17ea357834 Fix for bug 90426 . Stop using obsolete int32 and uint32 typedefs . r=nelson
git-svn-id: svn://10.0.0.236/trunk@229406 18797224-902f-48f8-a5cc-f745e15eee43
2007-07-06 03:16:56 +00:00
nelson%bolyard.com
7069ddec51 Bug 373276 – Enhance SSL's Bypass feature to withstand failures. r=neil,alexei
git-svn-id: svn://10.0.0.236/trunk@225321 18797224-902f-48f8-a5cc-f745e15eee43
2007-05-01 03:54:58 +00:00
rrelyea%redhat.com
5e97cf8097 Add Camilla cipher suites TLS RFC4132 bug 361025
code supplied by okazaki@kick.gr.jp


git-svn-id: svn://10.0.0.236/trunk@221086 18797224-902f-48f8-a5cc-f745e15eee43
2007-02-28 19:47:40 +00:00
wtchang%redhat.com
1cb5d3ccbb Bugzilla Bug 363073: verify that the peer's ephemeral public key is the
type we expect before using it.  r=nelsonb
Modified Files: ssl3con.c ssl3ecc.c


git-svn-id: svn://10.0.0.236/trunk@216773 18797224-902f-48f8-a5cc-f745e15eee43
2006-12-08 22:37:29 +00:00
alexei.volkov.bugs%sun.com
5f7cf266e5 353888: klockwork IDs for ssl3con.c. r=nelson
git-svn-id: svn://10.0.0.236/trunk@213367 18797224-902f-48f8-a5cc-f745e15eee43
2006-10-09 22:26:44 +00:00
nelson%bolyard.com
bf090012bf Also trace the DH(E) PMS. bug 349966. r=julien.pierre, wtchang
git-svn-id: svn://10.0.0.236/trunk@209074 18797224-902f-48f8-a5cc-f745e15eee43
2006-09-02 18:53:54 +00:00
nelson%bolyard.com
5bc47a3fed re-enable SSLTRACE for keys and (pre)master secrets. Bug 349966. r=rrelyea
git-svn-id: svn://10.0.0.236/trunk@208358 18797224-902f-48f8-a5cc-f745e15eee43
2006-08-24 22:10:03 +00:00
nelson%bolyard.com
3c8ae7422c Correct ifdefs so that non-ECC builds will continue to build correctly.
r=wtchang  bug 341707.


git-svn-id: svn://10.0.0.236/trunk@203201 18797224-902f-48f8-a5cc-f745e15eee43
2006-07-20 00:17:23 +00:00
nelson%bolyard.com
505b7efaff Curve-limited clients must not negotiate ECC ciphersuites unless they send the supported curve extension. This means that when they are nogotiating SSL 3.0
and not TLS, they should not negotiate ECC ciphersuites at all.
Bug 341707.  r=rrelyea.


git-svn-id: svn://10.0.0.236/trunk@203068 18797224-902f-48f8-a5cc-f745e15eee43
2006-07-19 01:42:58 +00:00
alexei.volkov.bugs%sun.com
b1e4bcb35a 341291: Coverity 689 - potential NULL ptr crash in ssl3_SendCertificate. r=nelson
git-svn-id: svn://10.0.0.236/trunk@202256 18797224-902f-48f8-a5cc-f745e15eee43
2006-07-17 22:08:03 +00:00
wtchang%redhat.com
e82461ec07 Bugzilla Bug 338798: in C89, local struct variables can only be initialized
by constant expressions.  HP C compiler version B.11.11.08 generates
incorrect code silently if the initializers are non-constant expressions.
r=alexei.volkov,julien.pierre.
Modified files: cmd/crmftest/testcrmf.c lib/ssl/ssl3con.c


git-svn-id: svn://10.0.0.236/trunk@200976 18797224-902f-48f8-a5cc-f745e15eee43
2006-06-26 23:32:19 +00:00
wtchang%redhat.com
9d60721908 Bugzilla bug 338599: added new function SECKEY_SignatureLen and use it
instead of SECKEY_PublicKeyStrength to get ECDSA signature lengths.
Removed the 'type' member from the VFYContextStr structure because that
info is in the 'key->keyType' field.  Set error codes when functions
fail (return 0). r=nelsonb.
Modified Files:
	cryptohi/keyhi.h cryptohi/seckey.c cryptohi/secvfy.c
	nss/nss.def ssl/ssl3con.c


git-svn-id: svn://10.0.0.236/trunk@198781 18797224-902f-48f8-a5cc-f745e15eee43
2006-05-31 23:54:52 +00:00
nelson%bolyard.com
d41e92d455 Fix several Coverity bugs. Bug 336982. NULL ptr check after ptr deref'ed.
Bug 337080.  Dead code.  r=alexei.volkov


git-svn-id: svn://10.0.0.236/trunk@197950 18797224-902f-48f8-a5cc-f745e15eee43
2006-05-18 20:41:21 +00:00
alexei.volkov.bugs%sun.com
ea68cbd9e6 Patch contributed by jonsmirl@yahoo.com
[Bug 336932] Coverity 163, dead code in mozilla/security/nss/lib/ssl/ssl3con.c. r=nelson


git-svn-id: svn://10.0.0.236/trunk@196440 18797224-902f-48f8-a5cc-f745e15eee43
2006-05-13 00:15:43 +00:00
nelson%bolyard.com
c74c0d6ec1 Bug 80092: SSL write indicates all data sent when some is buffered.
SSL now follows NSPR socket semantics and never returns a short write
count on a blocking socket.  On a blocking socket, it returns either
the full count or -1 (with an error code set).
For non-blocking sockets, SSL no longer returns a full write count
when some of the data remains buffered in the SSL record layer.
Instead it returns a number is that always at least 1 byte short of a
full write count, so that the caller will  keep retrying until it is done.
SSL makes sure that the first byte sent by the caller in the retry
matches the last byte previously buffered.  r=rrelyea.
Modified Files: ssl3con.c sslcon.c ssldef.c sslimpl.h sslsecur.c


git-svn-id: svn://10.0.0.236/trunk@194962 18797224-902f-48f8-a5cc-f745e15eee43
2006-04-20 08:46:34 +00:00
nelson%bolyard.com
782997f209 Fix broken optimized builds, caused by last checkin. Bug 236245.
git-svn-id: svn://10.0.0.236/trunk@194370 18797224-902f-48f8-a5cc-f745e15eee43
2006-04-14 00:43:19 +00:00
nelson%bolyard.com
bafb7f6292 Implement TLS Hello extensions for ECC. Bug 236245. r=rrelyea.
This patch has a known problem, choosing ephemeral ECDH curves
according to the wrong (suboptimal, non-FIPS) criteria.
Modified Files: ssl3con.c ssl3ecc.c sslimpl.h


git-svn-id: svn://10.0.0.236/trunk@194359 18797224-902f-48f8-a5cc-f745e15eee43
2006-04-13 23:08:18 +00:00