alexbrazier / react-native-network-logger

An HTTP network request monitor for React Native with in-app interface for iOS and Android with no native code
MIT License
536 stars 48 forks source link

Functionality for SIP/Protocols other than HTTP #48

Open lawhorkl opened 3 years ago

lawhorkl commented 3 years ago

I've downloaded and used this package and I've verified that it works for HTTP requests but I'm curious as to whether this also captures network requests from other protocols like SIP?

alexbrazier commented 3 years ago

Hi @lawhorkl, behind the scenes the package makes use of this intercepter in react-native https://github.com/facebook/react-native/blob/master/Libraries/Network/XHRInterceptor.js

From what I can tell this interceptor doesn't support other protocols and I can't see any others in the react-native project. Open to any suggestions if you can work out how it could be done though!

lawhorkl commented 3 years ago

thanks for the quick response.

trying to figure out how to capture packets in general in react native for a SIP based application. If I find anything that could be of use I will post it here

t1gor commented 3 years ago

Hello, @alexbrazier. Based on your answer below, I assume Websocket (sw/ssw) requests also can't be viewed by the lib, right?

alexbrazier commented 3 years ago

Hi @t1gor, as far as I can tell react native doesn't expose anything that would allow this library to intercept sockets either.