Research
Security News
Threat Actor Exposes Playbook for Exploiting npm to Build Blockchain-Powered Botnets
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
uri-template-lite
Advanced tools
@version 0.1.7
@date 2014-05-21
@stability 2 - Unstable
URI Template [RFC 6570][rfc-6570] implementation in less than 1kb.
To use it in the browser, include uri-template-min.js in your site
<script src=uri-template-min.js></script>
In node.js: npm install uri-template-lite
var URI = require("uri-template-lite").URI
var data = {"domain":"example.com", "user":"fred", "query":"mycelium"}
URI.expand("http://{domain}/~{user}/foo{?query,number}", data)
// http://example.com/~fred/foo?query=mycelium
var template = new URI.Template("http://{domain}/~{user}/foo{?query,number}")
var data = {"domain":"example.com", "user":"fred", "query":"mycelium", "number": 3}
template.expand(data)
// http://example.com/~fred/foo?query=mycelium&number=3
template.match("http://example.com/~fred/foo?query=mycelium&number=3")
// {"domain":"example.com", "user":"fred", "query":"mycelium", "number": "3"}
template.match("http://other.com/?query=mycelium")
// false
This implementation tries to do a best effort template expansion and leaves erroneous expressions in the returned URI instead of throwing errors. So for example, the incorrect expression {unclosed will return {unclosed as output.
browser-upgrade-lite
package
or other ES5 polyfill.escape
should be patched to remove non-standard 2nd param,
browser-upgrade-lite
does that.Copyright (c) 2014 Lauri Rooden <lauri@rooden.ee>
The MIT License
FAQs
URI Template [RFC 6570] expansion and extraction
We found that uri-template-lite 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 threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
Security News
NVD’s backlog surpasses 20,000 CVEs as analysis slows and NIST announces new system updates to address ongoing delays.
Security News
Research
A malicious npm package disguised as a WhatsApp client is exploiting authentication flows with a remote kill switch to exfiltrate data and destroy files.