Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Works with Rails API? #69

Open
roccogalluzzo opened this issue Oct 10, 2016 · 2 comments
Open

Works with Rails API? #69

roccogalluzzo opened this issue Oct 10, 2016 · 2 comments
Labels

Comments

@roccogalluzzo
Copy link

Hi,

Someone is using this gem with Rails API? it's possibile to return 403 instead of a redirect to cas login page if not logged in?

@adamcrown
Copy link
Collaborator

I wouldn't really recommend CAS for APIs. I'd think you'd be much better off with oAuth or JWTs or something like that. CAS is really designed around a browser and user interaction as you've seen with the redirects and other components of the spec.

@roccogalluzzo
Copy link
Author

Hi @adamcrown,

Yes, you right but I haven't mentioning the context: the API is used by a Single Page Application, so I only need to handle the redirect with javascript. Now I'm playing with ignore 401, I will update the issue if I find something that works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants