Info.plist에서 iOS 9“fbauth2”가 누락되었습니다
FBSDKLog: fbauth2 is missing from your Info.plist under LSApplicationQueriesSchemes and is required for iOS 9.0
이것이 무엇인지 아십니까? plist에 추가했지만 작동하지 않았습니다.
iOS 9 용 앱을 빌드 할 때 URL 스킴을 계속 사용할 수 있으며 URL 스킴을 호출하려면 앱 Info.plist에서이를 선언해야합니다. LSApplicationQueriesSchemes 라는 새로운 키가 있으며 여기 에서 canOpenURL 을 사용하려는 구성표 목록을 추가해야합니다.
<key>LSApplicationQueriesSchemes</key>
<array>
<string>fbauth2</string>
</array>
iOS9를 사용하는 경우 info.plist 파일을 업데이트하는 것이 중요합니다. 3 단계 만 수행하면됩니다. info.plist로 이동하십시오. 2. LSApplicationQueriesSchemes NSArray 데이터 유형 필드를 추가하십시오 . 3. NSString 데이터 유형의 항목을 fbauth2로 추가하십시오.
그게 다야. 청소하고 실행하십시오. 경고가 다시 표시되지 않습니다.
FaceBook SDK v4.6.0과 관련하여 plist 파일에 다음 키를 추가하십시오.
<key>LSApplicationQueriesSchemes</key>
<array>
<string>fbapi</string>
<string>fb-messenger-api</string>
<string>fbauth2</string>
<string>fbshareextension</string>
</array>
링크 : https://developers.facebook.com/docs/ios/ios9
Facebook 설명을 따르기 만하면됩니다 : iOS9를위한 앱 준비하기
Apple에서 언급 한 내용 : 개인 정보 및 앱 Keynote 2015
CFBundleURLSchemes에 이것을 추가하지 마십시오 ... 실제로 Facebook 인증에서 앱의 시도를 HIJACK하여 팝업에 "X app want to open"대화 상자가 표시됩니다.
당신은 그렇게하고 싶지 않습니다.
cf :
https://developers.facebook.com/docs/applinks/ios
https://www.fireeye.com/blog/threat-research/2015/04/url_masques_on_apps.html
https://www.reddit.com/r/workflow/comments/2tlx29/get_url_scheme_of_any_app
테스트 대상이 기본 번들에 액세스 할 수 없으므로 키위 테스트를 실행할 때 이것을 얻었습니다. 그래서에 조건을 추가해야 isRegisteredCanOpenURLScheme
했습니다.FBSDKInternalUtility.m
+ (BOOL)isRegisteredCanOpenURLScheme:(NSString *)urlScheme
{
static dispatch_once_t fetchBundleOnce;
static NSArray *schemes = nil;
dispatch_once(&fetchBundleOnce, ^{
schemes = [[[NSBundle mainBundle] infoDictionary] valueForKey:@"LSApplicationQueriesSchemes"];
if (!schemes) { // This is a work around for our Kiwi tests as the Specs target doesn't have access to main bundle
NSBundle *bundle = [NSBundle bundleForClass:[self class]];
NSString *path = [bundle pathForResource:@"Info" ofType:@"plist"];
NSDictionary *dictionary = [NSDictionary dictionaryWithContentsOfFile:path];
schemes = [dictionary valueForKey:@"LSApplicationQueriesSchemes"];
}
});
return [schemes containsObject:urlScheme];
}
iOS 9 용 앱을 빌드하려면 : (Facebook Share)
- 열기
Info.plist
파일, 다른 필드 추가 LSApplicationQueriesSchemes을 아래에 정보 속성 목록 과의 데이터 유형을 설정Array
하거나NSArray
. - LSApplicationQueriesSchemes에 3 개의 항목 을 추가 하고 해당 데이터 유형을 또는로 설정하십시오 .
String
NSString
- 할당
fbauth2
,fbshareextension
,fbapi
항목 값으로.
이 사진을 따르십시오 :
Write the below code in your info.plist under the **LSApplicationQueriesScheme**
<string>fbapi</string>
<string>fbapi20130214</string>
<string>fbapi20130410</string>
<string>fbapi20130702</string>
<string>fbapi20131010</string>
<string>fbapi20131219</string>
<string>fbapi20140410</string>
<string>fbapi20140116</string>
<string>fbapi20150313</string>
<string>fbapi20150629</string>
<string>fbauth</string>
<string>fbauth2</string>
<string>fb-messenger-api20140430</string>
<string>fb-messenger-platform-20150128</string>
<string>fb-messenger-platform-20150218</string>
<string>fb-messenger-platform-20150305</string>
참고 URL : https://stackoverflow.com/questions/32006033/ios-9-fbauth2-missing-from-info-plist
'Programing' 카테고리의 다른 글
소문자를 대문자로 또는 그 반대로 변환하는 ^ = 32의 아이디어는 무엇입니까? (0) | 2020.06.14 |
---|---|
효율적으로 입력 스트림에서 Android 읽기 (0) | 2020.06.14 |
bash 스크립트에서 소스를 사용할 때 '소스 : 찾을 수 없음'오류 표시 (0) | 2020.06.14 |
왜 Git이 지정된 파일을 무시하지 않습니까? (0) | 2020.06.14 |
Mac OS X에서 zsh를 로그인 쉘로 실행하는 방법 (iTerm)? (0) | 2020.06.14 |