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

error: 'SecCertificateCopyPublicKey' is only available on iOS 10.3 or newer #64

Closed
kiroskirin opened this issue Jun 26, 2019 · 3 comments
Assignees
Milestone

Comments

@kiroskirin
Copy link

I folk this repo and try to make it support Carthage but when I run the build. There is an error like this

Swift-JWT/.build/checkouts/BlueRSA/Sources/CryptorRSA/CryptorRSAKey.swift:338:15: error: 'SecCertificateCopyPublicKey' is only available on iOS 10.3 or newer

let key = SecCertificateCopyPublicKey(certData)
@Andrew-Lees11
Copy link
Contributor

Hello @kiroskirin

There seems to be a mistake in BlueRSA.
At CryptorRSAKey.swift#L32 it has:

@available(macOS 10.12, iOS 10.0, *)

Which should be:

@available(macOS 10.12, iOS 10.3, *)

This might also be the case for other @available methods.
I will look into this and raise a PR against BlueRSA

@Andrew-Lees11
Copy link
Contributor

@kiroskirin
I have raised pr #67 that should update all the @available lines so that the project compiles on iOS, watchOS and tvOS. Would you be able to test the available branch to see if this solves your issue?

@Andrew-Lees11
Copy link
Contributor

Closing since this should be fixed in the 3.5.1 release

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

No branches or pull requests

3 participants