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.
@clocklimited/validity-validate-if-property-set
Advanced tools
validate the current property if another property is set
Validate the current property if another property is set.
E.g you have a URL property of a schema, which is not a required field. You only want to apply validation to that field if another field has a value.
npm install validity-validate-if-property-set --save
Below is a simple example for usage with schemata and save:
var validity = require("@clocklimited/validity"),
schemata = require("schemata"),
save = require("save"),
collection = save("author"),
validateIfPropertySet = require("@clocklimited/validity-validate-if-property-set");
var schema = schemata({
useLink: { type: Boolean },
url: {
type: String,
validators: { all: [validateIfPropertySet("useLink", validity.url)] },
},
});
FAQs
validate the current property if another property is set
The npm package @clocklimited/validity-validate-if-property-set receives a total of 52 weekly downloads. As such, @clocklimited/validity-validate-if-property-set popularity was classified as not popular.
We found that @clocklimited/validity-validate-if-property-set demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 7 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’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.