Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Fix for FLEX-212: Spring Security integration does not work with Data Services NIO endpoints #1

Merged
merged 1 commit into from Oct 31, 2011

Conversation

Projects
None yet
2 participants
Contributor

rokumar commented Oct 27, 2011

FLEX-212: Spring Security integration does not work with Data Services NIO endpoints
It turns out due a change made for FLEX-185, the Security Login Command was changed so that the FlexContext.getHttpRequest() was being used used to set the source on the UserPasswordAuthenticationToken, which results in a silent error when passed a null value or a shell HttpRequest object (as is the case for NIO based endpoints). By ensuring that the code is enclosed in a try/catch block, this can be silently ignored if it happens. When we locally tested the fix, everything works.

@rokumar rokumar FLEX-212: Spring Security integration does not work with Data Service…
…s NIO endpoints

It turns out due a change made for FLEX-185, the Security Login Command was changed so that the FlexContext.getHttpRequest() was being used used to set the source on the UserPasswordAuthenticationToken, which results in a silent error when passed a null value or a shell HttpRequest object (as is the case for NIO based endpoints). By ensuring that the code is enclosed in a try/catch block, this can be silently ignored if it happens. When we locally tested the fix, everything works.
2cac3ae
Contributor

jeremyg484 commented Oct 31, 2011

Rohit,

Looks fine, I'll go ahead and merge it now.

One thing to consider going forward is whether you might want to provide an extended implementation of SpringSecurityLoginCommand in LCDS that sets potentially useful details about the user requesting the authentication. Perhaps a flex client ID instead of a session ID, etc.

Thanks,

Jeremy

@jeremyg484 jeremyg484 added a commit that referenced this pull request Oct 31, 2011

@jeremyg484 jeremyg484 Merge pull request #1 from rokumar/master
Fix for FLEX-212: Spring Security integration does not work with Data Services NIO endpoints
34ece3d

@jeremyg484 jeremyg484 merged commit 34ece3d into spring-projects:master Oct 31, 2011

Contributor

rokumar commented Nov 1, 2011

Thanks Jeremy. Yes, we could possibly consider inject additional NIO channel related info in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment