Skip to main content

Known issues

info

This page covers known issues that occur in the SDK iOS.

When necessary, issues are treated and new releases with corrections are made available.

Code Obfuscation

Important

This page must be used as a developer's guidebook when obfuscation problems arise during application's deployment.

The client obfuscation framework might affect the SDK behavior, so it is mandatory that the SDK do not be obfuscated by it.

Unico disclaims liability in relation to obfuscation conflicts with the SDK.

Obfuscation is a process of transforming bytecode into a less human-readable form, thus making reverse engineering difficult.

This process consists of removing debugging-related information such as variable tables, number of lines and renaming packages, classes and methods.

When embedding the Flutter SDK in the application, crashes or abrupt closures may occur.

Obfuscation by DexGuard

Unfortunately, the criation process of rules in DexGuard is laborious, many time by trial and error.

Although, beneath are some rules that have helped our customers to implement the application obfuscation.

-keep class kotlin.coroutines.**
-keep class kotlinx.coroutines.**

-keep class com.facetec.sdk.** { *; }
-keep class com.acesso.acessobio_android.** { *; }
-keep class io.unico.** { *; }

-keep class br.com.makrosystems.haven.** { *; }
-keep class HavenSDK.**{ *; }
-keep class HavenSDK** { *; }

Obfuscation by ProGuard

-keep class kotlin.coroutines.**
-keep class kotlinx.coroutines.**

-keep class com.facetec.sdk.** { *; }
-keep class com.acesso.acessobio_android.** { *; }
-keep class io.unico.** { *; }

-keep class br.com.makrosystems.haven.** { *; }
-keep class HavenSDK.**{ *; }
-keep class HavenSDK** { *; }

To obfuscation by ProGuard we have a POC in the following link.

Bitcode Error in App Distribution Using Xcode 16

After the official release of Xcode 16 on September 17, 2024, and its use for app distribution in the App Store, we encountered a blockage when using the iOS SDK signaling the use of bitcode in two internal dependencies when using Cocoapods as the internal dependency manager. These are DeviceProfiling and UnicoSdkLogger. In order not to block new releases, it is possible to apply the following step-by-step procedure until its definitive correction in a future release of the iOS SDK:

  1. Open the Podfile;
  2. Insert the following lines after the command post_install do |installer| and before the last end:
bitcode_strip_path = `xcrun --find bitcode_strip`.chop!
def strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
framework_path = File.join(Dir.pwd, framework_relative_path)
command = "#{bitcode_strip_path} #{framework_path} -r -o #{framework_path}"
puts "Stripping bitcode: #{command}"
system(command)
end

framework_paths = [
"Pods/unicocheck-ios/DeviceProfiling.xcframework/ios-arm64/DeviceProfiling.framework/DeviceProfiling",
"Pods/unicocheck-ios/UnicoSdkLogger.xcframework/ios-arm64/UnicoSdkLogger.framework/UnicoSdkLogger"
]

framework_paths.each do |framework_relative_path|
strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
end

2.1. If there is already some code, insert it before the existing section;

2.2. If manual bitcode removal is already being done, explicitly add the paths mentioned in framework_paths;

  1. If there is no post_install do |installer| command in the Podfile, insert it as shown below before the last end:
 post_install do |installer|
bitcode_strip_path = `xcrun --find bitcode_strip`.chop!
def strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
framework_path = File.join(Dir.pwd, framework_relative_path)
command = "#{bitcode_strip_path} #{framework_path} -r -o #{framework_path}"
puts "Stripping bitcode: #{command}"
system(command)
end

framework_paths = [
"Pods/unicocheck-ios/DeviceProfiling.xcframework/ios-arm64/DeviceProfiling.framework/DeviceProfiling",
"Pods/unicocheck-ios/UnicoSdkLogger.xcframework/ios-arm64/UnicoSdkLogger.framework/UnicoSdkLogger"
]

framework_paths.each do |framework_relative_path|
strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
end

Source: Bitrise, Xcode 16 release notes, Stackoverflow

Any concerns?

Didn't find something or still need help? If you are already a customer or partner, you can contact us through Help Center.