Re: Get intermediate MessageDigest state?

2014-05-22 Thread Bernd Eckenfels
Am Thu, 22 May 2014 20:49:26 -0500 schrieb "David M. Lloyd" : > Using MessageDigest.clone() is the usual approach. Theoretically > though, some providers won't be cloneable; the only practical > recourse in this case is to replay the whole of the input, > unfortunately. Yes, I have the need to p

Re: Get intermediate MessageDigest state?

2014-05-22 Thread Bernd Eckenfels
Am Thu, 22 May 2014 20:49:26 -0500 schrieb "David M. Lloyd" : > Using MessageDigest.clone() is the usual approach. Theoretically > though, some providers won't be cloneable; the only practical > recourse in this case is to replay the whole of the input, > unfortunately. My problem is, that I nee

Re: Get intermediate MessageDigest state?

2014-05-22 Thread David M. Lloyd
On 05/22/2014 07:34 PM, Bernd Eckenfels wrote: Hello, for some applications I need to safe and resume the state of a MessageDigest implementation (SHA1 and others). I wonder if there has been any discussion about exporting states from Digesters or Cipher Streams? For MD5 there is a implementati

Re: Locking/Singleton in JCAUtil

2014-05-22 Thread Bernd Eckenfels
And just a followup: it is interesting to note, that this Utility is still used as default random source for Key Generators and DSA Signatures. I would expect those need to refer to SecureRandom.getInstanceStrong() instead? (the string instance getter is nowhere used?) Bernd

Locking/Singleton in JCAUtil

2014-05-22 Thread Bernd Eckenfels
Hello, by browsing the source code I run across the JCAUtil class. It is (among other stuff) responsible for providing a SecureRandom singleton. The code looks a bit strange. First of all, it defines a LOCK object, but instead of using an unreachable instancde (which is a common pattern for thos

Get intermediate MessageDigest state?

2014-05-22 Thread Bernd Eckenfels
Hello, for some applications I need to safe and resume the state of a MessageDigest implementation (SHA1 and others). I wonder if there has been any discussion about exporting states from Digesters or Cipher Streams? For MD5 there is a implementation which supports this, but of course I would pre

Re: RFR [8043507]: javax.smartcardio.CardTerminals.list() fails on MacOSX

2014-05-22 Thread Valerie (Yu-Ching) Peng
Looks good. Thanks, Valerie On 05/22/14 00:25, Ivan Gerasimov wrote: On 22.05.2014 3:13, Valerie (Yu-Ching) Peng wrote: Looks good. Thank you Valerie! Have you looked for similar problems in the code? I wonder if this is the only occurrence. I've scanned through the rest of pcsc.c and f

Re: RFR 8036709: Java 7 jarsigner displays warning about cert policy tree

2014-05-22 Thread Wang Weijun
On May 23, 2014, at 2:15, Sean Mullan wrote: > Hi Max, > > Did you consider using a CertPathBuilder instead? This should essentially do > the same thing (find a matching trust anchor, and build a validated path). I thought about it but anyway the certchain is still a chain. If I just treat t

Webrev for 8043342: StringBuffer/StringBuilder crypto changes.

2014-05-22 Thread Bradford Wetmore
No additional code review necessary, this is just an FYI. For internal reasons (i.e. we have to sign our JCE jar files), we have separated the JCE portion for: 8041679: Replace uses of StringBuffer with StringBuilder within the JDK into: 8043342: Replace uses of StringBuffer with StringBuild

Re: RFR 8036709: Java 7 jarsigner displays warning about cert policy tree

2014-05-22 Thread Sean Mullan
Hi Max, Did you consider using a CertPathBuilder instead? This should essentially do the same thing (find a matching trust anchor, and build a validated path). --Sean On 05/21/2014 08:20 PM, Wang Weijun wrote: Hi All Please review the code change at http://cr.openjdk.java.net/~weijun/

Re: RFR [8043507]: javax.smartcardio.CardTerminals.list() fails on MacOSX

2014-05-22 Thread Ivan Gerasimov
On 22.05.2014 3:13, Valerie (Yu-Ching) Peng wrote: Looks good. Thank you Valerie! Have you looked for similar problems in the code? I wonder if this is the only occurrence. I've scanned through the rest of pcsc.c and found a few other places that can potentially have the same issue. In al