c# - Login to a Remote Service (ruby based) from iPhone -


OK, my problem is in short, I've built a web service from Ruby on Rails. Using restful_authentication, but I'm also building an iPhone application to access my web service, but I can not understand it. I was thinking that anyone could help me to get a place to start.

Are you asking the iphone side or rail side?

For the rail, I think that you should use the basic authentication features of the privileges so that you can take the password of the user and authorize your request, or follow this article: An API key

  def login_from_api_key self.current_user = User.find_by_api_key (params [: api_key]) until params [: api_key] .empty? End defer_user @current_user || = (Login_from_session || login_from_api_key || login_from_basic_auth || login_from_cookie) Unless @current_user == wrong end  

iPhone side is simple if you use api_key; Simply add it to your html headers and you will love to go.


Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -