Re: RFR: JDK-8303465: KeyStore of type KeychainStore, provider Apple shows different behavior after 8278449

2023-03-02 Thread Matthias Baesken
On Thu, 2 Mar 2023 15:23:02 GMT, Weijun Wang wrote: > dump-trust-setting I have found some errors with dump-trust-settings like this one https://github.com/wbond/package_control/issues/1017 but not sure if this is related to what you saw on your test infrastructure. - PR: https:

Re: RFR: 8297955: LDAP CertStore should use LdapName and not String for DNs

2023-03-02 Thread Rajan Halade
On Thu, 23 Feb 2023 16:42:17 GMT, Sean Mullan wrote: > The LDAPCertStore implementation passes Distinguished Names in CRL and > Certificate URLs as Strings to JNDI APIs such as > LdapContext.getAttributes(String), which then treats them as CompositeNames. > This causes issues with URLs that ha

Re: RFR: 8297955: LDAP CertStore should use LdapName and not String for DNs

2023-03-02 Thread Weijun Wang
On Thu, 23 Feb 2023 16:42:17 GMT, Sean Mullan wrote: > The LDAPCertStore implementation passes Distinguished Names in CRL and > Certificate URLs as Strings to JNDI APIs such as > LdapContext.getAttributes(String), which then treats them as CompositeNames. > This causes issues with URLs that ha

Re: RFR: 8303480: Miscellaneous fixes to mostly invisible doc comments

