facebook-ios-sdk icon indicating copy to clipboard operation
facebook-ios-sdk copied to clipboard

Build error with FBAudienceNetwork.xcframework: Signature cannot be verified

Open WorldDownTown opened this issue 3 months ago • 2 comments

Checklist before submitting a bug report

Xcode version

15.3

Facebook iOS SDK version

6.15.0 (This version is from FBAudienceNetwork.xcframework)

Dependency Manager

Prebuilt Binaries

SDK Framework

Other / I don't know

Goals

I intend to use the FBAudienceNetwork as a mediation partner with the IronSource ad SDK to display ads correctly in my application.

Expected results

To successfully build my app using FBAudienceNetwork.xcframework with Xcode 15.3 without encountering any signature verification issues.

Actual results

When attempting to build the app, the build process fails and terminates with the error "The signature of 'FBAudienceNetwork.xcframework' cannot be verified." Screenshot 2024-04-10 at 17 06 21 Screenshot 2024-04-10 at 17 07 41

Steps to reproduce

I downloaded FBAudienceNetwork.xcframework (6.15.0) from IronSource documentation. https://developers.is.com/ironsource-mobile/ios/mediation-networks-ios/#step-2

However, using the download from "Meta for Developers" did not change the situation. https://developers.facebook.com/docs/audience-network/setting-up/platform-setup/ios/add-sdk

Code samples & details

My Package.swift is like below.


let package = Package(
    name: "Libraries",
    platforms: [
        .iOS(.v15),
    ],
    products: [
        .library(
            name: "Libraries",
            targets: [
                "Libraries",
                "IronSource",
                "ISFacebookAdapter",
                "FBAudienceNetwork",
            ]
        )
    ],
    dependencies: [
        // ...
    ],
    targets: [
        .target(
            name: "Libraries",
            dependencies: [
               // ...
            ]
        ),
        .binaryTarget(name: "IronSource", path: "Binaries/IronSource.xcframework"),
        .binaryTarget(name: "ISFacebookAdapter", path: "Binaries/ISFacebookAdapter.xcframework"),
        .binaryTarget(name: "FBAudienceNetwork", path: "Binaries/FBAudienceNetwork.xcframework"),
    ]
)

I have also found another library that has a very similar issue, which I have attached. https://github.com/onevcat/Kingfisher/issues/2178

WorldDownTown avatar Apr 10 '24 08:04 WorldDownTown

I've the same issue

hhhhht avatar Apr 18 '24 14:04 hhhhht

I found the cause of the signature validation failure. It appears that I manually rewrote the MinimumOsVersion in Info.plist to address issue #2353, which caused the signature verification to fail.

It looks like I can avoid the signature validation error by rewriting the signature with the following command, so that I can handle the error myself without waiting for Facebook to respond. However, I do not know if this response is correct.

codesign --force --timestamp -v --sign "Apple Distribution: MyOrganization (XXXXXXXXXX)" local/path/to/FBAudienceNetwork.xcframework

#2353 is now closed, but FBAudienceNetwork.framework/Info.plist is still not addressed. When will you address the FBAudienceNetwork issue?

WorldDownTown avatar Apr 22 '24 02:04 WorldDownTown