Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

esniffer

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

esniffer

Modern network analyze tool. Alternatives to Hoxy, Charles, etc.

  • 1.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
11
increased by266.67%
Maintainers
1
Weekly downloads
 
Created
Source

ESniffer 🔬

Modern network analyze tool. Alternatives to Hoxy, Charles, etc.

Install

npm i esniffer
yarn add esniffer

Example

// index.js
import ESniffer from "esniffer";
import fs from "fs";

// Required if you want to monitor over HTTPS
const key = fs.readFileSync(`path/to/root-key.pem`);
const cert = fs.readFileSync(`path/to/root-cert.pem`);

const proxy = ESniffer.createServer({ secure: { key, cert } });
proxy.listen(8080);

proxy.on("request", (req) => {
  req.pipe(process.stdout);
});
proxy.on("response", (res) => {
  res.pipe(process.stdout);
});
proxy.on("info", (info) => {
  console.log(info);
});
proxy.on("error", (e) => {
  console.error(e.message);
});

Start and configure the proxy server

node index.js

In your mac, from System Preferences > Network > Advanced... > Proxies tab, configure the proxy as follows:

ProtocolHostPort
Web Proxy (HTTP)127.0.0.18080
Secure Web Proxy (HTTPS)127.0.0.18080

Finally, don't forget OK and Apply.

Events

namedescriptiontype
infoLogs of the proxy serverstring
errorErrors occurring on the proxy serverError
requestRequest object to the actual serverhttp.IncomingMessage
responseResponse object to the actual serverhttp.IncomingMessage

Keywords

FAQs

Package last updated on 06 Nov 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc