Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(428)

Issue 286030043: Bug 1228555 - Remove support for SSLv2 (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
8 years, 2 months ago by ttaubert
Modified:
8 years, 1 month ago
Reviewers:
ekr, mt, wtc1, ekr-rietveld
Visibility:
Public.

Description

Bug 1228555 - Remove support for SSLv2

Patch Set 1 #

Total comments: 79

Patch Set 2 : Bug 1228555 - Remove support for SSLv2 #

Patch Set 3 : Rebased #

Patch Set 4 : Bug 1228555 - Remove support for SSLv2 #

Total comments: 11

Patch Set 5 : Bug 1228555 - Remove support for SSLv2 #

Total comments: 39

Patch Set 6 : Rebased on top of DTLS 1.3 #

Patch Set 7 : Addressed ekr's comments #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+481 lines, -14651 lines) Patch
M cmd/lib/secutil.h View 1 2 3 4 5 6 1 chunk +3 lines, -9 lines 0 comments Download
M cmd/lib/secutil.c View 1 2 3 4 5 6 5 chunks +16 lines, -28 lines 0 comments Download
M cmd/listsuites/listsuites.c View 1 2 3 4 5 6 1 chunk +1 line, -2 lines 0 comments Download
M cmd/selfserv/selfserv.c View 1 2 3 4 5 6 10 chunks +9 lines, -36 lines 0 comments Download
M cmd/strsclnt/strsclnt.c View 1 2 3 4 5 6 10 chunks +18 lines, -58 lines 0 comments Download
M cmd/tstclnt/tstclnt.c View 1 2 3 4 5 6 9 chunks +10 lines, -43 lines 0 comments Download
M cmd/vfyserv/vfyserv.h View 1 2 3 4 5 6 1 chunk +0 lines, -1 line 0 comments Download
M cmd/vfyserv/vfyserv.c View 1 2 3 4 5 6 3 chunks +6 lines, -7 lines 0 comments Download
M cmd/vfyserv/vfyutil.c View 1 2 3 4 5 6 2 chunks +1 line, -10 lines 0 comments Download
M lib/ssl/SSLerrs.h View 1 2 3 4 5 6 3 chunks +5 lines, -4 lines 2 comments Download
M lib/ssl/derive.c View 1 2 3 4 5 6 1 chunk +2 lines, -3 lines 0 comments Download
M lib/ssl/manifest.mn View 1 2 3 4 5 6 1 chunk +0 lines, -1 line 0 comments Download
M lib/ssl/notes.txt View 1 2 3 4 5 6 5 chunks +4 lines, -34 lines 0 comments Download
M lib/ssl/ssl.h View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M lib/ssl/ssl3con.c View 1 2 3 4 5 6 20 chunks +12 lines, -120 lines 0 comments Download
M lib/ssl/ssl3gthr.c View 1 2 3 4 5 6 2 chunks +28 lines, -0 lines 0 comments Download
M lib/ssl/sslauth.c View 1 2 3 4 5 6 1 chunk +1 line, -5 lines 0 comments Download
M lib/ssl/sslcon.c View 1 2 3 4 5 6 5 chunks +58 lines, -3479 lines 0 comments Download
M lib/ssl/sslenum.c View 1 2 3 4 5 6 1 chunk +0 lines, -8 lines 0 comments Download
M lib/ssl/sslerr.h View 1 2 3 4 5 6 5 chunks +12 lines, -2 lines 0 comments Download
D lib/ssl/sslgathr.c View 1 2 3 4 5 6 1 chunk +0 lines, -421 lines 0 comments Download
M lib/ssl/sslimpl.h View 1 2 3 4 5 6 17 chunks +37 lines, -188 lines 0 comments Download
M lib/ssl/sslinfo.c View 1 2 3 4 5 6 5 chunks +7 lines, -30 lines 0 comments Download
M lib/ssl/sslnonce.c View 1 2 3 4 5 6 4 chunks +33 lines, -58 lines 0 comments Download
M lib/ssl/sslproto.h View 1 2 3 4 5 6 4 chunks +35 lines, -44 lines 0 comments Download
M lib/ssl/sslsecur.c View 1 2 3 4 5 6 24 chunks +28 lines, -178 lines 0 comments Download
M lib/ssl/sslsnce.c View 1 2 3 4 5 6 19 chunks +135 lines, -295 lines 0 comments Download
M lib/ssl/sslsock.c View 1 2 3 4 5 6 26 chunks +10 lines, -147 lines 0 comments Download
M lib/ssl/ssltrace.c View 1 2 3 4 5 6 1 chunk +0 lines, -150 lines 0 comments Download
M lib/util/ciferfam.h View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M tests/iopr/server_scr/cipher.list View 1 2 3 4 5 6 1 chunk +0 lines, -12 lines 0 comments Download
D tests/pkcs11/netscape/suites/Makefile View 1 2 3 4 5 6 1 chunk +0 lines, -48 lines 0 comments Download
D tests/pkcs11/netscape/suites/config.mk View 1 2 3 4 5 6 1 chunk +0 lines, -14 lines 0 comments Download
D tests/pkcs11/netscape/suites/manifest.mn View 1 2 3 4 5 6 1 chunk +0 lines, -9 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/Makefile View 1 2 3 4 5 6 1 chunk +0 lines, -48 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/config.mk View 1 2 3 4 5 6 1 chunk +0 lines, -26 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/manifest.mn View 1 2 3 4 5 6 1 chunk +0 lines, -12 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/Makefile View 1 2 3 4 5 6 1 chunk +0 lines, -49 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/config.mk View 1 2 3 4 5 6 1 chunk +0 lines, -29 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/manifest.mn View 1 2 3 4 5 6 1 chunk +0 lines, -18 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/pk11test.h View 1 2 3 4 5 6 1 chunk +0 lines, -82 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/pk11test.c View 1 2 3 4 5 6 1 chunk +0 lines, -1331 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/pk11test.htp View 1 2 3 4 5 6 1 chunk +0 lines, -21 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/pkcs11.h View 1 2 3 4 5 6 1 chunk +0 lines, -161 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/pkcs11.reg View 1 2 3 4 5 6 1 chunk +0 lines, -932 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/pkcs11.rep View 1 2 3 4 5 6 1 chunk +0 lines, -129 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/pkcs11/rules.mk View 1 2 3 4 5 6 1 chunk +0 lines, -6 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/Makefile View 1 2 3 4 5 6 1 chunk +0 lines, -50 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/README View 1 2 3 4 5 6 1 chunk +0 lines, -11 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/config.mk View 1 2 3 4 5 6 1 chunk +0 lines, -34 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/manifest.mn View 1 2 3 4 5 6 1 chunk +0 lines, -25 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/sslc.h View 1 2 3 4 5 6 1 chunk +0 lines, -67 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/sslc.c View 1 2 3 4 5 6 1 chunk +0 lines, -263 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/ssls.h View 1 2 3 4 5 6 1 chunk +0 lines, -98 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/ssls.c View 1 2 3 4 5 6 1 chunk +0 lines, -76 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/sslt.h View 1 2 3 4 5 6 1 chunk +0 lines, -209 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/sslt.c View 1 2 3 4 5 6 1 chunk +0 lines, -1154 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/sslt.htp View 1 2 3 4 5 6 1 chunk +0 lines, -107 lines 0 comments Download
D tests/pkcs11/netscape/suites/security/ssl/sslt.rep View 1 2 3 4 5 6 1 chunk +0 lines, -389 lines 0 comments Download
D tests/pkcs11/netscape/trivial/.cvsignore View 1 2 3 4 5 6 1 chunk +0 lines, -6 lines 0 comments Download
D tests/pkcs11/netscape/trivial/Makefile.in View 1 2 3 4 5 6 1 chunk +0 lines, -146 lines 0 comments Download
D tests/pkcs11/netscape/trivial/README.txt View 1 2 3 4 5 6 1 chunk +0 lines, -56 lines 0 comments Download
D tests/pkcs11/netscape/trivial/acconfig.h View 1 2 3 4 5 6 1 chunk +0 lines, -7 lines 0 comments Download
D tests/pkcs11/netscape/trivial/config.h.in View 1 2 3 4 5 6 1 chunk +0 lines, -28 lines 0 comments Download
D tests/pkcs11/netscape/trivial/configure View 1 2 3 4 5 6 1 chunk +0 lines, -1906 lines 0 comments Download
D tests/pkcs11/netscape/trivial/configure.in View 1 2 3 4 5 6 1 chunk +0 lines, -150 lines 0 comments Download
D tests/pkcs11/netscape/trivial/install-sh View 1 2 3 4 5 6 1 chunk +0 lines, -251 lines 0 comments Download
D tests/pkcs11/netscape/trivial/trivial.c View 1 2 3 4 5 6 1 chunk +0 lines, -1280 lines 0 comments Download
M tests/ssl/ssl.sh View 1 2 3 4 5 6 6 chunks +8 lines, -32 lines 0 comments Download
M tests/ssl/sslcov.txt View 1 2 3 4 5 6 1 chunk +0 lines, -14 lines 0 comments Download
M tests/ssl/sslstress.txt View 1 2 3 4 5 6 2 chunks +0 lines, -2 lines 0 comments Download

Messages

Total messages: 17
ekr-rietveld
Tim, this is quite large so I am going to have to review it in ...
8 years, 2 months ago (2016-01-31 02:23:10 UTC) #1
ekr-rietveld
Tim, this is quite large so I am going to have to review it in ...
8 years, 2 months ago (2016-01-31 02:23:11 UTC) #2
ekr-rietveld
Wan-Teh, in case you are interested. https://codereview.appspot.com/286030043/diff/1/lib/ssl/SSLerrs.h File lib/ssl/SSLerrs.h (right): https://codereview.appspot.com/286030043/diff/1/lib/ssl/SSLerrs.h#newcode51 lib/ssl/SSLerrs.h:51: "Unrecognized SSL error ...
8 years, 2 months ago (2016-01-31 20:45:03 UTC) #3
mt
I found one serious problem, and maybe there is a latent bug, but I need ...
8 years, 2 months ago (2016-01-31 23:13:42 UTC) #4
mt
On 2016/01/31 23:13:42, mt wrote: > Maybe we need to look at whether ss->handshake != ...
8 years, 2 months ago (2016-02-04 02:20:38 UTC) #5
ttaubert
https://codereview.appspot.com/286030043/diff/1/cmd/lib/secutil.c File cmd/lib/secutil.c (right): https://codereview.appspot.com/286030043/diff/1/cmd/lib/secutil.c#newcode3724 cmd/lib/secutil.c:3724: SSLVersionRange *vrange, PRBool *enableSSL2) On 2016/01/31 02:23:10, ekr-webrtc wrote: ...
8 years, 2 months ago (2016-02-04 17:32:42 UTC) #6
ttaubert
Rebased and all feedback addressed.
8 years, 2 months ago (2016-02-04 17:34:19 UTC) #7
ttaubert
Rebased again after all the clang-formatting. Will upload the SSLv2 client hello as a second ...
8 years, 1 month ago (2016-02-29 15:11:30 UTC) #8
mt
LGTM https://codereview.appspot.com/286030043/diff/30001/lib/ssl/ssl.h File lib/ssl/ssl.h (left): https://codereview.appspot.com/286030043/diff/30001/lib/ssl/ssl.h#oldcode41 lib/ssl/ssl.h:41: #define SSL_IS_SSL2_CIPHER(which) (((which)&0xfff0) == 0xff00) You can't delete ...
8 years, 1 month ago (2016-03-02 03:28:30 UTC) #9
wtc1
Review comments on patch set 4: Please consider my review as supplemental. I will try ...
8 years, 1 month ago (2016-03-02 04:53:57 UTC) #10
ttaubert
https://codereview.appspot.com/286030043/diff/30001/lib/ssl/SSLerrs.h File lib/ssl/SSLerrs.h (right): https://codereview.appspot.com/286030043/diff/30001/lib/ssl/SSLerrs.h#newcode12 lib/ssl/SSLerrs.h:12: "Unrecognized SSL error code.") On 2016/03/02 04:53:57, wtc1 wrote: ...
8 years, 1 month ago (2016-03-02 13:15:47 UTC) #11
ekr-rietveld
ttaubert, I will try to review this over the next few days.
8 years, 1 month ago (2016-03-02 18:35:33 UTC) #12
ekr-rietveld
https://codereview.appspot.com/286030043/diff/40001/cmd/lib/secutil.c File cmd/lib/secutil.c (right): https://codereview.appspot.com/286030043/diff/40001/cmd/lib/secutil.c#newcode3788 cmd/lib/secutil.c:3788: } Is it actaually possible here to have max ...
8 years, 1 month ago (2016-03-08 13:25:56 UTC) #13
ekr-rietveld
Note: I didn't study anything in tests/pkcs11 or ssl.sh, sslcov.txt or sslstress.txt
8 years, 1 month ago (2016-03-08 14:03:33 UTC) #14
ttaubert
https://codereview.appspot.com/286030043/diff/40001/cmd/lib/secutil.c File cmd/lib/secutil.c (right): https://codereview.appspot.com/286030043/diff/40001/cmd/lib/secutil.c#newcode3788 cmd/lib/secutil.c:3788: } On 2016/03/08 13:25:55, ekr-webrtc wrote: > Is it ...
8 years, 1 month ago (2016-03-08 19:19:52 UTC) #15
ekr-rietveld
LGTM https://codereview.appspot.com/286030043/diff/40001/lib/ssl/ssl3con.c File lib/ssl/ssl3con.c (right): https://codereview.appspot.com/286030043/diff/40001/lib/ssl/ssl3con.c#newcode5306 lib/ssl/ssl3con.c:5306: : ssl_LookupSID(&ss->sec.ci.peer, ss->sec.ci.port, ss->peerID, ss->url); On 2016/03/08 19:19:52, ...
8 years, 1 month ago (2016-03-11 09:02:40 UTC) #16
ttaubert
8 years, 1 month ago (2016-03-11 10:53:20 UTC) #17
https://codereview.appspot.com/286030043/diff/40001/lib/ssl/ssl3con.c
File lib/ssl/ssl3con.c (right):

https://codereview.appspot.com/286030043/diff/40001/lib/ssl/ssl3con.c#newcode...
lib/ssl/ssl3con.c:5306: : ssl_LookupSID(&ss->sec.ci.peer, ss->sec.ci.port,
ss->peerID, ss->url);
On 2016/03/11 09:02:39, ekr-webrtc wrote:
> On 2016/03/08 19:19:52, ttaubert wrote:
> > On 2016/03/08 13:25:55, ekr-webrtc wrote:
> > > Is there a reason not to consolidate the SID-handling code from
> > > ssl_BeginClientHandshake()? It seems like its there to do v2/v3 detection
> > based
> > > on SID
> > 
> > That's a good point. I think we could indeed merge those two and there very
> > likely is a lot of duplicate work. I don't understand all of it very well
> though
> > and it seems like there is some stuff we do here (e.g. duplicate localCert)
> that
> > the other path doesn't do.
> > 
> > How about looking at this in a follow-up, later when we find some time for
it?
> 
> 
> Sure. File a bug

Filed bug 1255758.

https://codereview.appspot.com/286030043/diff/40001/lib/ssl/sslsecur.c
File lib/ssl/sslsecur.c (right):

https://codereview.appspot.com/286030043/diff/40001/lib/ssl/sslsecur.c#newcod...
lib/ssl/sslsecur.c:411: }
On 2016/03/11 09:02:39, ekr-webrtc wrote:
> On 2016/03/08 19:19:52, ttaubert wrote:
> > On 2016/03/08 13:25:55, ekr-webrtc wrote:
> > > Why do we need this arm?
> > 
> > The first arm gathers another handshake in a connection the has a version
> number
> > set before already. The second arm when firstHsDone=false means that this is
> the
> > first handshake. Could probably turn the !firstHsDone into an assertion but
> the
> > outcome would be the same.
> 
> Yes, please make it an assert. That would make it much clearer.

Done.

https://codereview.appspot.com/286030043/diff/60001/lib/ssl/SSLerrs.h
File lib/ssl/SSLerrs.h (right):

https://codereview.appspot.com/286030043/diff/60001/lib/ssl/SSLerrs.h#newcode459
lib/ssl/SSLerrs.h:459: "SSL received a missing_extenson alert.")
On 2016/03/11 09:02:39, ekr-webrtc wrote:
> Nit: "missing extension". Can you test?

Fixed.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b