Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat [v4]

2022-06-14 Thread Matthias Baesken
i.java:174) > at java.naming/com.sun.jndi.ldap.LdapURL.(LdapURL.java:105) > > I would like to add the host and port info to the exception (in the example > it is host:port of URI:null:-1] ) so that it is directly visible that the > input caused the construction of a URI > with &quo

Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat [v3]

2022-06-14 Thread Matthias Baesken
i.java:174) > at java.naming/com.sun.jndi.ldap.LdapURL.(LdapURL.java:105) > > I would like to add the host and port info to the exception (in the example > it is host:port of URI:null:-1] ) so that it is directly visible that the > input caused the construction of a URI > with &quo

Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat [v2]

2022-06-14 Thread Matthias Baesken
On Tue, 14 Jun 2022 10:43:54 GMT, Matthias Baesken wrote: >> When trying to construct an LdapURL object with a bad input string (in this >> example the _ in ad_jbs is causing issues), and not using >> the backward compatibility flag -Dcom.sun.jndi.ldapURLParsing=&

Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat [v2]

2022-06-14 Thread Matthias Baesken
i.java:174) > at java.naming/com.sun.jndi.ldap.LdapURL.(LdapURL.java:105) > > I would like to add the host and port info to the exception (in the example > it is host:port of URI:null:-1] ) so that it is directly visible that the > input caused the construction of a URI > with &quo

Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat

2022-06-14 Thread Matthias Baesken
On Fri, 10 Jun 2022 12:16:17 GMT, Matthias Baesken wrote: > When trying to construct an LdapURL object with a bad input string (in this > example the _ in ad_jbs is causing issues), and not using > the backward compatibility flag -Dcom.sun.jndi.ldapURLParsing="

Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat

2022-06-13 Thread Matthias Baesken
On Mon, 13 Jun 2022 14:29:44 GMT, Jaikiran Pai wrote: > > Hi Daniel, should we maybe better print something like "check for not > > allowed characters" in the exception ? Do you have an easy and cheap way in > > mind to the get the unsupported character (in this case "_") to add it to > > the

Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat

2022-06-13 Thread Matthias Baesken
On Fri, 10 Jun 2022 14:19:27 GMT, Daniel Fuchs wrote: > I might question whether the added "null:-1" information is really helpful, > or just as confusing however. Hi Daniel, should we maybe better print something like "check for not allowed characters" in the exception ? Do you have an easy

Re: RFR: JDK-8288207: Enhance MalformedURLException in Uri.parseCompat

2022-06-10 Thread Matthias Baesken
On Fri, 10 Jun 2022 13:15:11 GMT, Alan Bateman wrote: > We have to be cautious about leaking security sensitive configuration in > exception messages. Can you look at the security property > jdk.includeInException (conf/security/java.security) and usages in the JDK > for ideas on how this

[jdk18] Integrated: 8279385: [test] Adjust sun/security/pkcs12/KeytoolOpensslInteropTest.java after 8278344

2022-02-03 Thread Matthias Baesken
On Mon, 10 Jan 2022 13:36:25 GMT, Matthias Baesken wrote: > 8279385: [test] Adjust sun/security/pkcs12/KeytoolOpensslInteropTest.java > after 8278344 This pull request has now been integrated. Changeset: 01f93ddf Author:Matthias Baesken URL: https://git.openjdk.java.net

[jdk18] RFR: 8279385: [test] Adjust sun/security/pkcs12/KeytoolOpensslInteropTest.java after 8278344

2022-01-10 Thread Matthias Baesken
8279385: [test] Adjust sun/security/pkcs12/KeytoolOpensslInteropTest.java after 8278344 - Commit messages: - Backport 9bdf6eb7b2412ecff523015f1430dfb6a0e4dd09 Changes: https://git.openjdk.java.net/jdk18/pull/91/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk18=91=00

[jdk18] Integrated: 8278344: sun/security/pkcs12/KeytoolOpensslInteropTest.java test fails because of different openssl output

2022-01-10 Thread Matthias Baesken
On Mon, 10 Jan 2022 09:09:13 GMT, Matthias Baesken wrote: > 8278344: sun/security/pkcs12/KeytoolOpensslInteropTest.java test fails > because of different openssl output This pull request has now been integrated. Changeset: 06b4d494 Author:Matthias Baesken URL:

