Authentication Against an OData Source

Hybrid Apps pass user name and password information using HTTP basic authentication, by setting the Authorization HTTP header. 

It is recommended to use this in combination with SSL/TLS, otherwise user names and passwords are passed in cleartext. For example:
var strUsername = "odata";
var strPassword = "password"; 
var oHeaders = {};
oHeaders['Authorization'] = "Basic " + btoa(strUsername + ":" + strPassword); 
var request = { 
       headers : oHeaders, // object that contains HTTP headers as name value pairs 
       requestUri : sUrl, // OData endpoint URI 
       method : "GET"
                
}; 

OData.read( request, function (data, response) { 
                                            
      // do something with the response 
      }, 
      function( err ) { 
      // handle error reading the data 
      }); 
Related concepts
Basic Authentication
Related reference
SSO Token, Including SAP SSO2 and SiteMinder/Network Edge