simple-express-proxy🗜📡
This is simple express proxy web server using https protocol.
Following is simple guide and usage example for quick start.
- Install package in your application
npm install simple-express-proxy
- Write code in your entry point code section
const createProxy = require("simple-express-proxy");
const fs = require("fs");
const privateKey = fs.readFileSync('./secure/key.pem', 'utf-8');
const certificate = fs.readFileSync('./secure/cert.pem', 'utf-8');
const passphrase = 'your custom password';
const target = 'https://google.com';
const whitelist = ['0.0.0.0', '95.180.41.194'];
const proxy = createProxy(privateKey, certificate, passphrase, target, whitelist);
proxy.listen((port, host) => {
console.log(`https proxy server is running on port ${port} and host ${host}`)
})
- Host your application . 💻