This article provides instructions on how to capture a HAR file from an Android device or an emulated Android device, which can assist with troubleshooting.
NOTE: These instructions cover capturing a HAR file only from a browser and do not address native applications or embedded browsers.
- Okta Identity Engine (OIE)
- Android
- Traffic capture
For the traffic to be captured on a desktop device, the Android device must have developer mode active and USB debugging activated. The option is enabled by default for emulated Android devices.
NOTE: When USB debugging is enabled, the device must only be connected to known devices for security reasons.
To enable developer mode, see the steps below:
- Go to Settings.
- Tap About device or About phone.
- Tap Software information.
- Tap Build number seven times.
- Enter the pattern, PIN, or password to enable the Developer options menu.
- The Developer options menu will now appear in the Settings menu.
NOTE: Settings can differ depending on the manufacturer. The steps above will enable developer options, including USB debugging.
USB debugging can be activated from Settings > System > Advanced > Developer Options > USB debugging.
- With USB debugging enabled, connect the Android device to the PC.
- With the mobile device connected, navigate in the desktop device browser to chrome://inspect/#devices (for the Chrome browser, the same format also works for edge://inspect/#devices, or brave://inspect/#devices. Refer to this link for Firefox steps.)
This will open a browser page on which the Android device and any open browser tabs can be seen.
- Select Inspect on the tab that is required for troubleshooting.
- This will open a HAR file capture for the Android device browser tab. At this point, reproducing the issue on the Android device is required to generate network traffic.
- With the newly generated traffic, the HAR needs to be exported and attached to the case.
NOTE: Remove or hide any confidential or personally identifying information before sending the HAR file to Okta. The file can be edited with a text editor. See Sanitize HTTP Traces and How to Sanitize a HTTP Trace File Automatically.
