
Research
/Security News
9 Malicious NuGet Packages Deliver Time-Delayed Destructive Payloads
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.
@boundstate/firebase-migrate
Advanced tools
CLI for syncing Firebase and handling migrations.
$ npm install @boundstate/firebase-migrate
Migrating data in Firebase production apps is hard.
The aim of this tool is to ease the process, avoiding data loss or disruptions to services.
Each version of data is prefixed (e.g. /v1, /v2) so that apps can still function until they are updated.
Rules for each version are defined in separate files, and are automatically combined and updated so that only the latest
version of data is writable.
Configure your project by creating firebase-migrate.json at the project root:
{
"environment": {
"project-1": {
"someservice.key": "PROJECT_1_SOME_SERVICE_KEY"
}
},
"migrations": "./firebase/migrations",
"databaseRules": "./firebase/rules"
}
Options
environment: map of projects to maps of Firebase functions config keys to ENV var names.
(Config is set during the migration process before cloud functions are deployed)migrations: path to migrationsdatabaseRules: path to Bolt filesImportant: If using TypeScript, compile migrations before running the CLI, and point the
migrationspath infirebase-migrate.jsonto the build folder.
Create a migration file v1-to-v2.ts:
import {MigrateFunction} from '@boundstate/firebase-migrate';
const migrate: MigrateFunction = async (db) => {
await db.update('/', {
'example/path': true,
});
};
export = migrate;
Before this function is run, all data will be automatically copied from
/v1to/v2. Database operations performed in the function are automatically prefixed with/v2.
Create a file in your rules folder named v2-rules.bolt and define the security rules
Update references in your app code to use the v2 data
Deploy to Firebase and apply any new migrations:
$ firebase-migrate --project <projectId>
Deploy only database rules, functions and/or storage rules (skipping migrations):
$ firebase-migrate --project <projectId> --only database functions storage
--force).FAQs
CLI for deploying to Firebase and handling migrations
The npm package @boundstate/firebase-migrate receives a total of 2 weekly downloads. As such, @boundstate/firebase-migrate popularity was classified as not popular.
We found that @boundstate/firebase-migrate demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.

Security News
Learn the essential steps every developer should take to stay secure on npm and reduce exposure to supply chain attacks.