1

Our tester captured some unknown GET request while doing API testing in our React Native application.

GET /inspector/device?name=some_unique_id&app=com.companyname.appname HTTP/1.1

Upgrade: websocket
Connection: Upgrade
Sec-WebSocket-Key: encrypted key
Sec-WebSocket-Version: 13
Host: localhost:8082
Accept-Encoding: gzip, deflate
User-Agent: okhttp/3.11.0

Could someone give me some idea what is this and why is this called.?

Thanks.

arthankamal
  • 6,341
  • 4
  • 36
  • 51

1 Answers1

1

It seems the line may comes from RCTInspectorDevServerHelper.mm. You can see the line

return [NSURL URLWithString:[NSString stringWithFormat:@"http://%@/inspector/device?name=%@&app=%@",
                                                        getServerHost(bundleURL, inspectorProxyPort),
                                                        escapedDeviceName,
                                                        escapedAppName]];

inside getInspectorDeviceUrl function, which seems to be called each time the app is loaded to connect with the bundle.

rabbit87
  • 3,165
  • 2
  • 20
  • 29