开发者

ios json authentication with rails 3 app

when building a ios app, what's the best way to authen开发者_StackOverflowticate with a rails app through json? i've seen posts about using tokens in the URL and others about using cookies.


I use Authlogic -- Typically I wrote a mobile_signin action which returns the users api_token (created by Authlogic) and then store that on ios. For all future requests you can pass that token to the rails app, and Authlogic understands it and uses it as authentication, of course just as if you were going to use it in the web app, a token is only good for 1 request, so you'd have to send that token with each request, but this is standard procedure.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