Layer7 API Management

 View Only
  • 1.  Error IOS SDK - network host is not currently reachable

    Posted May 14, 2018 08:58 AM

    Using #IOS SDK  #MASAuthentiation #demo (GitHub - CAAPIM/Sample-App-MAS-iOS-Login-User-Authentication-And-Authorization ). Any ideas why I might be getting the error following error on login, invoking api:

     

    Error Domain=com.ca.MASFoundation.localError:ErrorDomain Code=-1003 "The network host is not currently reachable" UserInfo={NSLocalizedDescription=The network host is not currently reachable, status-code=0}

     

    I've set the Capabilities to enable Keychain sharing, and all groups are valid with come.companyName.MASAuthentiation and com.companyName.singleSignOn

     

     



  • 2.  Re: Error IOS SDK - network host is not currently reachable

    Broadcom Employee
    Posted May 14, 2018 07:39 PM

    Is it a simulator or physical device? What's the DNS setting -- can the hostname be resolved?

    Code=-2003 is a HostnameNotFound error



  • 3.  Re: Error IOS SDK - network host is not currently reachable

    Posted May 15, 2018 03:55 AM

    It is a simulator, the hostname can be resolved on my machine.



  • 4.  Re: Error IOS SDK - network host is not currently reachable

    Posted May 24, 2018 06:44 PM

    Hi,

     

    I would need few more information to help you with this problem.

    Can you try to resolve your hostname on the simulator's Safari browser?

     

    Also, make sure all of the server information on msso_config.jso (such as port, host name, and prefix, etc.) are correct.

     

    The network reachability error purely means that the host that you are trying to reach cannot be resolved from the device (simulator) that you are trying.

     

    Please let me know.

     

    Thanks,



  • 5.  Re: Error IOS SDK - network host is not currently reachable
    Best Answer

    Posted May 31, 2018 04:47 AM

    Hi, I solved it in the end. It was an update to xcode that fixed it.



  • 6.  Re: Error IOS SDK - network host is not currently reachable

    Posted May 31, 2018 10:58 AM

    Good to hear that the issue is resolved.

    Thanks for posting the discussion, and sharing the resolution.

     

    Thanks,



  • 7.  Re: Error IOS SDK - network host is not currently reachable

    Broadcom Employee
    Posted May 31, 2018 08:40 PM

    Then, I believe you're using /etc/hosts to resolve the hostname