Crashlytics - Do we need to pay for commercial app analysis - ios

Question #1:
I am using Crashlytics for one of my commercial iOS Apps. Their service seems very helpful. I wonder if there is any Legal issue of using their services for commercial apps? Is there any limitations for using Crashlytics?
Question #2:
I need to upload .dsym file in their server to get crashlogs symbolicated. Is there any privacy issue. Is it possible to get my code (or any info) back by reverse engineering when they have .dsym file.
Question #3
Sometime some crashes are not showing in the crashlytics dashboard. Is it necessary to be online when crash happens to get crashlog in dashboard? Don't Crashlytics keep logs trace when offline and send logs back to the server when device become online? Any idea how they work?

Mike from Fabric here, but I'm not a lawyer.
1) Fabric and Crashlytics is used in many commercial apps, including our own. There aren't limitations to using Fabric. You can find the Fabric terms of service here.
2) The dSYM is what let's us or any other crash reporter symbolicate the crash report as it contains the symbols that map back to your app's source. None of your source code is uploaded. From Apple's own documentation:
As the compiler translates your source code into machine code, it also
generates debug symbols which map each machine instruction in the
compiled binary back to the line of source code from which it
originated. Depending on the Debug Information Format
(DEBUG_INFORMATION_FORMAT) build setting, these debug symbols are
stored inside the binary or in a companion Debug Symbol (dSYM) file.
The Debug Symbol file and application binary are tied together on a
per-build-basis by the build UUID. A new UUID is generated for each
build of your application and uniquely identifies that build. Even if
a functionally-identical executable is rebuilt from the same source
code, with the same compiler settings, it will have a different build
UUID.
3) Crashes are caught regardless if the app is connected to a network or not. However, crashes are only sent on relaunch of the app and would then be processed.
One thing to note is that if you're testing in the Simulator or with your device connected to Xcode will cause Xcode's debugger to capture the crash instead of us.
Further, if the dSYM hasn't been uploaded, then we're unable to process the crash report and we'll alert you in the Crashlytics dashboard of the missing dSYMs so that you can upload them.

Related

How to get crash logs on IOS SDK Development using Sentry

I develop an IOS SDK, which developers can implement it to their apps as a framework.
I’m currently using Sentry as crash analysis tool, and the related DSYM file (produced from my SDK project) is automatically uploaded to Sentry on every build.
But the problem is when someone’s app crashes due to an error on the SDK I’m developing, Sentry returns partially symbolicated crash logs that I can barely understand what has happened and where the crash has occurred.
Is there a way that I can get the fully symbolicated crash logs, without changing the app’s project settings and without uploading anything (app’s DSYM etc.) from the original app. (Since I don’t have the app, I’m only producing the SDK)
My project has the following build settings:
Strip Debug Symbols During Copy: No
Strip Style: Debugging Symbols
Strip Linked Product: No
I was sending the DSYM's to a wrong project. I set 'export SENTRY_PROJECT=proper_project_name' then the issue has resolved.
Here is the link of the issue;
https://github.com/getsentry/sentry-cocoa/issues/277

How do I view crash reason in iTunes Connect?

Is there any way to get crash information in iTunes Connect? I notice under App Analytics it displays the number of "Opt-in Only Crashes". I press the number under it (in my case 2). This takes me to a page that only seems to show the days that the crash happened. Is there any way I can see useful crash information, for example line of code, etc.?
To see where is the problem just open your Xcode > Window > Organizer > Crashes from your Application.
You already deployed your app on App Store (or as an Ad Hoc or Enterprise build) then you won't be able to attach Xcode's debugger to deployed app for debugging. To debug problems, you need to analyze Crash Logs and Console output from the device. To read crash reports with backtraces its need to be symbolicated before they can be analyzed. Symbolication is a process which replaces memory addresses with human-readable function names and line numbers.
To understanding and Analyzing Application Crash Reports you can refer Symbolicating Crash Reports, Debugging Deployed iOS Apps or Analyzing Crash Reports.
Overview of the crash reporting and symbolication process.
Set Debug Information Format (DEBUG_INFORMATION_FORMAT) in build settings these debug symbols are stored inside the binary or in a companion Debug Symbol (dSYM) file.
When you archive the application for distribution, Xcode will gather the application binary along with the .dSYM file and store them at a location inside your home folder.
At the time of deploying on the App Store or a beta test using Test Flight, include the dSYM file when uploading your archive to iTunes Connect.
When your application crashes, an unsymbolicated crash report is created and stored on the device.
You can retrieve crash reports directly from their device by following the steps in Debugging Deployed iOS Apps. If you have distributed your application via AdHoc or Enterprise distribution, this is the only way to acquire crash reports from your users.
Crash reports retrieved from a device are unsymbolicated and will need to be symbolicated using Xcode. Xcode uses the dSYM file associated with your application binary to replace each address in the backtrace with its originating location in your source code. The result is a symbolicated crash report.
If the user has opted to share diagnostic data with Apple, or if the user has installed a beta version of your application through TestFlight, the crash report is uploaded to the App Store.
The App Store symbolicates the crash report and groups it with similar crash reports. This aggregate of similar crash reports is called a Crash Point.
The symbolicated crash reports are made available to you in Xcode's Crashes organizer.
Yes, You can view those crashes in Xcode. This can found in apple docs in Analyzing crash reports

Firebase crash console asking for UUID of a build that does not exist

I am trying to get crash reports working on my ios app. I am getting an error message in the Firebase Crash dashboard that says
Upload symbol file to symbolicate future stack traces for UUID 69696969-7F8H-567E-1ABCD-FAKEID123
I have checked every binary on my machine, and not a single one of them has this UUID. So where is this UUID coming from? I put a fake one in the example above obviously, but how can Firebase be asking for this UUID if it doesn't exist?
Note that this is a test crash. I am calling
FIRCrashMessage("Hey man, you crashed.")
fatalError()
in my app. The build is one I've downloaded from iTunes connect via TestFlight. Is Apple creating a binary that I don't have a dSYM file for? I have bitcode disabled.
I also verified that the run script is working. If I click "Symbol Files", to the right of "Dashboard" on the Firebase Crash Reporting tab I have lots of dSYM files uploaded to the Firebase Crash service, but none match the UUID of the binary I've downloaded from TestFlight.

Find where iOS is crashing based on crash reports

I have an app in beta using TestFlight and I have been noticing crash reports appearing.
most of the reports are this
If I click on the button Open in project in the Organizer it takes me no where
This appears to be an internal crash correct?
How can I find out what UIBarButtonItem is causing the crash?
I Hope this will help you: Apple doc Crash Report , as you can see in the doc in the Listing 4 the crash report is fully symbolicated , Listing 6 shows partially symbolicated crash reports which looks like your case
From Apple Doc
You must keep both the application binary and the .dSYM file in order to be able to fully symbolicate crash reports. You should archive these files for every build that you submit to iTunes Connect. The .dSYM and application binary are specifically tied together on a per-build-basis, and subsequent builds, even from the same source files, will not interoperate with files from other builds. If you use Xcode's Build and Archive command then they will be placed in a suitable location automatically. Otherwise any location searchable by Spotlight (such as your home directory) is fine.
For more information about this you can check portion after Listing 6 in Symbolication
you can use crashlytics for identifying where the app is crashed.It will give the Controller name and line number of code also.
https://docs.fabric.io/ios/index.html Document
Easy to add your project also

Only crashing on Testflight

We're using TestFlight to send out pilots of our app.
There's a part of the app that is crashing, and we had a lot of trouble reproducing the crash. The code their is fairly simple.
It turns out that the users who got the App via TestFlight get the crash, while if you build the app and install it using the IDE it doesn't crash!
Anyone have ideas about what might be causing this?
Any ideas for workarounds? We don't want to stop using TestFlight.
Make sure to build your app in Release Mode not in Debug. The app may only crash when in Release.
The first thing I'd try is to map the crash stack trace to function names in your application. This may yield useful insight into the nature of the crash:
As soon as a crash is reported request the crash log. This can be obtained through Xcode's organizer or if that's not an option it can be screen-captured from the iPhone's Settings -> General -> About -> Diagnostics & Usage -> Diagnostic & Usage Data. Scroll to the app name or the section LatestCrash-AppName.plist.
Although you can in theory symbolicate a crash, I find the procedure described below a foolproof way to get symbols from the stack. Convert all stack addresses for the crashing thread into method names.
Optionally request the iDevice syslog. This may include assertion failure messages which are also invaluable. Note that this should be done as quickly as possible as the syslog only holds so many entries before they get dropped. You can use the Organizer or the cmd line idevicesyslog to obtain this.
Manual symbolication:
This will work as long as your builds have debug information.
Obtain the _exact_same_ .ipa that crashed. If you didn't save it you can download it from the device by using iFunBox or the cmd line ideviceinstaller utility.
Unzip the .ipa
Run the following command on the executable file (Payload/AppName.app/AppName):
otool -tv AppName.app | c++filt > listing.asm
Wait while the previous step completes (may take a while). The generated listing.asm file will be several megabytes long.
Using an editor that can handle large files search listing.asm for the addresses listed in the stack trace. Note that the addresses may be a few bytes off (usually pointing 3 or so bytes ahead). Also, addresses that aren't found in listing.asm indicate addresses in iOS libraries. Ignore those for now.
Of course, if you're able to symbolicate, you can skip this procedure.
Good luck debugging!
We had a similar problem. The issue with us was static libraries. When we built the app from scratch and went to testflight, it was crashing but from the IDE it wasn't. The crash was because the static libraries did not get included when doing a build, but was getting included if I connected the iPad direct and used XCode to install.
A simple test will prove this:-
1.) Instead of building from IDE, create a .app file and then load it via iTunes and check if you are getting the crash.
We worked around this by creating the .iPA manually, that is creating the .app then making a Payload folder and putting the .app in it along with the info.plist.
Then things began to work in Testflight as well.

Resources