[security-dev 00847]: Re: Code review request: 6813340: X509Factory should not depend on is.available()==0

2009-05-25 Thread Xuelei Fan
1. 116 byte[] buffer = new byte[length]; I would like to use a fixed length, such as 1024, for memory saving for large data. Just a very very personal preference. 2. 562 ~ 567 You assume that the end character of a line is the same for all lines. That's OK, I just worry about the

[security-dev 00848]: Re: Code review request: 6813340: X509Factory should not depend on is.available()==0

2009-05-25 Thread Max (Weijun) Wang
On May 25, 2009, at 6:47 PM, Xuelei Fan wrote: 1. 116 byte[] buffer = new byte[length]; I would like to use a fixed length, such as 1024, for memory saving for large data. Just a very very personal preference. I see what you mean. My attempt was read it in a single shot. Will

[security-dev 00851]: Re: Code review request: 6813340: X509Factory should not depend on is.available()==0

2009-05-25 Thread Xuelei Fan
Max (Weijun) Wang wrote: 3. 584 ~ EOF You assume that the tag occupy only one byte, that's incorrect, the tag would occupy more than one byte when it is bigger than 30. The assume would make the following length parser code incorrect. You assume that the end of indefinite length is only

[security-dev 00852]: Re: Code review request: 6813340: X509Factory should not depend on is.available()==0

2009-05-25 Thread Xuelei Fan
Xuelei Fan wrote: t to support indefinite-length, I think you can simply keep reading until get two zero bytes. As I understand, 0x80 0x06 0x07 0x01 0x00 0x00 is not an indef-len BER. You're right, it is not a valid indef-len BER. I will look twice of readBERInternal() tomorrow. The

[security-dev 00854]: hg: jdk7/tl/jdk: 6349566: java.net.CookieManager doesn't set default domain

2009-05-25 Thread jean-christophe . collet
Changeset: 206d73d299d4 Author:jccollet Date: 2009-05-25 22:27 +0200 URL: http://hg.openjdk.java.net/jdk7/tl/jdk/rev/206d73d299d4 6349566: java.net.CookieManager doesn't set default domain Summary: Enforce default domain in CookieManager Reviewed-by: michaelm !

[security-dev 00856]: Re: hg pull failed: patch cannot be decoded

2009-05-25 Thread Xuelei Fan
Brad Wetmore wrote: There was a problem where the tl and tl-gate got out of sync and was fixed around 12:35 this afternoon. I don't know if it's the cause of your problem. The hg pull still did not work for me. but the hg clone works now. Thanks, Andrew brad Xuelei Fan wrote: $ hg

[security-dev 00858]: Re: Code review request: 6813340: X509Factory should not depend on is.available()==0

2009-05-25 Thread Weijun Wang
The new webrev is at http://cr.openjdk.java.net/~weijun/6813340/webrev.03 Changes compared to last webrev is: diff -r 59db2c7c37fa src/share/classes/sun/security/provider/X509Factory.java --- a/src/share/classes/sun/security/provider/X509Factory.java +++