[
https://issues.apache.org/jira/browse/ARTEMIS-5587?focusedWorklogId=976242&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-976242
]
ASF GitHub Bot logged work on ARTEMIS-5587:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 25/Jul/25 11:02
Start Date: 25/Jul/25 11:02
Worklog Time Spent: 10m
Work Description: grgrzybek opened a new pull request, #5845:
URL: https://github.com/apache/activemq-artemis/pull/5845
(no comment)
Issue Time Tracking
-------------------
Worklog Id: (was: 976242)
Remaining Estimate: 0h
Time Spent: 10m
> HttpServerAuthenticator needs to set correct TCCL
> -------------------------------------------------
>
> Key: ARTEMIS-5587
> URL: https://issues.apache.org/jira/browse/ARTEMIS-5587
> Project: ActiveMQ Artemis
> Issue Type: Bug
> Affects Versions: 2.43.0
> Reporter: Grzegorz Grzybek
> Priority: Major
> Labels: pull-request-available
> Time Spent: 10m
> Remaining Estimate: 0h
>
> When using this configuration in {{etc/artemis.profile}}:
> {noformat}
> -DhttpServerAuthenticator.realm=activemq
> -DhttpServerAuthenticator.requestSubjectAttribute=org.jolokia.jaasSubject
> -javaagent:$HOME/.m2/repository/org/jolokia/jolokia-agent-jvm/2.2.10-SNAPSHOT/jolokia-agent-jvm-2.2.10-SNAPSHOT-javaagent.jar=
> \
>
> authClass=org.apache.activemq.artemis.spi.core.security.jaas.HttpServerAuthenticator,
> \
> port=7778, \
> protocol=http, \
> debug=true, \
> lazy=true
> {noformat}
> I could tell Jolokia to use Artemis' implementation of
> {{com.sun.net.httpserver.Authenticator}}. By default, {{etc/login.conf}} is:
> {noformat}
> activemq {
> org.apache.activemq.artemis.spi.core.security.jaas.PropertiesLoginModule
> required
> debug=false
> reload=true
> org.apache.activemq.jaas.properties.user="artemis-users.properties"
> org.apache.activemq.jaas.properties.role="artemis-roles.properties";
> };
> {noformat}
> The problem is that while Jolokia loads
> {{org.apache.activemq.artemis.spi.core.security.jaas.HttpServerAuthenticator}}
> correctly thanks to its {{ArtemisDetector}}, When {{LoginContext.login()}}
> is invoked, it's the TCCL that is tried to load actual login module (here:
> {{org.apache.activemq.artemis.spi.core.security.jaas.PropertiesLoginModule}}).
> Currently TCCL is set to app class loader.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact