users@jersey.java.net
[Jersey] Re: Is it possible to set the Principal in ContainerRequestFilter
This message
: [
Message body
] [ More options (
top
,
bottom
) ]
Related messages
: [
Next message
] [
Previous message
] [
In reply to
] [
Next in thread
] [
Replies
]
Contemporary messages sorted
: [
by date
] [
by thread
] [
by subject
] [
by author
] [
by messages with attachments
]
From
: Jakub Podlesak <
jakub.podlesak_at_oracle.com
>
Date
: Mon, 17 Oct 2011 12:49:50 +0200
Hi Duncan,
You should be able to set the security context in your filter. The user
Principal is than obtained from there. See [1].
You may also want to check the jersey oauth-server module [2],
which does exactly the same thing (setting a custom security context).
HTH,
~Jakub
[1]
http://jersey.java.net/nonav/apidocs/latest/jersey/com/sun/jersey/spi/container/ContainerRequest.html#setSecurityContext%28javax.ws.rs.core.SecurityContext%29
[2]
http://java.net/projects/jersey/sources/svn/content/trunk/jersey/contribs/jersey-oauth/oauth-server/src/main/java/com/sun/jersey/oauth/server/api/OAuthServerFilter.java?rev=5435
On 12.10.2011 14:32, dabloem_at_gmail.com wrote:
> If it's possible, how can I set the Principal after a security check in
> a ContainerRequestFilter?
>
> Thank you,
> Duncan
>
This message
: [
Message body
]
Next message
:
Jakub Podlesak: "[Jersey] Re: jersey how to support or implement Init and Destroy function?"
Previous message
:
Jakub Podlesak: "[Jersey] Re: Remote address in ContainerRequest"
In reply to
:
dabloem_at_gmail.com: "[Jersey] Is it possible to set the Principal in ContainerRequestFilter"
Next in thread
:
Duncan Bloem: "[Jersey] Re: Is it possible to set the Principal in ContainerRequestFilter"
Reply
:
Duncan Bloem: "[Jersey] Re: Is it possible to set the Principal in ContainerRequestFilter"
Contemporary messages sorted
: [
by date
] [
by thread
] [
by subject
] [
by author
] [
by messages with attachments
]