[jdk18] RFR: 8278344: sun/security/pkcs12/KeytoolOpensslInteropTest.java test fails because of different openssl output

2022-01-10 Thread Matthias Baesken
8278344: sun/security/pkcs12/KeytoolOpensslInteropTest.java test fails because of different openssl output - Commit messages: - Backport 8b5ff4bdffc8f32317d67b00c085071d6c772b30 Changes: https://git.openjdk.java.net/jdk18/pull/90/files Webrev:

Integrated: JDK-8279385: [test] Adjust sun/security/pkcs12/KeytoolOpensslInteropTest.java after 8278344

2022-01-03 Thread Matthias Baesken
On Mon, 3 Jan 2022 14:52:13 GMT, Matthias Baesken wrote: > Hello , please review this XXS test adjustment. After 8278344, it has been > commented that better shouldMatch should be used for the adjusted test > parsing output of different OpenSSL versions. This pull request has

RFR: JDK-8279385: [test] Adjust sun/security/pkcs12/KeytoolOpensslInteropTest.java after 8278344

2022-01-03 Thread Matthias Baesken
Hello , please review this XXS test adjustment. After 8278344, it has been commented that better shouldMatch should be used for the adjusted test parsing output of different OpenSSL versions. - Commit messages: - JDK-8279385 Changes:

Integrated: JDK-8278344: sun/security/pkcs12/KeytoolOpensslInteropTest.java test fails because of different openssl output

2021-12-12 Thread Matthias Baesken
On Thu, 9 Dec 2021 08:25:17 GMT, Matthias Baesken wrote: > Please review this small test fix. > KeytoolOpensslInteropTest.java fails with the output below. > Seems on our SUSE Linux 15 (openssl is > ~> openssl version > OpenSSL 1.1.0i-fips 14 Aug 2018 > ) we get a slig

Re: RFR: JDK-8278344: sun/security/pkcs12/KeytoolOpensslInteropTest.java test fails because of different openssl output

2021-12-10 Thread Matthias Baesken
On Fri, 10 Dec 2021 12:01:11 GMT, Martin Doerr wrote: > LGTM. Hi Martin, thanks for the review. - PR: https://git.openjdk.java.net/jdk/pull/6779

Re: [jdk17] RFR: 8270556: Exclude security/infra/java/security/cert/CertPathValidator/certification/LetsEncryptCA

2021-07-15 Thread Matthias Baesken
On Thu, 15 Jul 2021 15:04:04 GMT, Christoph Langer wrote: > The test is failing since 8th of July. Let's exclude it for now. Marked as reviewed by mbaesken (Reviewer). - PR: https://git.openjdk.java.net/jdk17/pull/251

Re: RFR: 8263069: Exclude some failing tests from security/infra/java/security/cert/CertPathValidator

2021-03-10 Thread Matthias Baesken
On Fri, 5 Mar 2021 08:38:54 GMT, Christoph Langer wrote: > Exclude some failing tests from > security/infra/java/security/cert/CertPathValidator Looks good, thanks! - Marked as reviewed by mbaesken (Reviewer). PR: https://git.openjdk.java.net/jdk/pull/2840

Integrated: JDK-8261791: (sctp) handleSendFailed in SctpChannelImpl.c potential leaks

2021-02-17 Thread Matthias Baesken
On Tue, 16 Feb 2021 12:26:54 GMT, Matthias Baesken wrote: > In another bug this question from me was answered by Alan Bateman : > > Btw. while adjusting Java_sun_nio_ch_sctp_SctpChannelImpl_receive0 , I > started to wonder what happens to the allocated memory in t

Re: RFR: JDK-8261791: (sctp) handleSendFailed in SctpChannelImpl.c potential leaks

2021-02-17 Thread Matthias Baesken
On Wed, 17 Feb 2021 13:43:14 GMT, Daniel Fuchs wrote: > As pointed out by Alan: It seems like a space is missing after the colon in > the PR title lets give it a try. Thanks ! - PR: https://git.openjdk.java.net/jdk/pull/2586

Re: RFR: JDK-8261791: (sctp) handleSendFailed in SctpChannelImpl.c potential leaks

2021-02-17 Thread Matthias Baesken
On Wed, 17 Feb 2021 13:36:17 GMT, Alan Bateman wrote: > Here's the jcheck failure: > https://github.com/openjdk/jdk/pull/2586/checks?check_run_id=1918880270 Hi Alan , I am aware of the jcheck message. It claims : "The commit message does not reference any issue. " I adjusted now the for the 3

