
Research
Security News
Lazarus Strikes npm Again with New Wave of Malicious Packages
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
@kentico/kontent-backup-manager
Advanced tools
This utility enables backup & restore of Kentico Kontent projects
The purpose of this project is to backup & restore Kentico Kontent projects. This project uses CM API to both get & restore data.
Install package globally:
npm i @kentico/kontent-backup-manager -g
Config | Value |
---|---|
projectId | Id of Kentico Kontent project (required) |
apiKey | Content management Api key (required) |
action | Action. Possible values are: 'restore' & 'backup' & 'clean' (required) |
zipFilename | Name of zip used for export / restoring data. E.g. 'kontent-backup'. |
enableLog | Indicates if default logging is enabled (useful to indicate progress) |
force | If enabled, project will we exported / restored even if there are data inconsistencies. Enabled by default. |
We recommend restoring backups to clean (empty) projects. Restoration process may make changes to target project such as changing language codenames to match source project.
To backup a project run:
kbm --action=backup --apiKey=xxx --projectId=xxx
To restore a project run:
kbm --action=restore --apiKey=xxx --projectId=xxx --zipFilename=backupFile
To clean (delete) everything inside a project run:
kbm --action=clean --apiKey=xxx --projectId=xxx
Create a json
configuration file in the folder where you are attempting to run script. (e.g. backup-config.json
)
{
"projectId": "xxx",
"apiKey": "xxx",
"zipFilename": "backup",
"action": "backup",
"enableLog": true,
"force": true
}
To execute your action run:
kbm --config=backup-config.json
const run = async () => {
const exportService = new ExportService({
apiKey: 'sourceProjectApiKey',
projectId: 'sourceProjectId',
onExport: item => {
// called when any content is exported
console.log(`Exported: ${item.title} | ${item.type}`);
}
});
// data contains entire project content
const data = await exportService.exportAllAsync();
// you can also save backup in file with ZipService
const zipService = new ZipService({
filename: 'file',
enableLog: true
});
await zipService.createZipAsync(data);
};
run();
const run = async () => {
const zipService = new ZipService({
filename: 'xxx',
enableLog: true
});
const importService = new ImportService({
onImport: item => {
// called when any content is imported
console.log(`Imported: ${item.title} | ${item.type}`);
},
fixLanguages: true,
projectId: 'targetProjectId',
apiKey: 'targetProjectId',
enableLog: true,
workflowIdForImportedItems: '00000000-0000-0000-0000-000000000000' // workflow id that items are assigned
});
// read export data from zip
const data = await zipService.extractZipAsync();
// restore into target project
await importService.importFromSourceAsync(data);
};
run();
const run = async () => {
const zipService = new ZipService({
filename: 'xxx',
enableLog: true
});
const importService = new ImportService({
onDelete: item => {
// called when any content is deleted
console.log(`Deleted: ${item.title} | ${item.type}`);
},
fixLanguages: true,
projectId: 'targetProjectId',
apiKey: 'targetProjectId',
enableLog: true
});
// read export data from zip
const data = await zipService.extractZipAsync();
// restore into target project
await importService.importFromSourceAsync(data);
};
run();
FAQs
This utility enables backup & restore of Kentico Kontent projects
We found that @kentico/kontent-backup-manager demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 11 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
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.
Security News
Opengrep continues building momentum with the alpha release of its Playground tool, demonstrating the project's rapid evolution just two months after its initial launch.