Layer 7 Mobile API Gateway: MAS app for Android crashes on startup
search cancel

Layer 7 Mobile API Gateway: MAS app for Android crashes on startup

book

Article ID: 136957

calendar_today

Updated On:

Products

CA Mobile API Gateway CA Rapid App Security CA API Gateway

Issue/Introduction

When launching the 'MAS Android Login User Authentication and Authorization' sample app on Android P (API 28) it will crash on startup.

https://github.com/CAAPIM/Sample-App-MAS-Android-Login-User-Authentication-And-Authorization

You will see errors similar to the below in the logs:

2019-09-12 07:56:51.845 13683-14103/com.google.android.gms.unstable W/KeyStore: KeyStore exception

    android.os.ServiceSpecificException:  (code 7)

   


Environment

Android P

MAS SDK 1.8+

 

Cause

Secure Account Manager Storage (AMS) stores SSO tokens and data using Android AccountManager, providing an extra layer of data encryption before storing the data to the AccountManager. We recommended using Secure Account Manager Storage rather than Android keystore (default). Although Secure AMS is the default token storage for Android P devices and higher, you must explicity enable Secure AMS for earlier Android devices.

Resolution

Be sure to set up Secure Account Manager Storage per our documentation:

https://techdocs.broadcom.com/us/en/ca-enterprise-software/layer7-api-management/mobile-sdk-for-ca-mobile-api-gateway/2-1/android-sdk/android-2-1-guide/Set-Up-Project-and-Start-the-SDK.html