Re: Code Review Request: TLS 1.3 Implementation

2018-06-08 Thread Jamil Nimeh
Hi Brad, just one follow-up to your CipherSuite comment, please see below. --Jamil On 06/08/2018 07:55 PM, Bradford Wetmore wrote: CipherSuite.java 74:  There is a mix of ciphersuite initialization styles, which I find confusing.  In the *_OF_12, you pass the MAC of M_NULL,

Re: Code Review Request: TLS 1.3 Implementation

2018-06-08 Thread Xuelei Fan
Update: http://hg.openjdk.java.net/jdk/sandbox/rev/a02692615745 Code clean up for SSLSessionContextImpl.java On 6/7/2018 10:28 AM, Bradford Wetmore wrote: SSLSessionContextImpl.java -- The only change here was to reorder the import of Vector (obsolete) and update the c

Re: Code Review Request: TLS 1.3 Implementation

2018-06-08 Thread Bradford Wetmore
CipherSuite.java 74: There is a mix of ciphersuite initialization styles, which I find confusing. In the *_OF_12, you pass the MAC of M_NULL, with H_* being used for PRF/HASH, which is also used for the MAC value for new suites, IIUC. Would you consider specifying both in

Re: Code Review Request: TLS 1.3 Implementation

2018-06-08 Thread Xuelei Fan
> BaseSSLSocketImpl.java > -- Update: http://hg.openjdk.java.net/jdk/sandbox/rev/bad9f4c7eeec Update to handle EOFException and requireCloseNotify property. Xuelei On 6/7/2018 10:28 AM, Bradford Wetmore wrote: Also reviewed SSLSocketFactoryImpl.java BaseSSLSocketImpl.java

Re: Code Review Request: TLS 1.3 Implementation

2018-06-08 Thread Valerie Peng
Hi Xuelei, Will this.requestedServerNames ever be null? This field is initialized in constructors with Collections.xxxList(...) method. Are the two private fields "peerPrincipal" and "localPrincipal" really used? There are two pkg private methods, setPeer/LocalPrincipal(...) which sets the

Re: Code Review Request: TLS 1.3 full handshake (JDK-8196584)

2018-06-08 Thread Xuelei Fan
Update: http://hg.openjdk.java.net/jdk/sandbox/rev/ad4c1c488574 This update cleans the unused methods in RSASignature.java. Xuelei On 6/7/2018 5:25 PM, Xuelei Fan wrote: On 6/7/2018 3:27 PM, Valerie Peng wrote: Hi Xuelei, There seems to be inconsistency in whether you can override the inte

Re: Code Review Request: TLS 1.3 full handshake (JDK-8196584)

2018-06-08 Thread Xuelei Fan
> http://cr.openjdk.java.net/~xuelei/8196584/webrev-full.02 Update: http://hg.openjdk.java.net/jdk/sandbox/rev/f4c7a97a1275 On 6/8/2018 12:19 PM, Valerie Peng wrote: Hi Xuelei, Some typos, line 139: minial -> minimal, line 144: caculate -> calculate, minial -> minimal When constructing PSSP

Re: Code Review Request: TLS 1.3 full handshake (JDK-8196584)

2018-06-08 Thread Valerie Peng
Hi Xuelei, Some typos, line 139: minial -> minimal, line 144: caculate -> calculate, minial -> minimal When constructing PSSParameterSpec object on line 174, I think it's better to specify new MGF1ParameterSpec(hash) instead of null. Although current RSASSA-PSS signature algorithm impl in Su

Re: SSLStringize.java (was Re: Code Review Request: TLS 1.3 Implementation)

2018-06-08 Thread Xuelei Fan
Update: http://hg.openjdk.java.net/jdk/sandbox/rev/25178bb3e8f5 On 6/6/2018 3:58 AM, Weijun Wang wrote: SSLStringize.java: 1. I assume the toString() method does not change the internal status of a ByteBuffer? Is it worth mentioning this in the spec? 2. Should this interface and all its imple

Re: RFR JDK-8178374: Problematic ByteBuffer handling in CipherSpi.bufferCrypt method

2018-06-08 Thread Anthony Scarpino
On 06/06/2018 02:16 PM, Valerie Peng wrote: Hi Tony, Can you please help reviewing this fix? The original impl uses buffering for both input and output and is broken in several places. I ended up re-writing most of them. The buffering is done only on input. The new regression test covers all

Re: Code Review Request: TLS 1.3 Implementation

2018-06-08 Thread Xuelei Fan
On 6/8/2018 10:21 AM, Xuelei Fan wrote: Here is the 3rd full webrev:    http://cr.openjdk.java.net/~xuelei/8196584/webrev-full.02 and the delta update to the 1st webrev: typo: 1st -> 2nd    http://cr.openjdk.java.net/~xuelei/8196584/webrev-delta.01 Xuelei On 6/3/2018 9:43 PM, Xuelei Fan w

Re: Code Review Request: TLS 1.3 Implementation

2018-06-08 Thread Xuelei Fan
Here is the 3rd full webrev: http://cr.openjdk.java.net/~xuelei/8196584/webrev-full.02 and the delta update to the 1st webrev: http://cr.openjdk.java.net/~xuelei/8196584/webrev-delta.01 Xuelei On 6/3/2018 9:43 PM, Xuelei Fan wrote: Hi, Here it the 2nd full webrev:   http://cr.openjdk.j

Re: RFR (XL): JDK-8204572 SetupJdkLibrary should setup SRC and -I flags automatically

2018-06-08 Thread Erik Joelsson
Looks good. /Erik On 2018-06-08 01:50, Magnus Ihse Bursie wrote: On 2018-06-07 23:20, Erik Joelsson wrote: Hello Magnus, Very nice refactoring! Thanks! JdkNativeCompilation.gmk line 126-127 looks a bit long. There is an extra space on 126. Also, why not addprefix for adding -I instead o

Re: RFR (XL): JDK-8204572 SetupJdkLibrary should setup SRC and -I flags automatically

2018-06-08 Thread Magnus Ihse Bursie
On 2018-06-07 23:20, Erik Joelsson wrote: Hello Magnus, Very nice refactoring! Thanks! JdkNativeCompilation.gmk line 126-127 looks a bit long. There is an extra space on 126. Also, why not addprefix for adding -I instead of clunky foreach? Not that I care greatly, but I usually prefer that