AzureAD / azure-activedirectory-library-for-objc

The ADAL SDK for Objective C gives you the ability to add support for Work Accounts to your iOS and macOS applications with just a few lines of additional code. This SDK gives your application the full functionality of Microsoft Azure AD, including industry standard protocol support for OAuth2, Web API integration with user level consent, and two factor authentication support.
MIT License
178 stars 113 forks source link

App crashing EXC_CRASH (SIGABRT) #1565

Closed shivR closed 3 years ago

shivR commented 3 years ago

Not able to reproduce the issue internally but seeing many crashes on AppStore. below is the symbolicate crash file. ADAL lib version - 2.6.2

` Hardware Model: iPhone10,6 Process: ------------ Path: /private/var/containers/Bundle/Application/--------- Identifier: ---------------- Version: 3.4.0.11 (3.4.0) AppStoreTools: 12B45a AppVariant: 1:iPhone10,6:13 Code Type: ARM-64 (Native) Role: Foreground Parent Process: launchd [1] Coalition: ----------- [3307]

Date/Time: 2021-01-04 15:54:53.2307 -0700 Launch Time: 2021-01-04 15:54:14.0036 -0700 OS Version: iPhone OS 14.1 (18A8395) Release Type: User Baseband Version: 4.00.00 Report Version: 104

Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000 Exception Note: EXC_CORPSE_NOTIFY Triggered by Thread: 36

Thread 0 name: Thread 0: 0 libsystem_kernel.dylib 0x00000001d23b5734 mkdir + 8 1 ADAL 0x000000010493a95c llvm_profile_recursive_mkdir + 26972 (InstrProfilingUtil.c:58) 2 ADAL 0x0000000104939398 llvm_gcda_start_file + 21400 (GCDAProfiling.c:360) 3 ADAL 0x00000001049934d8 llvm_gcov_writeout + 28 4 libsystem_c.dylib 0x00000001b04e89e0 cxa_finalize_ranges + 388 (atexit.c:286) 5 libsystem_c.dylib 0x00000001b04e8ce4 exit + 24 (exit.c:81) 6 UIKitCore 0x00000001aa0db2e4 -[UIApplication _terminateWithStatus:] + 500 (UIApplication.m:6534) 7 UIKitCore 0x00000001a97b1d9c -[_UISceneLifecycleMultiplexer _evalTransitionToSettings:fromSettings:forceExit:withTransitionStore:] + 124 (_UISceneLifecycleMultiplexer.m:819) 8 UIKitCore 0x00000001a97b1a20 -[_UISceneLifecycleMultiplexer forceExitWithTransitionContext:scene:] + 216 (_UISceneLifecycleMultiplexer.m:457) 9 UIKitCore 0x00000001aa0d1120 -[UIApplication workspaceShouldExit:withTransitionContext:] + 208 (UIApplication.m:3600) 10 FrontBoardServices 0x00000001b6140608 -[FBSUIApplicationWorkspaceShim workspaceShouldExit:withTransitionContext:] + 84 (FBSUIApplicationWorkspace.m:144) 11 FrontBoardServices 0x00000001b616ae14 __63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke_2 + 76 (FBSWorkspaceScenesClient.m:312) 12 FrontBoardServices 0x00000001b6151400 -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:] + 232 (FBSWorkspace.m:355) 13 FrontBoardServices 0x00000001b616adb0 63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke + 104 (FBSWorkspaceScenesClient.m:309) 14 libdispatch.dylib 0x00000001a74c6280 _dispatch_client_callout + 16 (object.m:559) 15 libdispatch.dylib 0x00000001a749f19c _dispatch_block_invoke_direct$VARIANT$armv81 + 216 (queue.c:468) 16 FrontBoardServices 0x00000001b61904a8 FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK + 40 (FBSSerialQueue.m:184) 17 FrontBoardServices 0x00000001b6190170 -[FBSSerialQueue _targetQueue_performNextIfPossible] + 404 (FBSSerialQueue.m:227) 18 FrontBoardServices 0x00000001b6190644 -[FBSSerialQueue _performNextFromRunLoopSource] + 28 (FBSSerialQueue.m:258) 19 CoreFoundation 0x00000001a780d240 CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION + 24 (CFRunLoop.c:1967) 20 CoreFoundation 0x00000001a780d140 CFRunLoopDoSource0 + 204 (CFRunLoop.c:2011) 21 CoreFoundation 0x00000001a780c488 CFRunLoopDoSources0 + 256 (CFRunLoop.c:2048) 22 CoreFoundation 0x00000001a7806a40 CFRunLoopRun + 776 (CFRunLoop.c:2925) 23 CoreFoundation 0x00000001a7806200 CFRunLoopRunSpecific + 572 (CFRunLoop.c:3242) 24 GraphicsServices 0x00000001bd983598 GSEventRunModal + 160 (GSEvent.c:2259) 25 UIKitCore 0x00000001aa0cfbcc -[UIApplication _run] + 1052 (UIApplication.m:3270) 26 UIKitCore 0x00000001aa0d51a0 UIApplicationMain + 164 (UIApplication.m:4739) 27 AppName-appstore 0x0000000102becf60 main + 331616 (main.m:64) 28 libdyld.dylib 0x00000001a74e5588 start + 4 . . . Thread 36 Crashed: 0 libsystem_kernel.dylib 0x00000001d23b395c pthread_kill + 8 1 libsystem_pthread.dylib 0x00000001ed56a9e8 pthread_kill + 212 (pthread.c:1375) 2 libsystem_c.dylib 0x00000001b0507934 abort + 100 (abort.c:110) 3 libc++abi.dylib 0x00000001bb225cc8 abort_message + 128 (abort_message.cpp:76) 4 libc++abi.dylib 0x00000001bb217c88 demangling_terminate_handler() + 272 (cxa_default_handlers.cpp:62) 5 libobjc.A.dylib 0x00000001bb129f74 _objc_terminate() + 140 (objc-exception.mm:704) 6 libc++abi.dylib 0x00000001bb225154 std::terminate(void (*)()) + 16 (cxa_handlers.cpp:59) 7 libc++abi.dylib 0x00000001bb227bec __cxxabiv1::failed_throw(cxxabiv1::cxa_exception*) + 32 (cxa_exception.cpp:153) 8 libc++abi.dylib 0x00000001bb227bac cxa_throw + 132 (cxa_exception.cpp:284) 9 libc++.1.dylib 0x00000001bb1ff418 std::1::throw_system_error(int, char const) + 88 (system_error.cpp:287) 10 libc++.1.dylib 0x00000001bb1f49d0 std::__1::mutex::lock() + 36 (mutex.cpp:35) 11 AppName-appstore 0x0000000103bbbdc8 GT::Device::getDevice+ 16907720 () + 44 12 AppName-appstore 0x0000000103bc0184 GT::SchedulerBase::scheduleImmediately+ 16925060 () + 40 13 AppName-appstore 0x0000000103616c20 GT::Socket::run+ 10988576 () + 1772 14 AppName-appstore 0x0000000103bc1b04 GT::thread_run+ 16931588 (void) + 124 15 libsystem_pthread.dylib 0x00000001ed569b70 _pthread_start + 288 (pthread.c:880) 16 libsystem_pthread.dylib 0x00000001ed56e880 thread_start + 8

`

kaisong1990 commented 3 years ago

@shivR Thanks for your question, looks like the crash happens on thread 36 and no signs of ADAL related. Is it possible to upgrade the ADAL to our latest 4.0.11 or switch to use MSAL.