That
is interesting. Here’s a symbolicated backtrace of the exception:
Code Block | 13 Foundation … -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] |
| 14 CryptoTokenKit … -[TKClientTokenSession withError:accessControl:invoke:] + 540 |
| 15 CryptoTokenKit … -[TKClientTokenObject operation:data:algorithms:parameters:error:] + 264 |
| 16 Security … TKTokenCopyOperationResult + 604 |
| 17 Security … __SecCTKKeyCopyOperationResult_block_invoke + 452 |
| 18 Security … SecItemAuthDo + 124 |
| 19 Security … SecCTKKeyCopyOperationResult + 380 |
| 20 Security … SecKeyRunAlgorithmAndCopyResult + 248 |
| 21 Security … SecKeyCreateSignature + 104 |
| 22 Security … SecKeyPerformLegacyOperation + 172 |
| 23 Security … SecKeyRawSign + 132 |
| 24 tztHuaTaiZLMobile … -[gmrz_jv_ecc_cal_ext useKeyAsyncSign:serviceId:username:digestData:digestLeng… |
In frame 24 your app has called
SecKeyRawSign. Frames 23 through 17 are that call wending its way through the Security framework. In frame 16 it calls into CryptoTokenKit, because the key is stored on a secure token. Presumably this is the Secure Enclave, which is handled internally as a CryptoTokenKit token. Anyway, frames 15 and 14 are CryptoTokenKit and there’s where the
Unexpected sessionID mismatch exception is coming from.
I don’t have a good idea as to why this is happening. How frequently does this happen? Is this crash report coming in from users in the field? Can you reproduce it yourself?
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"