biancini / IdP3-TwoFactor

Apache License 2.0
1 stars 2 forks source link

the plugin is broken? #1

Open splashx opened 7 years ago

splashx commented 7 years ago

The first password authentication part passes, however the next flow (twofactor-authn-flow.xml) fails.

Trackback from main idp process (debug mode):

2016-12-12 08:22:48,737 - ERROR [org.springframework.webflow.execution.ActionExecutionException:76] - 
org.springframework.webflow.execution.ActionExecutionException: Exception thrown executing [AnnotatedAction@3667f1d1 targetAction = [EvaluateAction@3bbfadd4 expression = T(it.reti.integrations.TwoFactorAuthentication).instance(environment.getProperty('twofactor.token', ''), usernamePasswordContext.getUsername()), resultExpression = flowScope.twofactor], attributes = map[[empty]]] in state 'null' of flow 'authn/twofactor' -- action execution attributes were 'map[[empty]]'
    at org.springframework.webflow.execution.ActionExecutor.execute(ActionExecutor.java:60)
Caused by: org.springframework.binding.expression.EvaluationException: An ELException occurred getting the value for expression 'T(it.reti.integrations.TwoFactorAuthentication).instance(environment.getProperty('twofactor.token', ''), usernamePasswordContext.getUsername())' on context [class org.springframework.webflow.engine.impl.RequestControlContextImpl]
    at org.springframework.binding.expression.spel.SpringELExpression.getValue(SpringELExpression.java:92)
Caused by: org.springframework.expression.spel.SpelEvaluationException: EL1011E:(pos 48): Method call: Attempted to call method getUsername() on null context object
    at org.springframework.expression.spel.ast.MethodReference.throwIfNotNullSafe(MethodReference.java:144)

Environment: Ubuntu 16.4 IdP version 3.3.0

biancini commented 7 years ago

Sorry for getting back so late. The problem seems to be present onyl from IdP version 3.3.0. Some of the beans in the authentication flows changed and so the process is no longer able to retrieve username from authentication session. Still looking for a solution, keep you updated when found!