[jboss-jira] [JBoss JIRA] (ELY-1224) TokenSecurityRealm should throw a IllegalStateException when identity can not be mapped

Darran Lofthouse (JIRA) issues at jboss.org
Mon Jun 5 14:16:00 EDT 2017


    [ https://issues.jboss.org/browse/ELY-1224?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13416450#comment-13416450 ] 

Darran Lofthouse commented on ELY-1224:
---------------------------------------

IllegalStateException would cover cases where methods are called at the wrong time, i.e. obtaining an authorization identity before one even exists.

For general validation we may actually want methods to just reject authentication normally and log at TRACE so it can be debugged.

> TokenSecurityRealm should throw a IllegalStateException when identity can not be mapped
> ---------------------------------------------------------------------------------------
>
>                 Key: ELY-1224
>                 URL: https://issues.jboss.org/browse/ELY-1224
>             Project: WildFly Elytron
>          Issue Type: Task
>          Components: Realms
>    Affects Versions: 1.1.0.Beta50
>            Reporter: Pedro Igor
>            Assignee: Pedro Igor
>
> {{TokenSecurityRealm}} is using a {{RealmUnavailableException}} when failing to map the principal name from tokens.
> Need to change this to throw a {{illegalStateException}} instead.



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the jboss-jira mailing list