IBM Support

PH29218: ANDROID APP CRASHES DUE TO ILLEGALACCESSERROR DURING LAUNCH

Subscribe to this APAR

By subscribing, you receive periodic emails alerting you to the status of the APAR, along with a link to the fix after it becomes available. You can track this item individually or track all items by product.

Notify me when this APAR changes.

Notify me when an APAR for this component changes.

 

APAR status

  • Closed as program error.

Error description

  • Product components impacted: Android SDK
    Affected mobile development environments: Android
    Mobile Devices Operating Systems impacted: Android
    User roles impacted: End Users
    Distribution: Fix Central
    Versions affected: 8.0
    
    When an Android apk is protected using tools such as
    Arxan, the app might crash during launch with the following
    exception :
    java.lang.IllegalAccessError.
    
    This crash occurs due to the way Arxan intercepts the operating
    system level operations performed by the Mobile Foundation
    libraries. Specifically the use of Arxan prevents the Mobile
    Foundation Android SDK to be unable to deserialize previously
    serialized data which results in the app crash. The following is
    the stack trace when the app crashes
    
    java.lang.
    IllegalAccessError
    java.lang.IllegalAccessError :
    at
    com.worklight.wlclient.cookie.SharedPrefsCookiePersistor.loadAll
    :()Ljava/util/List;
    at
    com.worklight.wlclient.cookie.PersistentCookieJar.<init>:(Lcom/w
    orklight/wlclient/cookie/CookieCache;Lcom/worklight/wlclient/coo
    kie/CookiePersistor;
    at
    com.worklight.wlclient.HttpClientManager.<init>:(Landroid/conten
    t/Context;
    at
    com.worklight.wlclient.HttpClientManager.createInstance:(Landroi
    d/content/Context;
    at
    com.worklight.common.Logger.setContext:(Landroid/content/Context
    ;
    at
    com.worklight.androidgap.api.WL.<init>:(Landroid/content/Context
    ;
    at
    com.worklight.androidgap.api.WL.VBs-StaticWrapper(I[Ljava/lang/O
    bject;)Ljava/lang/Object;"
    at com.ibm.MFPApplication.onCreate (MFPApplication.java: 21)
    at android.app. Instrumentation.callApplicationOnCreate
    (Instrumentation . java: 1189)
    at android.app.ActivityThread.handleBindApplication
    (ActivityThread. java : 6591 )
    at android.app.ActivityThread.access$1500 (ActivityThread . java
    : 230)
    at android .app.ActivityThread$H.handleMessage(ActivityThread .
    java : 1911 )
    at android.os.Handler.dispatchMessage (Handler. java : 107)
    at android.os.Looper.loop (Looper.java:224)
    at android.app.ActivityThread.main (ActivityThread.java:7551)
    at java.lang.reflect.Method.invoke (Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run
    (RuntimeInit .java: 539)
    

Local fix

  • Uninstall and re-install app
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * Developers using the Mobile Foundation Android SDK along     *
    * with third party app protection tools such as Arxan          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * When Android apk is protected using the third party tool     *
    * Arxan, the app might crash during launch with an exception : *
    * java.lang.IllegalAccessError.                                *
    *                                                              *
    * This crash has occurred due to Arxan intercepting the        *
    * operating system level calls made by the Mobile Foundation   *
    * SDK which causes a loss of data integrity. Serialized data   *
    * stored by the Mobile Foundation libraries are not            *
    * deserialized correctly when the app is protected with Arxan. *
    * This APAR handles the error condition gracefully instead of  *
    * resulting in the app crashing.                               *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Include below classes in obfuscating rules :                 *
    *                                                              *
    * MFPApplication.java -  com.ibm                               *
    *                                                              *
    *  WL.java - com.worklight.androidgap.api                      *
    *                                                              *
    *  HttpClientManager.java - com.worklight.wlclient             *
    *                                                              *
    *  WLPersistentCookie.java - com.worklight.wlclient.cookie     *
    *                                                              *
    *  SetCookieCache.java - com.worklight.wlclient.cookie         *
    *                                                              *
    *  CookieCache.java - com.worklight.wlclient.cookie            *
    *                                                              *
    *  SharedPrefsCookiePersistor.java -                           *
    * com.worklight.wlclient.cookie                                *
    *                                                              *
    *  CookiePersistor.java - com.worklight.wlclient.cookie        *
    *                                                              *
    *  PersistentCookieJar.java - com.worklight.wlclient.cookie    *
    *                                                              *
    *  ClearableCookieJar.java - com.worklight.wlclient.cookie     *
    *                                                              *
    *  SerializableCookie.java - com.worklight.wlclient.cookie     *
    *                                                              *
    *  Serializable.java - java.io                                 *
    ****************************************************************
    

Problem conclusion

  • Problem has been fixed in MFP SDK to avoid crash
    

Temporary fix

  • Uninstall and reinstall app
    

Comments

APAR Information

  • APAR number

    PH29218

  • Reported component name

    MOBILE1ST PLATF

  • Reported component ID

    5725I4301

  • Reported release

    800

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2020-09-07

  • Closed date

    2020-10-19

  • Last modified date

    2020-10-19

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    MOBILE1ST PLATF

  • Fixed component ID

    5725I4301

Applicable component levels

[{"Line of Business":{"code":"LOB45","label":"Automation"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSZH4A","label":"IBM Worklight"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"800"}]

Document Information

Modified date:
20 October 2020