From 5f5e86c2b2bb614b9654b9cb62b4e33238b05e4c Mon Sep 17 00:00:00 2001 From: tombolton Date: Thu, 12 May 2022 11:09:02 +0100 Subject: [PATCH] add XssThroughDom and CodeInjection to Queries.qll --- .../modelbuilding/extraction/Queries.qll | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/javascript/ql/experimental/adaptivethreatmodeling/modelbuilding/extraction/Queries.qll b/javascript/ql/experimental/adaptivethreatmodeling/modelbuilding/extraction/Queries.qll index 51dd3ffec84..6bbd7ec7804 100644 --- a/javascript/ql/experimental/adaptivethreatmodeling/modelbuilding/extraction/Queries.qll +++ b/javascript/ql/experimental/adaptivethreatmodeling/modelbuilding/extraction/Queries.qll @@ -5,10 +5,12 @@ */ newtype TQuery = + TCodeInjectionQuery() or TNosqlInjectionQuery() or TSqlInjectionQuery() or TTaintedPathQuery() or - TXssQuery() + TXssQuery() or + TXssThroughDomQuery() abstract class Query extends TQuery { abstract string getName(); @@ -16,6 +18,10 @@ abstract class Query extends TQuery { string toString() { result = getName() } } +class CodeInjectionQuery extends Query, TCodeInjectionQuery { + override string getName() { result = "CodeInjection" } +} + class NosqlInjectionQuery extends Query, TNosqlInjectionQuery { override string getName() { result = "NosqlInjection" } } @@ -31,3 +37,7 @@ class TaintedPathQuery extends Query, TTaintedPathQuery { class XssQuery extends Query, TXssQuery { override string getName() { result = "Xss" } } + +class XssThroughDomQuery extends Query, TXssThroughDomQuery { + override string getName() { result = "XssThroughDom" } +}