-
-
Notifications
You must be signed in to change notification settings - Fork 50
Open
Description
Good afternoon,
first I found this library incredible, congratulations on the work!
I use lib to intercept various protocols (http, https, mongodb, rabbitmq, redis, etc. ..)
however, when I try to intercept the gRPC calls made by lib Google PubSub it doesn't work like the other protocols, it seems to be looping.
investigating on the internet, i found that this lib uses under the engine called gRPC, and that in turn uses underneath called http2
Our use case is not for the purpose of TDD (unit tests), but I use it as a Firewall allowing or not requests.
Below is an example of my code:
`
var Mitm = require("mitm");
var mitm = Mitm();
mitm.enable();
mitm.on("connect", function(socket:any, opts:any) {
socket.bypass();
try{
if("my release rule") {
socket.bypass();
}
else {
socket.end();
}
}
catch(err){
socket.end();
}
});
`
Nodejs : v12.16.1
pabloalmeidas13
Metadata
Metadata
Assignees
Labels
No labels