I have an HTTPS
WebService that need to be accessed from a Mobile (iPhone) application. both are developed by our-side.
We need to secure the Mobile access to this Service. So we used a username/password credentials.
We are aware of OAuth, but we need a more simple authentication scheme.
What We think of is the following:
The Mobile App shows a Login-form to the User/Resource Owner.
The Resource Owner enter The login credentials on behave of the Mobile App.
The Mobile app connect to the Server at special WS Method (e.g. "ValidateLogin") that takes username/password -probably hashed- as input and returns the
HTTP Session Id
.The Mobile app persists this
HTTP Session Id
-which is a unique key from server side, and may be secure?- to communicate with the Server for subsequent requests (Invoking business methods).If the Client doesn't communicate with the Server for say 30 Min, the Server will send 403/Session_time_out (The Mobile may remove the persisted
HTTP Session Id
to indicate to himself that he no longer has access to the Server resources - and It may opt to do so in case if it needs to end the communication with the Server)In this case, the Mobile will need to use the Resource Owner again to obtain a new session id from the Server and gain access to the Server resources.
The Questions are:
- Does the above steps are good enough to depend on?
- What do you think from security perspective?
- Do you have any other thoughts/opinions?
EDIT
: It is a HTTPS WebService