datatheorem / datatheorem/TrustKit
Crash at [TSKNSURLConnectionDelegateProxy swizzleNSURLConnectionConstructors:] TSKNSURLConnectionDelegateProxy.m:103
Nobody has claimed this yet.
- Dominant language
- Objective-C
- Stars
- 2.1k
- Forks
- 381
- PR merge metrics
- No merged PRs in 30d
Description
Hello guy, we have the next crash:
Exception Type: EXC_CRASH (SIGKILL)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Reason: FRONTBOARD 2343432205
<RBSTerminateContext| domain:10 code:0x8BADF00D explanation:[application<com.myApp>:99955] failed to terminate gracefully after 5.0s
ProcessVisibility: Unknown
ProcessState: Running
WatchdogEvent: process-exit
WatchdogVisibility: Background
WatchdogCPUStatistics: (
"Elapsed total CPU time (seconds): 4.930 (user 3.310, system 1.620), 16% CPU",
"Elapsed application CPU time (seconds): 0.019, 0% CPU"
) reportType:CrashLog maxTerminationResistance:Interactive>
Triggered by Thread: 0
Kernel Triage:
VM - pmap_enter failed with resource shortage
Thread 0 name:
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x00000001f5a8f4dc semaphore_wait_trap + 8 (:-1)
1 libdispatch.dylib 0x00000001bdcc0fcc _dispatch_sema4_wait + 28 (lock.c:139)
2 libdispatch.dylib 0x00000001bdcc1674 _dispatch_semaphore_wait_slow + 132 (semaphore.c:132)
3 CFNetwork 0x00000001be854b88 CFURLConnectionSendSynchronousRequest + 380 (CFURLConnection_Synchronous.c:209)
4 CFNetwork 0x00000001be8ff3f8 +[NSURLConnection sendSynchronousRequest:returningResponse:error:] + 120 (NSURLConnection.mm:480)
5 MyApp 0x000000010541614c __70+[TSKNSURLConnectionDelegateProxy swizzleNSURLConnectionConstructors:]_block_invoke_2.38 + 184 (TSKNSURLConnectionDelegateProxy.m:103)
6 MyApp 0x00000001055b759c __swizzleNSURLConnectionSendSynchronousRequest_block_invoke + 476 (CRNSURLConnectionDelegateProxy.m:556)
7 Foundation 0x00000001bf8615d4 -[NSData(NSData) initWithContentsOfURL:options:maxLength:error:] + 280 (NSData.m:894)
The first crash appeared around one year ago.
Any ideas or help what could be?
Seem like the problem comes from the swizzled code by RSSwizzleClassMethod in TSKNSURLConnectionDelegateProxy.m:103
https://github.com/datatheorem/TrustKit/blob/0617d99b534de6adb632ada2475ca8c20c644736/TrustKit/Swizzling/TSKNSURLConnectionDelegateProxy.m#L102-L113
Does anyone have the same crash?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading TrustKit/Swizzling/TSKNSURLConnectionDelegateProxy.m around swizzleNSURLConnectionConstructors:, especially line 103, and compare it with the reported call stack. Investigate the interaction with the synchronous NSURLConnection request and the watchdog termination. Done means identifying a reproducible cause and documenting or validating a fix; the issue names no test or reproduction steps.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, objective-c
- Domain
- mobile-dev, security
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100