Unsafe fall-through in getWhereConditions
Impact
Providing an invalid value to the where option of a query caused Sequelize to ignore that option instead of throwing an error.
A finder call like the following did not throw an error:
``ts
User.findAll({
where: new Date(),
});
`
As this option is typically used with plain javascript objects, be aware that this only happens at the top level of this option.
Patches
This issue has been patched in sequelize@6.28.1` &
Sequelize - Default support for “raw attributes” when using parentheses
Impact
Sequelize 6.28.2 and prior has a dangerous feature where using parentheses in the attribute option would make Sequelize use the string as-is in the SQL
``ts
User.findAll({
attributes: [
['count(id)', 'count']
]
});
`
Produced
`sql
SELECT count(id) AS "count" FROM "users"
`
Patches
This feature was deprecated in Sequelize 5, and using it prints a deprecation warning.
This issue has been patched in [@sequelize/core@7.0.0.alpha-20`](https://github.com/sequelize
automattic/mongoose vulnerable to Prototype pollution via Schema.path
Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. Affected versions of this package are vulnerable to Prototype Pollution. The Schema.path() function is vulnerable to prototype pollution when setting the schema object. This vulnerability allows modification of the Object prototype and could be manipulated into a Denial of Service (DoS) attack.
Mongoose Vulnerable to Prototype Pollution in Schema Object
Description
Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment.
Affected versions of this package are vulnerable to Prototype Pollution. The Schema.path() function is vulnerable to prototype pollution when setting the schema object. This vulnerability allows modification of the Object prototype and could be manipulated into a Denial of Service (DoS) attack.
Proof of Concept
```js
// poc.js
const mongoose = require('mongoose');
const schema =
jsonwebtoken unrestricted key type could lead to legacy keys usage
Overview
Versions <=8.5.1 of jsonwebtoken library could be misconfigured so that legacy, insecure key types are used for signature verification. For example, DSA keys could be used with the RS256 algorithm.
Am I affected?
You are affected if you are using an algorithm and a key type other than the combinations mentioned below
| Key type | algorithm |
|----------|------------------------------------------|
| ec | ES256, ES384, ES512
Command Injection in lodash
lodash versions prior to 4.17.21 are vulnerable to Command Injection via the template function.