Re: RFR: JDK-8261791:(sctp) handleSendFailed in SctpChannelImpl.c potential leaks

2021-02-17 Thread Matthias Baesken
On Wed, 17 Feb 2021 13:19:13 GMT, Matthias Baesken wrote: >> The changes looks okay to me. I see Chris has created JDK-8261881 to setup >> the cleanup. > > Hi Alan and Chris, thanks for the reviews. Looks like I cannot integrate it, even after changing the tit

Re: RFR: JDK-8261791:(sctp) handleSendFailed in SctpChannelImpl.c potential leaks

2021-02-17 Thread Matthias Baesken
On Wed, 17 Feb 2021 12:51:06 GMT, Alan Bateman wrote: >> In another bug this question from me was answered by Alan Bateman : >> >> Btw. while adjusting Java_sun_nio_ch_sctp_SctpChannelImpl_receive0 , I >> started to wonder what happens to the allocated memory in the same file in >>

RFR: JDK-8261791: handleSendFailed in SctpChannelImpl.c potential leaks

2021-02-16 Thread Matthias Baesken
In another bug this question from m was answered by Alan Bateman : Btw. while adjusting Java_sun_nio_ch_sctp_SctpChannelImpl_receive0 , I started to wonder what happens to the allocated memory in the same file in handleSendFailed ( if ((addressP =

Re: RFR: JDK-8261601: free memory in early return in Java_sun_nio_ch_sctp_SctpChannelImpl_receive0

2021-02-16 Thread Matthias Baesken
On Tue, 16 Feb 2021 08:42:42 GMT, Alan Bateman wrote: > I see this has been integrated but the fix is incomplete. Are you planning to > create a follow-on issue for the issues that I pointed out above? Hi Alan, thanks about your comment to my question about handleSendFailed . I opened a

Integrated: JDK-8261601: free memory in early return in Java_sun_nio_ch_sctp_SctpChannelImpl_receive0

2021-02-16 Thread Matthias Baesken
On Fri, 12 Feb 2021 08:50:14 GMT, Matthias Baesken wrote: > There seems to be an early return in > Java_sun_nio_ch_sctp_SctpChannelImpl_receive0 that misses freeing memory. > > Sonar reports : > https://sonarcloud.io/project/issues?id=shipilev_jdk=c=AXck8Cl0BBG2CXpcnjFu=fa

Re: RFR: JDK-8261601: free memory in early return in Java_sun_nio_ch_sctp_SctpChannelImpl_receive0

2021-02-12 Thread Matthias Baesken
On Fri, 12 Feb 2021 08:50:14 GMT, Matthias Baesken wrote: >Btw. while adjusting Java_sun_nio_ch_sctp_SctpChannelImpl_receive0 , I started >to wonder what happens to the allocated >memory in the same file in >handleSendFailed ( if ((addressP = malloc(dataLength)) == NULL) ) in ea

Re: RFR: JDK-8261601: free memory in early return in Java_sun_nio_ch_sctp_SctpChannelImpl_receive0

2021-02-12 Thread Matthias Baesken
On Fri, 12 Feb 2021 08:50:14 GMT, Matthias Baesken wrote: > There seems to be an early return in > Java_sun_nio_ch_sctp_SctpChannelImpl_receive0 that misses freeing memory. > > Sonar reports : > https://sonarcloud.io/project/issues?id=shipilev_jdk=c=AXck8Cl0BBG2CXpcnjFu=fa

Re: RFR: 8261534: Test sun/security/pkcs11/KeyAgreement/IllegalPackageAccess.java fails on platforms where no nsslib artifacts are defined

2021-02-12 Thread Matthias Baesken
On Wed, 10 Feb 2021 23:29:14 GMT, Christoph Langer wrote: > Fix exception in test > sun/security/pkcs11/KeyAgreement/IllegalPackageAccess.java: > > java.security.AccessControlException: access denied > ("java.security.SecurityPermission" "removeProvider.SUN") > at >

RFR: JDK-8261601: free memory in early return in Java_sun_nio_ch_sctp_SctpChannelImpl_receive0

2021-02-12 Thread Matthias Baesken
There seems to be an early return in Java_sun_nio_ch_sctp_SctpChannelImpl_receive0 that misses freeing memory. Sonar reports : https://sonarcloud.io/project/issues?id=shipilev_jdk=c=AXck8Cl0BBG2CXpcnjFu=false=BLOCKER=BUG Potential leak of memory pointed to by 'newBuf' I adjusted the early

Integrated: JDK-8259786: initialize last parameter of getpwuid_r

2021-01-20 Thread Matthias Baesken
On Fri, 15 Jan 2021 11:24:49 GMT, Matthias Baesken wrote: > We have a couple of calls to getpwuid_r in the codebase, like > g= getpwuid_r(getuid(), , pwd_buf, sizeof(pwd_buf), ); > > Usually we NULL-check pwd after the call because we do not fully trust the > return code

Re: RFR: JDK-8259786: initialize last parameter of getpwuid_r [v4]

2021-01-20 Thread Matthias Baesken
narcloud.io/project/issues?id=jdk=AXaE0dsA8L9hkQskGEbA=false=BUG > > > Aside from this issue , should we in other issue , unify the OS versions of > static char* get_user_name(uid_t uid)in posix code (currently we have it > for bsd, linux, aix but the functions look very similar

Re: RFR: JDK-8259786: initialize last parameter of getpwuid_r [v3]

2021-01-20 Thread Matthias Baesken
narcloud.io/project/issues?id=jdk=AXaE0dsA8L9hkQskGEbA=false=BUG > > > Aside from this issue , should we in other issue , unify the OS versions of > static char* get_user_name(uid_t uid)in posix code (currently we have it > for bsd, linux, aix but the functions look very similar

Re: RFR: JDK-8259786: initialize last parameter of getpwuid_r [v2]

2021-01-20 Thread Matthias Baesken
narcloud.io/project/issues?id=jdk=AXaE0dsA8L9hkQskGEbA=false=BUG > > > Aside from this issue , should we in other issue , unify the OS versions of > static char* get_user_name(uid_t uid)in posix code (currently we have it > for bsd, linux, aix but the functions look very similar

Re: RFR: JDK-8259786: initialize last parameter of getpwuid_r

2021-01-15 Thread Matthias Baesken
On Fri, 15 Jan 2021 13:54:15 GMT, Harold Seigel wrote: >> We have a couple of calls to getpwuid_r in the codebase, like >> g= getpwuid_r(getuid(), , pwd_buf, sizeof(pwd_buf), ); >> >> Usually we NULL-check pwd after the call because we do not fully trust the >> return code of the function

RFR: JDK-8259786: initialize last parameter of getpwuid_r

2021-01-15 Thread Matthias Baesken
We have a couple of calls to getpwuid_r in the codebase, like g= getpwuid_r(getuid(), , pwd_buf, sizeof(pwd_buf), ); Usually we NULL-check pwd after the call because we do not fully trust the return code of the function (it is documented in the codebase why we do not fully trust the return

Re: RFR: 8257997: sun/security/ssl/SSLSocketImpl/SSLSocketLeak.java again reports leaks after JDK-8257884

2020-12-10 Thread Matthias Baesken
On Thu, 10 Dec 2020 08:34:31 GMT, Christoph Langer wrote: > The fix for [JDK-8257884](https://bugs.openjdk.java.net/browse/JDK-8257884) > had a flaw which made the test fail even more often on Windows than before. > Here is the correction. Marked as reviewed by mbaesken (Reviewer).

Re: RFR: 8256202: Some tweaks for jarsigner tests PosixPermissionsTest and SymLinkTest

2020-11-11 Thread Matthias Baesken
On Thu, 12 Nov 2020 06:44:10 GMT, Matthias Baesken wrote: >> Working on 11u backports of JDK-8218021 and JDK-8250968, I found some minor >> points for improvement in tests >> test/jdk/sun/security/tools/jarsigner/PosixPermissionsTest.java and >> test/jdk/sun/

Re: RFR: 8256202: Some tweaks for jarsigner tests PosixPermissionsTest and SymLinkTest

2020-11-11 Thread Matthias Baesken
On Wed, 11 Nov 2020 14:36:07 GMT, Christoph Langer wrote: > Working on 11u backports of JDK-8218021 and JDK-8250968, I found some minor > points for improvement in tests > test/jdk/sun/security/tools/jarsigner/PosixPermissionsTest.java and >