0
votes

Android mobile native application recording issue

  • Step 1: Laptop and Android phone are on the same wifi network.
  • Step 2: Android phone is configured as the following:
  • Manual: IP set to Laptop (IP4) and Port is set to JMeter port 8888
  • Step 3: Started recording
  • Step 4: Started performing actions on the Android native application.

Observations:

  • Native App recording failed.

Additional Info: I am able to record actions on the Android Web Browser

enter image description here

1

1 Answers

0
votes

If you're running Android 7.0 or higher most probably it's the matter of increased network security config so you need to follow some extra steps in order to be able to record secure traffic using JMeter proxy server, to wit:

  1. Add the next line to the application section of your Android app manifest file:

    android:networkSecurityConfig="@xml/network_security_config"
    
  2. Create network_security_config.xml file under your app resources folder and put the following code inside:

    <?xml version="1.0" encoding="utf-8"?>
    <network-security-config>
        <debug-overrides>
            <trust-anchors>
                <!-- Trust user added CAs while debuggable only -->
                <certificates src="user" />
            </trust-anchors>
        </debug-overrides>
    </network-security-config>
    
  3. Compile and install your application in debug mode like:

    gradlew installDebug