Rename editor-manual to manual

There is a defined list of of valid origin values for the provenance.
This does not include `editor`, so to make sure all values are valid we
use `manual` instead.

See ac1df4de91/java/ql/lib/semmle/code/java/dataflow/internal/FlowSummaryImpl.qll (L221-L229)
This commit is contained in:
Koen Vlaswinkel
2023-05-16 10:23:21 +02:00
parent dc3966e113
commit 7d41cd7ae6
4 changed files with 4 additions and 6 deletions

View File

@@ -11,7 +11,7 @@ export type Provenance =
// Generated by the dataflow model and manually edited // Generated by the dataflow model and manually edited
| "df-manual" | "df-manual"
// Entered by the user in the editor manually // Entered by the user in the editor manually
| "editor-manual"; | "manual";
export type ModeledMethod = { export type ModeledMethod = {
type: ModeledMethodType; type: ModeledMethodType;

View File

@@ -224,7 +224,7 @@ DataExtensionsEditor.args = {
input: "Argument[this]", input: "Argument[this]",
output: "ReturnValue", output: "ReturnValue",
kind: "taint", kind: "taint",
provenance: "editor-manual", provenance: "manual",
}, },
"org.sql2o.Query#executeScalar(Class)": { "org.sql2o.Query#executeScalar(Class)": {
type: "neutral", type: "neutral",

View File

@@ -50,6 +50,6 @@ MethodRow.args = {
input: "Argument[this]", input: "Argument[this]",
output: "ReturnValue", output: "ReturnValue",
kind: "taint", kind: "taint",
provenance: "editor-manual", provenance: "manual",
}, },
}; };

View File

@@ -71,9 +71,7 @@ export const MethodRow = ({
...modeledMethod, ...modeledMethod,
type: target.value as ModeledMethodType, type: target.value as ModeledMethodType,
provenance: provenance:
modeledMethod?.provenance === "df-generated" modeledMethod?.provenance === "df-generated" ? "df-manual" : "manual",
? "df-manual"
: "editor-manual",
}); });
}, },
[onChange, externalApiUsage, modeledMethod, argumentsList], [onChange, externalApiUsage, modeledMethod, argumentsList],