
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
node-localstorage-xxy
Advanced tools
A drop-in substitute for the browser native localStorage API that runs on node.js.
Copyright (c) 2012, Lawrence S. Maccherone, Jr.
A drop-in substitute for the browser native localStorage API that runs on node.js.
localStorage['myKey'] = 'myValue'
and dot property localStorage.myKey = 'myValue'
syntax. If you are in an ES6 supported environment.Author: Larry Maccherone
unless localStorage?
{LocalStorage} = require('../') # require('node-localstorage') for you
localStorage = new LocalStorage('./scratch')
localStorage.setItem('myFirstKey', 'myFirstValue')
console.log(localStorage.getItem('myFirstKey'))
# myFirstValue
localStorage._deleteLocation() # cleans up ./scratch created during doctest
Open or create src/setupTests.js
and add these two lines:
// /src/setupTests.js
import { LocalStorage } from "node-localstorage";
global.localStorage = new LocalStorage('./scratch');
if (typeof localStorage === "undefined" || localStorage === null) {
var LocalStorage = require('node-localstorage').LocalStorage;
localStorage = new LocalStorage('./scratch');
}
localStorage.setItem('myFirstKey', 'myFirstValue');
console.log(localStorage.getItem('myFirstKey'));
Polyfil your node.js environment with this as the global localStorage when launching your own code
node -r node-localstorage/register my-code.js
npm install node-localstorage
new
FAQs
A drop-in substitute for the browser native localStorage API that runs on node.js.
The npm package node-localstorage-xxy receives a total of 0 weekly downloads. As such, node-localstorage-xxy popularity was classified as not popular.
We found that node-localstorage-xxy 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
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.