Skip to content

Commit

Permalink
fix: break endless login loop with too short max_age values
Browse files Browse the repository at this point in the history
  • Loading branch information
panva committed Jun 19, 2019
1 parent 9fd3fba commit 66c7968
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/helpers/interaction/prompts/login/max_age.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = new Check('max_age', 'End-User authentication could not be obta
return true;
}

if (oidc.session.past(oidc.params.max_age)) {
if (oidc.session.past(oidc.params.max_age) && (!ctx.oidc.result || !ctx.oidc.result.login)) {
return true;
}

Expand Down

0 comments on commit 66c7968

Please sign in to comment.