Facing issue while recording data from Android mobile device to JMeter

26 views
Skip to first unread message

Sifaat

unread,
Sep 25, 2024, 6:59:21 AM9/25/24
to BlazeMeter Forum

Hi Team,


Hope you all are doing great. I have been facing an issue with JMeter and am meaning to get some help. The respective issue is explained below.

 

Objective: To record the app data/ traffic of an android app from an android phone in JMeter in laptop smoothly

 

Components used: 

·      apache-jmeter-5.6.3

·      jdk 1.8

·      android debug build

 

Standard method followed:

1.    Download JMeter Temporary Certificate into the android device and install it. 

2.    Set up a proxy on the android device and the laptop. Once the mobile device and laptop are using the same Wi-Fi network, use the laptop's IPv4 address as the proxy server and a 4-digit port number same as that in JMeter.

3.    Start performing the required flows in the mobile app and the data/ network traffic gets recorded by JMeter in the laptop.

 

Issue:

The requirement involves logging into the application after launching it. Until the month of June, we were able to record the said flow easily by following the above mentioned steps. Since the last two months we have been facing issues while recording the login flow. Whenever we set up the proxy and then launch the application, it records normally. But when we enter credentials to login, it shows an error has occurred, with a code no. 400106. The 400106 error is propagated by the Android SDK network service when the service does not recognize network connection.


  1. We tried the same flow on different debug builds on different devices using the same JMeter version in our laptops, but it did not help.
  2. We reached out to the SAP team as well, but they told us that they cannot help as no log/ failure log is available for them to check. Also, our client’s team could not help as it is not in there is no error in their CDC logs.
  3. We tried to record the flow using Android Studio Emulator as well in the laptop which has JMeter in it. A project was created as an emulated device. JMeter root certificate was downloaded and installed into it, proxy was set up as mentioned in the standard method above, same port number set up in the emulator and JMeter and the same debug build was used for the recording. We got the same error as we were getting in the real device while login but also got the logs of the same. The logs had the statement: javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.
  4. Followed by this, our developers tried to make a change to the debug build to accept any certificate that we add to the mobile device but that also did not help.
  5. We also tried to launch our web application in the Google Chrome browser in the mobile device and found that like the mobile app, the web app was also showing errors while logging:
    2024-09-23 15:03:23,389 WARN o.a.j.p.h.p.Proxy: [57636]  Empty response to http over SSL. Probably waiting for user to authorize the certificate for cdns.eu1.gigya.com:443

    2024-09-23 15:03:54,385 WARN o.a.j.p.h.p.Proxy: [39584]  Problem with SSL certificate for url  for 'c.amazon-adsystem.com'? Ensure browser is set to accept the JMeter proxy cert: Connection reset
  6. We also tried to record the login flow of Amazon mobile app for the sake of exploration and were able to record the flow successfully.
  7. We tried to record the same login flow in Neoload tool and got the same error while logging in.

Looking for help in anticipation

Thanks in advance

Dmitri T

unread,
Sep 25, 2024, 7:08:09 AM9/25/24
to BlazeMeter Forum
You need to perform extra steps in your application network security configuration in order to make it possible. See Configure Android Devices for Proxy Recording documentation chapter for more details.

Sifaat

unread,
Sep 25, 2024, 7:47:46 AM9/25/24
to BlazeMeter Forum
Hello Dmitri, everyone,

Thanks for the quick response. The steps that you suggested are already implemented in the debug builds by the developers.

It is a flight booking app and we are able to record the flows of booking flights for a guest user. The issue is at the point where we try to login as a registered user. The developer has told me that Gigya SDK is used to login and that is the point where we are stuck.

Suggestions/ Questions are welcome

Thanks

Sifaat

Dmitri T

unread,
Sep 25, 2024, 7:51:15 AM9/25/24
to BlazeMeter Forum
I guess you need to play the same trick with Gigya SDK: https://github.com/SAP/gigya-android-sdk/blob/main/sdk-core/src/main/AndroidManifest.xml

Sifaat

unread,
Sep 25, 2024, 8:22:15 AM9/25/24
to BlazeMeter Forum
Hi Dmitri

He is telling me that the it is a SDK internal file and is ready-only. We cannot access or modify internal Library files inside the SDK.

Is there a workaround?

Thanks

Sifaat

Dmitri T

unread,
Sep 25, 2024, 8:25:49 AM9/25/24
to BlazeMeter Forum
What do you want from me exactly? Teach your "developer" how to use apktool?

If you're a BlazeMeter customer and this is a showstopper for your testing you can open a BlazeMeter Support ticket
Reply all
Reply to author
Forward
0 new messages