Security News
Opengrep Emerges as Open Source Alternative Amid Semgrep Licensing Controversy
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
an-node-proxy
Advanced tools
`an-node-proxy` is an http proxying library, supports both http and https, and also supports proxy to local data with the need of mock request
an-node-proxy
is an http proxying library, supports both http and https, and also supports proxy to local data with the need of mock request
npm install an-node-proxy --save
import {createServer} from 'http'
import {createProxyServer} from 'an-node=proxy'
// proxy server
createProxyServer({
target: 'http://localhost:8001'
}).listen(8000)
// target server
createServer((req, res) => {
res.writeHead(200, { 'Content-Type': 'text/plain' })
res.write(`request from ${req.socket.localAddress}, and headers are ${JSON.stringify(req.headers, null, 2)}`)
res.end()
}).listen(8001)
so does https, an-node-proxy
also support
import express from 'express'
import {createServer} from 'http'
import {createProxy} from 'an-node-proxy'
const app = new express()
const proxy = createProxy({
target: 'http://localhost:8004'
})
app.use((req, res) => {
proxy.proxy(req, res)
})
app.listen(8003)
// target server
createServer((req, res) => {
res.writeHead(200, { 'Content-Type': 'text/plain' })
res.write(`request from ${req.socket.localAddress}, and headers are ${JSON.stringify(req.headers, null, 2)}`)
res.end()
}).listen(8004)
import {createServer} from 'http'
import {createProxyServer} from 'an-node-proxy'
// mock server
createProxyServer({
mock: {
rules: [
{
from: '/test',
to: './examples/mock'
},
{
from: '/test/a.js',
to: './examples/a.js'
}
]
}
}).listen(8005)
FAQs
`an-node-proxy` is an http proxying library, supports both http and https, and also supports proxy to local data with the need of mock request
The npm package an-node-proxy receives a total of 1 weekly downloads. As such, an-node-proxy popularity was classified as not popular.
We found that an-node-proxy demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.