Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ios sdk 8 Symbol _NSURLAuthenticationMethodServerTrust not found #2109

Closed
inso- opened this issue Jun 4, 2014 · 13 comments
Closed

Ios sdk 8 Symbol _NSURLAuthenticationMethodServerTrust not found #2109

inso- opened this issue Jun 4, 2014 · 13 comments

Comments

@inso-
Copy link

@inso- inso- commented Jun 4, 2014

Hy all,
I recently download the new beta version of xcode with iOS 8 sdk,
And i have this problem at runtime:
Symbol not found: _NSURLAuthenticationMethodServerTrust

Do you have an idea ?

@whitebull
Copy link

@whitebull whitebull commented Jun 4, 2014

I'm having the same problem here. Any help or update would be appreciated.

@intuitionspumpe
Copy link

@intuitionspumpe intuitionspumpe commented Jun 5, 2014

I have had this problem also and it seems to be a known bug in the CFNetwork in iOS 8 SDK (look here: https://devforums.apple.com/message/971238#971238).

The work around is as follows:
Change the link order in "Link Binary With Libraries" of your target and put Foundation.framework before CFNetwork.framework.

That solved the issues for me.

@mattt
Copy link
Contributor

@mattt mattt commented Jun 5, 2014

Thanks, @intuitionspumpe.

Just a reminder: CocoaPods is the officially support method of installing AFNetworking.

@mattt mattt closed this Jun 5, 2014
@DigitalLeaves
Copy link

@DigitalLeaves DigitalLeaves commented Jun 9, 2014

Not everybody loves CocoaPods..., thanks intuitionspumpe

@mcfedr
Copy link

@mcfedr mcfedr commented Jun 11, 2014

If you are are using CocoaPods, I needed to add -framework Foundation to OTHER_LDFLAGS in the Pods.xcconfig file, be sure to add it before CFNetwork

@mfentross
Copy link

@mfentross mfentross commented Jun 14, 2014

@mcfedr You rule! Thanks so much!

@haemi
Copy link

@haemi haemi commented Jun 16, 2014

@intuitionspumpe changing the order doesn't work for me: http://cl.ly/image/1R0C0M0x3830

@mattt Do you mean with Cocoapods this issue shouldn't arise? Because I AM using it, but unfortunately get the dyld-error...

@saidler
Copy link

@saidler saidler commented Jun 17, 2014

If @intuitionspumpe suggestion does not work and you are using CocoaPods, do this:

  1. Edit Pods.xcconfig
  2. Under "OTHER_CFLAGS" cut "-framework Foundation" and paste it before "-framework CFNetwork"
  3. Clean and re-build/run

Source: https://devforums.apple.com/message/982272#982272

@ddgromit
Copy link

@ddgromit ddgromit commented Jun 24, 2014

Thanks @mcfedr, adding the foundation framework worked for me!

For anyone interested in the specifics, it was crashing on my 7.0.4 phone (though not on the 8.0 simulator) with:

dyld: Symbol not found: _NSURLAuthenticationMethodServerTrust
  Referenced from: /var/mobile/Applications/6E332AD4-D451-49A5-BB7D-39DA2133EA23/MyApp.app/MyApp
  Expected in: /System/Library/Frameworks/CFNetwork.framework/CFNetwork
 in /var/mobile/Applications/6E332AD4-D451-49A5-BB7D-39DA2133EA23/MyApp.app/MyApp

@wspruijt
Copy link

@wspruijt wspruijt commented Jul 7, 2014

Somehow this happened to me too using the XCode 6.0 beta, but using the 7.1 SDK.

@intuitionspumpe 's solution worked for me:

"Change the link order in "Link Binary With Libraries" of your target and put Foundation.framework before CFNetwork.framework."

@soltrinox
Copy link

@soltrinox soltrinox commented Aug 16, 2014

@intuitionspumpe 's solution worked for me too...

@SeanDunford
Copy link

@SeanDunford SeanDunford commented Sep 1, 2014

@saidler 's solution is the only thing that worked for me and I am using Cocoapods for everything.

@handcraftedcode1
Copy link

@handcraftedcode1 handcraftedcode1 commented Sep 3, 2014

I experienced this on iOS 7 as well. It seems to be Xcode 6 beta. @intuitionspumpe's solution also worked for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet