4.0.2 • Published 4 years ago

socket.io-cap v4.0.2

Weekly downloads
4
License
MIT
Repository
github
Last release
4 years ago

socket.io-cap

Proxy server for capturing socket.io data.

Installation

npm install socket.io-cap

Example

const fs = require('fs');
const IOProxy = require('socket.io-cap');

const hoxyOpts = {
  certAuthority: {
    key: fs.readFileSync('./ca-key.pem'),
    cert: fs.readFileSync('./ca-crt.pem'),
  }
};
const proxy = new IOProxy(hoxyOpts).listen(8889);

proxy.on('conn', ctx => {
  //ctx.proxy = 'socks://localhost:1080';
  proxy.showConn(ctx, {
    showHeader: false,
  });
});

proxy.on('engine', ctx => {
  proxy.showEnginePacket(ctx, {
    showUrl: true,
    showRaw: false,
    showParsed: true,
    skipMessage: true,
  });
});

proxy.on('socket', ctx => {
  proxy.showSocketPacket(ctx, {
    showUrl: true,
    showRaw: false,
    showParsed: true,
    skipMessage: true,
  });
});

proxy.on('message', ctx => {
  proxy.showMessage(ctx, {
    showUrl: true,
    showArgs: true,
  });
});
4.0.2

4 years ago

4.0.1

4 years ago

4.0.0

4 years ago

3.0.2

4 years ago

3.0.1

4 years ago

3.0.0

4 years ago

2.0.4

4 years ago

2.0.3

4 years ago

2.0.2

6 years ago

2.0.1

6 years ago

2.0.0

6 years ago

1.0.0

6 years ago