In this article, Lets see how to record iOS application HTTP/HTTPS requests using JMeter.
Desktop/Laptop Setup:
- Make a note of your Desktop/Laptop IP address.
- Ensure that you have JMeter 2.11 or above & Java 7 or above.
JMeter Setup:
- Start JMeter . (Go to JMETER_HOME/bin, Start jmeter.bat or jmeter.sh)
- Under JMeter Test Plan – Workbench, add ‘HTTP(S) Test Script Recorder’.
- You can add a ‘View Results Tree’ under ‘HTTP(S) Test Script Recorder’ to see the request & response details while recording. (It is not mandatory to have it.)
- In my setup, Proxy server is running at port 2020.
- Click on the ‘Start’ button in ‘HTTP(S) Test Script Recorder’ to start the proxy server.
- You would see above dialog. JMeter will create a certificate – ApacheJMeterTemporaryRootCA.crt under JMETER_HOME/bin. (Java6 does not create this certificate).
- If JMeter does not create new certificate, remove these files in the bin directory & restart proxy server.
- ApacheJMeterTemporaryRootCA.crt
- proxyserver.jks
- Send the certificate to your email.
iOS Device Setup:
- In your ipad/mobile device, open the – ApacheJMeterTemporaryRootCA.crt – file & Install. We would need this if the iOS app uses HTTPS which will lead to SSL handshake issue.
- On your iPad, go to Settings > Wi-Fi and click the arrow next your Wi-Fi connection. Under “HTTP Proxy”, select the Manual button and enter your desktop’s IP address in the Server field. Then enter “2020″ in the Port field.
That’s it. Now your iPad/device will be sending all the requests via your JMeter proxy server running in your PC.
I opened Trello app in my iPad. JMeter started recording all the HTTP requests from iPad.