You need to sign in to do that
Don't have an account?
IOS not getting to OAuth throwing error
I made a test hybrid remote app that I could then modify to do what is needed for a quick proof of concept. However, when I run the test, I immediately get an error as OAuth never loads in the first place. Any pointing in the right direction would be awesome. Was following the documntation. Error log follows:
2013-09-24 10:28:25.159 Test[39858:c07] userLogoutSettingEnabled: 0
2013-09-24 10:28:25.191 Test[39858:c07] Multi-tasking -> Device: YES, App: YES
2013-09-24 10:28:25:224 Test[39858:c07] DEBUG|SFAuthenticationManager|No authentication in progress. Initiating new authentication request.
2013-09-24 10:28:25.349 Test[39858:c07] SFOAuthCredentials:tokenForKey: (-25300) no existing "com.salesforce.oauth.refresh" item matching "{
acct = "Test-Default-login.salesforce.com";
class = genp;
"m_Limit" = "m_LimitOne";
"r_Attributes" = 1;
svce = "com.salesforce.oauth.refresh";
}"
2013-09-24 10:28:25.349 Test[39858:c07] SFOAuthCoordinator:authenticate: authenticating as 3MVG9Iu66FKeHhINkB1l7xt7kR8czFcCTUhgoA8Ol2Ltf1eYHOU4SqQRSEitYFDUpqRWcoQ2.dBv_a1Dyu5xa without refresh token on 'https://login.salesforce.com' ...
2013-09-24 10:28:25.351 Test[39858:c07] SFOAuthCredentials:tokenForKey: (-25300) no existing "com.salesforce.oauth.refresh" item matching "{
acct = "Test-Default-login.salesforce.com";
class = genp;
"m_Limit" = "m_LimitOne";
"r_Attributes" = 1;
svce = "com.salesforce.oauth.refresh";
}"
2013-09-24 10:28:25:354 Test[39858:c07] DEBUG|SFAuthenticationManager|oauthCoordinator:willBeginAuthenticationWithView
2013-09-24 10:28:25.355 Test[39858:c07] SFOAuthCredentials:tokenForKey: (-25300) no existing "com.salesforce.oauth.activation" item matching "{
acct = "Test-Default-login.salesforce.com";
class = genp;
"m_Limit" = "m_LimitOne";
"r_Attributes" = 1;
svce = "com.salesforce.oauth.activation";
}"
2013-09-24 10:28:25.355 Test[39858:c07] SFOAuthCoordinator:beginUserAgentFlow with https://login.salesforce.com/services/oauth2/authorize?client_id=3MVG9Iu66FKeHhINkB1l7xt7kR8czFcCTUhgoA8Ol2Ltf1eYHOU4SqQRSEitYFDUpqRWcoQ2.dBv_a1Dyu5xa&redirect_uri=https://test.salesforce.com/ services/oauth2/callback&display=touch&response_type=token&scope=refresh_token%20web%20api
2013-09-24 10:28:25.373 Test[39858:c07] SFOAuthCoordinator:webView:shouldStartLoadWithRequest: (navType=5): host=(null) : path=(null)
2013-09-24 10:28:25.375 Test[39858:c07] SFOAuthCoordinator:didFailLoadWithError Error Domain=WebKitErrorDomain Code=101 "The operation couldn’t be completed. (WebKitErrorDomain error 101.)" on URL: (null)
2013-09-24 10:28:25:376 Test[39858:c07] DEBUG|SFAuthenticationManager|oauthCoordinator:didFailWithError: Error Domain=WebKitErrorDomain Code=101 "The operation couldn’t be completed. (WebKitErrorDomain error 101.)", authInfo: <SFOAuthInfo: 0x9926520, authType=SFOAuthTypeUserAgent>
I'm assuming you have built this using the hybrid template that ships with the Mobile SDK. If that's the case, can you check the values of
remoteAccessConsumerKey
oauthRedirectURI
oauthScopes
If these are not valid, the oAuth dance will fail.
I hope this helps.
Regards,
Gaurav