Comments (3)
I've imported the project manually (without pods), and it works at the moment.
from blueecc.
Exactly same issue here.
from blueecc.
I saw a similar problem with Xcode 12.2 compiling for macOS. Strange thing was, it worked fine in Debug builds, but it crashed with builds for Profiling or Release. Mine is crashing when parsing the PublicKey, but otherwise looks to be the same core problem:
guard let secKey = SecKeyCreateWithData(keyData as CFData,
[kSecAttrKeyType: kSecAttrKeyTypeECSECPrimeRandom,
kSecAttrKeyClass: kSecAttrKeyClassPublic] as CFDictionary,
&error)
This looks like the relevant part of the stack trace:
Application Specific Information:
Fatal error: invalid unsafeDowncast: file /AppleInternal/BuildRoot/Library/Caches/com.apple.xbs/Sources/swiftlang/swiftlang-1103.8.25.8/swift/stdlib/public/core/Builtin.swift, line 235
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libswiftCore.dylib 0x00007fff6bfe21e1 closure #1 in closure #1 in closure #1 in _assertionFailure(_:_:file:line:flags:) + 529
1 libswiftCore.dylib 0x00007fff6bfe1cf7 closure #1 in closure #1 in _assertionFailure(_:_:file:line:flags:) + 87
2 libswiftCore.dylib 0x00007fff6bfe19c3 closure #1 in _assertionFailure(_:_:file:line:flags:) + 99
3 libswiftCore.dylib 0x00007fff6bfe15d5 _assertionFailure(_:_:file:line:flags:) + 533
4 libswiftCore.dylib 0x00007fff6bfe18b0 _fatalErrorMessage(_:_:file:line:flags:) + 32
5 libswiftCore.dylib 0x00007fff6c24d4a3 specialized _NativeDictionary.bridged() + 355
6 libswiftCore.dylib 0x00007fff6c02a06f _NativeDictionary.bridged() + 15
7 co.tinywins.Recut 0x0000000109087a73 specialized ECPublicKey.init(der:) + 1059 (ECPublicKey.swift:144)
8 co.tinywins.Recut 0x0000000109087224 ECPublicKey.__allocating_init(key:) + 836 (ECPublicKey.swift:93)
9 co.tinywins.Recut 0x00000001090d54c2 BlueECVerifier.verify(signature:for:) + 530 (BlueECDSA.swift:99)
10 co.tinywins.Recut 0x00000001090d5281 BlueECVerifier.verify(jwt:) + 577 (BlueECDSA.swift:84)
11 co.tinywins.Recut 0x00000001090d56e0 protocol witness for VerifierAlgorithm.verify(jwt:) in conformance BlueECVerifier + 16
12 co.tinywins.Recut 0x00000001090e5e3b static JWT.verify(_:using:) + 59 (JWT.swift:108)
I don't see the same "One of the two will be used" warning like the OP, but that definitely feels like a build issue. The comment about switching away from pods made me curious, so I switched from installing from a Podfile to using Package.swift, and that fixed the problem!
Maybe it was some kind of library mismatch or something. Hope this helps if anyone else stumbles across the same issue.
from blueecc.
Related Issues (13)
- Add patten matching for error.
- Carthage HOT 1
- secp521r1 signatures based on r|s are sometimes invalid
- Conversion from Data to ASN1 crashes HOT 1
- Integration with NodeJS server
- Swift-JWT fails to compile HOT 1
- Not compiling, OpenSSL linking issue HOT 5
- Cocoapods HOT 1
- [Request] Support for curve 25519 HOT 1
- Customize Algorithm secp256k1
- Use SecKeyCreateRandomKey HOT 2
- Add support for generating keys within the repo HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from blueecc.