Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
osh-cassandra
Advanced tools
This package is basically a wrapper around the Node.JS cassandra-driver, which does the heavy lifting with the CQL protocol. Its purpose is to help build CQL query strings based on config objects.
var merge = require('xtend/immutable');
var CassandraTable = require('osh-cassandra').Table;
var CassandraClient = require('cassandra-driver').Client;
// First define your POJO model using the POD scheme. Add a
// "storage" attribute to each POD to tell the CassandraTable
// mixin how and if it should store the thing.
var UserModel = {
attrs: {
username: {
validate: function(username) {
if (!/^[a-z]+$/.test(username)) {
return 'Must be a-z';
}
},
storage: {
cassandra: 'ascii',
pg: 'varchar(32)'
}
}
},
key: ['username']
};
// Now imbue it with Cassandra creation, storage, and retrieval.
var UserTable = merge(UserModel, CassandraTable);
UserTable.client = new CassandraClient({ /* driver options */ });
UserTable.create(function(err) {});
UserTable.drop(function(err) {});
UserTable.insert({ /* opts */ }, function(err) {});
UserTable.select({ /* opts */ }, function(err) {});
opts
Object, required
opts.where
String, requiredopts.consistency
callback
Function(err, results), requiredFirst, follow the instructions here to start a Cassandra instance in VirtualBox:
FAQs
openscihub.org: lightweight cassandra-driver wrapper
We found that osh-cassandra 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
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.