From e0a536c7323ead7bb4004e580ceab890127e1d0a Mon Sep 17 00:00:00 2001 From: George Pollard Date: Thu, 2 Feb 2023 23:27:39 +0000 Subject: [PATCH] Server side changes --- .../ApiService/OneFuzzTypes/Enums.cs | 1 + src/ApiService/ApiService/onefuzzlib/Defs.cs | 27 ++++++++++++------- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/src/ApiService/ApiService/OneFuzzTypes/Enums.cs b/src/ApiService/ApiService/OneFuzzTypes/Enums.cs index d0498cdbe03..e8b2358273f 100644 --- a/src/ApiService/ApiService/OneFuzzTypes/Enums.cs +++ b/src/ApiService/ApiService/OneFuzzTypes/Enums.cs @@ -89,6 +89,7 @@ public enum ContainerType { Analysis, Coverage, Crashes, + CrashDumps, Inputs, NoRepro, ReadonlyInputs, diff --git a/src/ApiService/ApiService/onefuzzlib/Defs.cs b/src/ApiService/ApiService/onefuzzlib/Defs.cs index b1692094f49..327af4c9f0e 100644 --- a/src/ApiService/ApiService/onefuzzlib/Defs.cs +++ b/src/ApiService/ApiService/onefuzzlib/Defs.cs @@ -1,7 +1,6 @@ namespace Microsoft.OneFuzz.Service; public static class Defs { - public static readonly IReadOnlyDictionary TASK_DEFINITIONS = new Dictionary() { { TaskType.Coverage , new TaskDefinition( @@ -162,6 +161,12 @@ public static class Defs { Value:1, Permissions: ContainerPermission.Write ), + new ContainerDefinition( + Type:ContainerType.CrashDumps, + Compare: Compare.Equal, + Value:1, + Permissions: ContainerPermission.Write + ), new ContainerDefinition( Type: ContainerType.Inputs, Compare: Compare.Equal, @@ -234,19 +239,23 @@ public static class Defs { Vm: new VmDefinition(Compare: Compare.AtLeast, Value: 1), Containers: new[] { new ContainerDefinition( - Type:ContainerType.Setup, + Type: ContainerType.Setup, Compare: Compare.Equal, - Value:1, + Value: 1, Permissions: ContainerPermission.Read | ContainerPermission.List ), new ContainerDefinition( - Type:ContainerType.Crashes, + Type: ContainerType.Crashes, Compare: Compare.Equal, - Value:1, + Value: 1, Permissions: ContainerPermission.Write - - - ), + ), + new ContainerDefinition( + Type: ContainerType.CrashDumps, + Compare: Compare.Equal, + Value: 1, + Permissions: ContainerPermission.Write + ), new ContainerDefinition( Type: ContainerType.Inputs, Compare: Compare.Equal, @@ -407,8 +416,6 @@ public static class Defs { Compare: Compare.Equal, Value:1, Permissions: ContainerPermission.Write - - ), new ContainerDefinition( Type: ContainerType.Inputs,