approval page defaults to "ask again" when prompt=consent is passed, closes #669

pull/730/head
Justin Richer 10 years ago
parent 775b77b367
commit b14dfa6458

@ -208,7 +208,7 @@
<fieldset style="text-align: left" class="well"> <fieldset style="text-align: left" class="well">
<legend style="margin-bottom: 0;">Remember this decision:</legend> <legend style="margin-bottom: 0;">Remember this decision:</legend>
<label for="remember-forever" class="radio"> <label for="remember-forever" class="radio">
<input type="radio" name="remember" id="remember-forever" value="until-revoked" checked="checked"> <input type="radio" name="remember" id="remember-forever" value="until-revoked" ${ !consent ? 'checked="checked"' : '' }>
remember this decision until I revoke it remember this decision until I revoke it
</label> </label>
<label for="remember-hour" class="radio"> <label for="remember-hour" class="radio">
@ -216,7 +216,7 @@
remember this decision for one hour remember this decision for one hour
</label> </label>
<label for="remember-not" class="radio"> <label for="remember-not" class="radio">
<input type="radio" name="remember" id="remember-not" value="none"> <input type="radio" name="remember" id="remember-not" value="none" ${ consent ? 'checked="checked"' : '' }>
prompt me again next time prompt me again next time
</label> </label>
</fieldset> </fieldset>

@ -102,6 +102,10 @@ public class OAuthConfirmationController {
model.put("code", HttpStatus.FORBIDDEN); model.put("code", HttpStatus.FORBIDDEN);
return HttpCodeView.VIEWNAME; return HttpCodeView.VIEWNAME;
} }
if (prompts.contains("consent")) {
model.put("consent", true);
}
//AuthorizationRequest clientAuth = (AuthorizationRequest) model.remove("authorizationRequest"); //AuthorizationRequest clientAuth = (AuthorizationRequest) model.remove("authorizationRequest");

Loading…
Cancel
Save