You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Provides classes modeling the `Node Redis` library.
743
+
*
744
+
* Redis is an in-memory key-value store and not a database,
745
+
* but `Node Redis` can be exploited similarly to a NoSQL database by giving a method an array as argument instead of a string.
746
+
* As an example the below two invocations of `client.set` are equivalent:
747
+
*
748
+
* ```
749
+
* const redis = require("redis");
750
+
* const client = redis.createClient();
751
+
* client.set("key", "value");
752
+
* client.set(["key", "value"]);
753
+
* ```
754
+
*
755
+
* ioredis is a very similar library. However, ioredis does not support array arguments in the same way, and is therefore not vulnerable to the same kind of type confusion.
* Provides signatures for the query methods from Node Redis.
788
+
*/
789
+
module QuerySignatures {
790
+
/**
791
+
* Holds if `method` interprets parameter `argIndex` as a key, and a later parameter determines a value/field.
792
+
* Thereby the method is vulnerable if parameter `argIndex` is unexpectedly an array instead of a string, as an attacker can control arguments to Redis that the attacker was not supposed to control.
793
+
*
794
+
* Only setters and similar methods are included.
795
+
* For getter-like methods it is not generally possible to gain access "outside" of where you are supposed to have access,
796
+
* it is at most possible to get a Redis call to return more results than expected (e.g. by adding more members to [`geohash`](https://redis.io/commands/geohash)).
0 commit comments