
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
combine-config
Advanced tools
Combine config object
npm install combine-config
var combine_config = require("combine-config");
var prototype_stringify = require("prototype-stringify"); //tool for debug
var base_config = {
ip: "127.0.0.1", //Items will be untouched if not existed in sub config.
port: 8080,
param: [1, 2, 3, 4],
date1: new Date(2000, 1, 1),
func1: function () { },
mine: {
"html": "text/html", //Items will be untouched if not existed in sub config.
"jpg": "image/jpg",
},
mine2: {
"html": "text/html",
"jpg": "image/jpg",
},
};
var sub_config = {
port: 8081, //Items will be replaced, except simple objects.
param: [3, 4],
date1: null,
func1: undefined,
mine: { //simple objects will be deep-copied.
"txt": "text/plain",
"jpg": "application/octet-stream",
},
"!mine2": { //To stop deep-copy, prefix name with "!".
"txt": "text/plain",
},
param2: "new param", //Add new item
};
var new_config = combine_config(base_config, sub_config, "test"); //A new config object is created
//change somethig
new_config.mine["css"] = "text/css"; //The base config is isolated by prototype chain
base_config.ip2 = "127.0.0.2"; //Change to base config will be seen in the new config
base_config.mine["js"] = "text/javascript";
base_config.mine["html"] = "text";
console.log(new_config);
prototype_stringify(new_config, "\t");
/*
var expect_config = {
ip: "127.0.0.1",
ip2: "127.0.0.2",
port: 8081,
param: [3, 4],
date1: null,
func1: undefined,
mine: {
"html": "text",
"txt": "text/plain",
"jpg": "application/octet-stream",
"js": "text/javascript",
"css": "text/css",
},
mine2: {
"txt": "text/plain",
},
param2: "new param",
};
*/
FAQs
combine config
We found that combine-config 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.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.