Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
more-router
Advanced tools
more-router is a routing library. It can run both on the client as well as on the server.
Its possibly special qualities include:
it has a precedence system: given the pattern /foo
and the pattern
/{myvariable}
, the path /foo
will match the pattern /foo
, not
the variable.
you mix text and variables in a single segment: /prefix{variable}
a publisher abstraction where you can express routes only respond to particular requests, i.e. only GET requests.
var moreRouter = require('more-router');
var router = new moreRouter.Router();
// second argument can be anything you like; here we use a string
// for easy demonstration of the API
router.addPattern('a', 'found a');
router.addPattern('a/{v}', 'found a/{v}')
router.resolve('a')
// returns
// {
// value: "found a",
// stack: [],
// variables: {}
// }
router.resolve('a/foo')
// returns
// {
// value: "found a/{v}",
// stack: [],
// variables: {'v': 'foo'}
// }
// alternate consume interface which taxes a stack
router.consume(['foo', 'a'])
// returns
// {
// value: "found a/{v}",
// stack: [],
// variables: {'v': 'foo'}
// }
// if no match exists, value is null, unmatched segments are on stack
router.resolve('notthere')
// returns
// {
// value: null,
// stack: ['notthere'],
// variables: {}
// }
To be documented.
more-router is derived from the routing code in the Morepath web framework written in Python.
FAQs
Router library. Derived from Morepath.
The npm package more-router receives a total of 0 weekly downloads. As such, more-router popularity was classified as not popular.
We found that more-router 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.