high-hospital-85984
06/29/2021, 9:14 PMorg.eclipse.jetty.jaas.spi.PropertyFileLoginModule
in this case. I'm however running into some errors that I cant figure out. Any tips on how to debug would be appreciated. Logs in thread.high-hospital-85984
06/29/2021, 9:14 PM21:11:47 [application-akka.actor.default-dispatcher-6] WARN application - Authentication error
javax.naming.AuthenticationException: javax.security.auth.login.LoginException: java.lang.NullPointerException
at org.eclipse.jetty.jaas.spi.PropertyFileLoginModule.setupPropertyUserStore(PropertyFileLoginModule.java:78)
at org.eclipse.jetty.jaas.spi.PropertyFileLoginModule.initialize(PropertyFileLoginModule.java:63)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at javax.security.auth.login.LoginContext.invoke(LoginContext.java:736)
at javax.security.auth.login.LoginContext.access$000(LoginContext.java:195)
at javax.security.auth.login.LoginContext$4.run(LoginContext.java:682)
at javax.security.auth.login.LoginContext$4.run(LoginContext.java:680)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
at javax.security.auth.login.LoginContext.login(LoginContext.java:587)
at security.AuthenticationManager.authenticateUser(AuthenticationManager.java:27)
at react.controllers.AuthenticationController.logIn(AuthenticationController.java:108)
at router.Routes$$anonfun$routes$1$$anonfun$applyOrElse$32$$anonfun$apply$32.apply(Routes.scala:1041)
at router.Routes$$anonfun$routes$1$$anonfun$applyOrElse$32$$anonfun$apply$32.apply(Routes.scala:1041)
at play.core.routing.HandlerInvokerFactory$$anon$3.resultCall(HandlerInvoker.scala:134)
at play.core.routing.HandlerInvokerFactory$$anon$3.resultCall(HandlerInvoker.scala:133)
at play.core.routing.HandlerInvokerFactory$JavaActionInvokerFactory$$anon$8$$anon$2$$anon$1.invocation(HandlerInvoker.scala:108)
at play.core.j.JavaAction$$anon$1.call(JavaAction.scala:88)
at play.http.DefaultActionCreator$1.call(DefaultActionCreator.java:31)
at play.core.j.JavaAction$$anonfun$9.apply(JavaAction.scala:138)
at play.core.j.JavaAction$$anonfun$9.apply(JavaAction.scala:138)
at scala.concurrent.impl.Future$PromiseCompletingRunnable.liftedTree1$1(Future.scala:24)
at scala.concurrent.impl.Future$PromiseCompletingRunnable.run(Future.scala:24)
at play.core.j.HttpExecutionContext$$anon$2.run(HttpExecutionContext.scala:56)
at play.api.libs.streams.Execution$trampoline$.execute(Execution.scala:70)
at play.core.j.HttpExecutionContext.execute(HttpExecutionContext.scala:48)
at scala.concurrent.impl.Future$.apply(Future.scala:31)
at scala.concurrent.Future$.apply(Future.scala:494)
at play.core.j.JavaAction.apply(JavaAction.scala:138)
at play.api.mvc.Action$$anonfun$apply$2.apply(Action.scala:96)
at play.api.mvc.Action$$anonfun$apply$2.apply(Action.scala:89)
at scala.concurrent.Future$$anonfun$flatMap$1.apply(Future.scala:253)
at scala.concurrent.Future$$anonfun$flatMap$1.apply(Future.scala:251)
at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:36)
at akka.dispatch.BatchingExecutor$AbstractBatch.processBatch(BatchingExecutor.scala:55)
at akka.dispatch.BatchingExecutor$BlockableBatch$$anonfun$run$1.apply$mcV$sp(BatchingExecutor.scala:91)
at akka.dispatch.BatchingExecutor$BlockableBatch$$anonfun$run$1.apply(BatchingExecutor.scala:91)
at akka.dispatch.BatchingExecutor$BlockableBatch$$anonfun$run$1.apply(BatchingExecutor.scala:91)
at scala.concurrent.BlockContext$.withBlockContext(BlockContext.scala:72)
at akka.dispatch.BatchingExecutor$BlockableBatch.run(BatchingExecutor.scala:90)
at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:40)
at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(ForkJoinExecutorConfigurator.scala:43)
at akka.dispatch.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
at akka.dispatch.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
at akka.dispatch.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
at akka.dispatch.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)
at security.AuthenticationManager.authenticateUser(AuthenticationManager.java:29)
at react.controllers.AuthenticationController.logIn(AuthenticationController.java:108)
at router.Routes$$anonfun$routes$1$$anonfun$applyOrElse$32$$anonfun$apply$32.apply(Routes.scala:1041)
at router.Routes$$anonfun$routes$1$$anonfun$applyOrElse$32$$anonfun$apply$32.apply(Routes.scala:1041)
at play.core.routing.HandlerInvokerFactory$$anon$3.resultCall(HandlerInvoker.scala:134)
at play.core.routing.HandlerInvokerFactory$$anon$3.resultCall(HandlerInvoker.scala:133)
at play.core.routing.HandlerInvokerFactory$JavaActionInvokerFactory$$anon$8$$anon$2$$anon$1.invocation(HandlerInvoker.scala:108)
at play.core.j.JavaAction$$anon$1.call(JavaAction.scala:88)
at play.http.DefaultActionCreator$1.call(DefaultActionCreator.java:31)
at play.core.j.JavaAction$$anonfun$9.apply(JavaAction.scala:138)
at play.core.j.JavaAction$$anonfun$9.apply(JavaAction.scala:138)
at scala.concurrent.impl.Future$PromiseCompletingRunnable.liftedTree1$1(Future.scala:24)
at scala.concurrent.impl.Future$PromiseCompletingRunnable.run(Future.scala:24)
at play.core.j.HttpExecutionContext$$anon$2.run(HttpExecutionContext.scala:56)
at play.api.libs.streams.Execution$trampoline$.execute(Execution.scala:70)
at play.core.j.HttpExecutionContext.execute(HttpExecutionContext.scala:48)
at scala.concurrent.impl.Future$.apply(Future.scala:31)
at scala.concurrent.Future$.apply(Future.scala:494)
at play.core.j.JavaAction.apply(JavaAction.scala:138)
at play.api.mvc.Action$$anonfun$apply$2.apply(Action.scala:96)
at play.api.mvc.Action$$anonfun$apply$2.apply(Action.scala:89)
at scala.concurrent.Future$$anonfun$flatMap$1.apply(Future.scala:253)
at scala.concurrent.Future$$anonfun$flatMap$1.apply(Future.scala:251)
at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:36)
at akka.dispatch.BatchingExecutor$AbstractBatch.processBatch(BatchingExecutor.scala:55)
at akka.dispatch.BatchingExecutor$BlockableBatch$$anonfun$run$1.apply$mcV$sp(BatchingExecutor.scala:91)
at akka.dispatch.BatchingExecutor$BlockableBatch$$anonfun$run$1.apply(BatchingExecutor.scala:91)
at akka.dispatch.BatchingExecutor$BlockableBatch$$anonfun$run$1.apply(BatchingExecutor.scala:91)
at scala.concurrent.BlockContext$.withBlockContext(BlockContext.scala:72)
at akka.dispatch.BatchingExecutor$BlockableBatch.run(BatchingExecutor.scala:90)
at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:40)
at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(ForkJoinExecutorConfigurator.scala:43)
at akka.dispatch.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
at akka.dispatch.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
at akka.dispatch.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
at akka.dispatch.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)
high-hospital-85984
06/29/2021, 9:14 PMjaas.conf
WHZ-Authentication {
org.eclipse.jetty.jaas.spi.PropertyFileLoginModule sufficient
debug="true"
file="/datahub-frontend/conf/user.props";
};
high-hospital-85984
06/29/2021, 9:15 PMuser.props
is simply
datahub:dataub
high-hospital-85984
06/29/2021, 9:16 PMuser.props
file is available in the container.big-carpet-38439
06/29/2021, 9:56 PMbig-carpet-38439
06/29/2021, 9:56 PMbig-carpet-38439
06/29/2021, 9:57 PMfile="/datahub-frontend/conf/user.props"
?big-carpet-38439
06/29/2021, 9:57 PMbig-carpet-38439
06/29/2021, 9:57 PMbig-carpet-38439
06/29/2021, 9:58 PMdocker exec --privileged <container-id> ls -l /datahub-frontend/conf/
if you're using docker directlybig-carpet-38439
06/30/2021, 3:28 PMhigh-hospital-85984
06/30/2021, 6:00 PMJAASLoginService.INSTANCE.get()
returns null. If I'm reading the code of the JAASLoginService
correctly, it's login
function should be called first to initialize the INSTANCE
-attribute, leading me to believe that this particular LoginModule is not compatible as is with Datahub's AuthenticationManager
. Thoughts?big-carpet-38439
06/30/2021, 7:03 PMbig-carpet-38439
07/01/2021, 5:14 PMbig-carpet-38439
07/01/2021, 5:42 PM'jettyJaas': 'org.eclipse.jetty:jetty-jaas:9.4.28.v20200408',
to the root build.gradle and then
play externalDependency.jettyJaas
to the play.gradle
dependenciesbig-carpet-38439
07/01/2021, 5:42 PMhigh-hospital-85984
07/01/2021, 6:13 PM'jettyJaas':Â 'org.eclipse.jetty:jetty-jaas:9.4.42.v20210604'
, but good if you got it working. I'll try again with the older versionhigh-hospital-85984
07/01/2021, 6:30 PMhigh-hospital-85984
07/01/2021, 6:39 PMbig-carpet-38439
07/01/2021, 9:11 PM