App signs out user on navigation button press: investigate session management configuration
Android
When a user presses an in-app navigation button on an Esper-managed device, the app signs them out unexpectedly.
Why this happens
Esper's configuration can affect app session persistence in several ways: Kiosk Mode restrictions may intercept navigation events, app permissions may block credential or session storage, and activity lifecycle policies such as "Don't keep activities" can destroy the app's process mid-session. Identifying which setting is responsible requires narrowing down the cause systematically.
Before you start
- Access to the Esper Console with permission to view and edit Blueprints
- The name of the affected app and the blueprint applied to the affected device
- An identical non-enrolled device running the same Android version and app version (recommended for comparison testing)
- ADB access to the device (optional, for advanced log collection)
Step 1: Confirm Esper configuration is the cause
- Install the same app version on an identical device that is not enrolled in Esper.
- Reproduce the same navigation action that triggers the sign-out.
- If the sign-out does not occur on the non-enrolled device, the cause is an Esper configuration setting. Continue to Step 2. If the sign-out also occurs on the non-enrolled device, this is an app-side issue unrelated to Esper.
Step 2: Review the active blueprint
- In the Esper Console, navigate to Devices & Groups → [Device Name] → Blueprint and note the name of the active blueprint.
- Open that blueprint and check the following:
- Kiosk Mode: If Single App or Multi-App Kiosk Mode is enabled, confirm the affected app is the pinned app. Verify the navigation button is not configured to exit Kiosk Mode, which would clear the app's foreground state.
-
App permissions: Go to Apps & Configuration → [Your App Name] → Permissions and confirm that
Storageand any credential-related permissions are set toAllow, notDenyorAsk. Denying storage permissions prevents the app from persisting session tokens between navigation events. - Clear data policy: Confirm no automatic app data clearing policy is enabled for this app. Clearing app data destroys stored sessions.
Step 3: Check activity lifecycle settings
- In the active blueprint, open Device Settings.
- Locate the Don't keep activities setting and confirm it is disabled. When enabled, Android destroys every activity as soon as the user navigates away, which causes apps to lose in-memory session state.
- Check for any battery optimization or memory management settings that could terminate background app processes during navigation.
Step 4: Isolate the cause with a permissive test blueprint
- Create a temporary test blueprint with the most permissive settings:
- Kiosk Mode disabled
- All app permissions set to
Allow - No app data clearing policies
- Don't keep activities disabled
- Apply this blueprint to the affected device via Devices & Groups → [Device Name] → Blueprint.
- Reproduce the navigation action. If the sign-out no longer occurs, re-enable restrictions one at a time and retest after each change to identify the specific setting causing the issue.
Step 5: Collect diagnostic logs
- Reproduce the sign-out, then immediately navigate to Devices & Groups → [Device Name] → Actions → Bug Report and request a bug report.
- Download the report once available and search for the following terms:
- Your app's package name
ActivityManageram_killclear_data
- Look for any events showing the app process being terminated or app data being cleared at the moment of navigation.
- Alternatively, collect logs directly over ADB:
adb shell logcat -d | grep -iE "esper|ActivityManager|am_kill|clear_data|[your-app-package]"
Verify
Verify: After applying a configuration change, have the user press the in-app navigation button at least five consecutive times. The user should remain signed in on every press. The device status in the Esper Console should show In Sync within 5 minutes of the blueprint update being applied.
If this doesn't resolve it
If the sign-out continues after checking all blueprint settings and completing the permissive test, contact Esper Support with the following information:
- The device serial number or Esper Device ID
- The name of the active blueprint
- The downloaded bug report from Step 5
- The specific navigation action that triggers the sign-out
- Whether the issue reproduces on a non-enrolled device
Still need help?
If the issue persists after reviewing your session management settings, submit a support ticket and include your session timeout configuration, the steps you've taken to troubleshoot, and details about when the unexpected sign-out occurs during navigation.
Please sign in to leave a comment.
Comments
0 comments