2023-03-02 Thread Chris Plummer
On Thu, 2 Mar 2023 12:03:44 GMT, Pavel Rappo wrote: > Please review this superficial documentation cleanup that was triggered by > unrelated analysis of doc comments in JDK API. > > The only effect that this multi-area PR has on the JDK API Documentation > (i.e. the observable effect on the ge

Re: RFR: 8303480: Miscellaneous fixes to mostly invisible doc comments

2023-03-02 Thread Phil Race
On Thu, 2 Mar 2023 12:03:44 GMT, Pavel Rappo wrote: > Please review this superficial documentation cleanup that was triggered by > unrelated analysis of doc comments in JDK API. > > The only effect that this multi-area PR has on the JDK API Documentation > (i.e. the observable effect on the ge

Re: RFR: JDK-8303465: KeyStore of type KeychainStore, provider Apple shows different behavior after 8278449

2023-03-02 Thread Weijun Wang
On Thu, 2 Mar 2023 13:33:53 GMT, Matthias Baesken wrote: > After 8278449, we seem to ignore in the call > > ` if (SecTrustSettingsCopyTrustSettings(certRef, > kSecTrustSettingsDomainUser, &trustSettings) == errSecItemNotFound) ` > > all trusted certs from admin and system domains, so a lot mo

Re: RFR: JDK-8303465: KeyStore of type KeychainStore, provider Apple shows different behavior after 8278449

2023-03-02 Thread Weijun Wang
On Thu, 2 Mar 2023 16:07:58 GMT, Matthias Baesken wrote: > > I'd like to contribute a test. > > Thanks for contributing the test. Any suggestion where to place the test ? Maybe just in `test/jdk/java/security/KeyStore/`. Otherwise needs to create a new dir and add it into some groups. ---

RFR: 8297955: LDAP CertStore should use LdapName and not String for DNs

2023-03-02 Thread Sean Mullan
The LDAPCertStore implementation passes Distinguished Names in CRL and Certificate URLs as Strings to JNDI APIs such as LdapContext.getAttributes(String), which then treats them as CompositeNames. This causes issues with URLs that have DNs with forward slashes. These are rare but compliant wit

Re: RFR: JDK-8303465: KeyStore of type KeychainStore, provider Apple shows different behavior after 8278449

2023-03-02 Thread Matthias Baesken
On Thu, 2 Mar 2023 15:23:02 GMT, Weijun Wang wrote: > I'd like to contribute a test. Thanks for contributing the test. Any suggestion where to place the test ? - PR: https://git.openjdk.org/jdk/pull/12829

Re: RFR: JDK-8303465: KeyStore of type KeychainStore, provider Apple shows different behavior after 8278449

2023-03-02 Thread Weijun Wang
On Thu, 2 Mar 2023 13:33:53 GMT, Matthias Baesken wrote: > After 8278449, we seem to ignore in the call > > ` if (SecTrustSettingsCopyTrustSettings(certRef, > kSecTrustSettingsDomainUser, &trustSettings) == errSecItemNotFound) ` > > all trusted certs from admin and system domains, so a lot mo

Integrated: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return

2023-03-02 Thread Matthias Baesken
On Tue, 28 Feb 2023 15:17:19 GMT, Matthias Baesken wrote: > We have a (potential) early return in addCertificatesToKeystore in > KeystoreImpl.m . This is implemented by the CHECK_NULL macro. However this > missed a CFRelease call. This pull request has now been integrated. Changeset: b51ea420

Re: RFR: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return [v2]

2023-03-02 Thread Matthias Baesken
On Thu, 2 Mar 2023 09:47:56 GMT, Matthias Baesken wrote: >> We have a (potential) early return in addCertificatesToKeystore in >> KeystoreImpl.m . This is implemented by the CHECK_NULL macro. However this >> missed a CFRelease call. > > Matthias Baesken has updated the pull request incrementall

Re: RFR: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return [v2]

2023-03-02 Thread Matthias Baesken
On Thu, 2 Mar 2023 13:54:05 GMT, Weijun Wang wrote: > Thanks for the fix. I almost think we should invent a CHECK_NULL_GOTO_ERROUT > macro, but your fix is also OK. I think I discussed a while back some extended CHECK_NULL_ - macros (I think it was for freeing before return) but it was not s

Re: RFR: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return [v2]

2023-03-02 Thread Weijun Wang
On Thu, 2 Mar 2023 08:22:58 GMT, Matthias Baesken wrote: >> src/java.base/macosx/native/libosxsecurity/KeystoreImpl.m line 431: >> >>> 429: CFRelease(trustSettings); >>> 430: goto errOut; >>> 431: } >> >> Do you also need to switch to `goto errOut` fo

Re: RFR: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return [v2]

2023-03-02 Thread Weijun Wang
On Thu, 2 Mar 2023 09:47:56 GMT, Matthias Baesken wrote: >> We have a (potential) early return in addCertificatesToKeystore in >> KeystoreImpl.m . This is implemented by the CHECK_NULL macro. However this >> missed a CFRelease call. > > Matthias Baesken has updated the pull request incrementall

Re: RFR: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return [v2]

2023-03-02 Thread Martin Doerr
On Thu, 2 Mar 2023 09:47:56 GMT, Matthias Baesken wrote: >> We have a (potential) early return in addCertificatesToKeystore in >> KeystoreImpl.m . This is implemented by the CHECK_NULL macro. However this >> missed a CFRelease call. > > Matthias Baesken has updated the pull request incrementall

RFR: JDK-8303465: KeyStore of type KeychainStore, provider Apple shows different behavior after 8278449

2023-03-02 Thread Matthias Baesken
After 8278449, we seem to ignore in the call ` if (SecTrustSettingsCopyTrustSettings(certRef, kSecTrustSettingsDomainUser, &trustSettings) == errSecItemNotFound) ` all trusted certs from admin and system domains, so a lot more certs are ignored than necessary. Probably we should take at least

Re: RFR: 8303480: Miscellaneous fixes to mostly invisible doc comments

2023-03-02 Thread Sean Mullan
On Thu, 2 Mar 2023 12:03:44 GMT, Pavel Rappo wrote: > Please review this superficial documentation cleanup that was triggered by > unrelated analysis of doc comments in JDK API. > > The only effect that this multi-area PR has on the JDK API Documentation > (i.e. the observable effect on the ge

RFR: 8303480: Miscellaneous fixes to mostly invisible doc comments

2023-03-02 Thread Pavel Rappo
Please review this superficial documentation cleanup that was triggered by unrelated analysis of doc comments in JDK API. The only effect that this multi-area PR has on the JDK API Documentation (i.e. the observable effect on the generated HTML pages) can be summarized as follows: diff -ur

Re: RFR: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return [v2]

2023-03-02 Thread Matthias Baesken
> We have a (potential) early return in addCertificatesToKeystore in > KeystoreImpl.m . This is implemented by the CHECK_NULL macro. However this > missed a CFRelease call. Matthias Baesken has updated the pull request incrementally with one additional commit since the last revision: handle

Re: RFR: JDK-8303354: addCertificatesToKeystore in KeystoreImpl.m needs CFRelease call in early potential CHECK_NULL return

2023-03-02 Thread Matthias Baesken
On Wed, 1 Mar 2023 19:51:46 GMT, Weijun Wang wrote: >> We have a (potential) early return in addCertificatesToKeystore in >> KeystoreImpl.m . This is implemented by the CHECK_NULL macro. However this >> missed a CFRelease call. > > src/java.base/macosx/native/libosxsecurity/KeystoreImpl.m line