Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
odata-parser
Advanced tools
OData query string parser for node.js based on pegjs.
npm install odata-parser
var parser = require("odata-parser");
var ast = parser.parse("$top=10&$skip=5&$select=foo")
util.inspect(ast)
will result in:
{
'$top': 10,
'$skip': 5,
'$select': [ 'foo' ]
}
Filters like:
parser.parse("$filter=Name eq 'John' and LastName lt 'Doe'")
results in:
{
$filter: {
type: 'and',
left: {
type: 'eq',
left: {
type: 'property',
name: 'Name'
},
right: {
type: 'literal',
value: 'John'
}
},
right: {
type: 'lt',
left: {
type: 'property',
name: 'LastName'
},
right: {
type: 'literal',
value: 'Doe'
}
}
}
}
Using functions in filters
parser.parse("$filter=substringof('nginx', Servers)")
restuls in:
{
$filter: {
type: 'functioncall',
func: 'substringof',
args: [{
type: 'literal',
value: 'nginx'
}, {
type: 'property',
name: 'Servers'
}]
}
}
If you have found a bug or if you have a feature request, please report them at this repository issues section. Please do not report security vulnerabilities on the public GitHub issue tracker. The Responsible Disclosure Program details the procedure for disclosing security issues.
This project is licensed under the MIT license. See the LICENSE file for more info.
FAQs
OData query string parser
The npm package odata-parser receives a total of 11,295 weekly downloads. As such, odata-parser popularity was classified as popular.
We found that odata-parser 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
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.