Skip to content

Commit

Permalink
updating missing hasura permissions
Browse files Browse the repository at this point in the history
  • Loading branch information
its-a-feature committed Oct 28, 2024
1 parent 767f82a commit e8737b4
Show file tree
Hide file tree
Showing 3 changed files with 211 additions and 75 deletions.
53 changes: 53 additions & 0 deletions hasura-docker/metadata/metadata/actions.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ type Mutation {
c2_id: Int!
file_uuid: String!
host_url: String!
alert_on_download: Boolean
remove: Boolean
): c2HostFileOutput
}

Expand Down Expand Up @@ -149,6 +151,7 @@ type Mutation {
type Mutation {
createTask(
command: String!
payload_type: String
params: String!
files: [String]
callback_id: Int
Expand Down Expand Up @@ -230,6 +233,12 @@ type Mutation {
): dynamicQueryOutput
}

type Query {
eventingTestFile(
file_contents: String!
): eventingTestFileOutput
}

type Mutation {
eventingTriggerCancel(
eventgroupinstance_id: Int!
Expand All @@ -255,6 +264,13 @@ type Mutation {
): eventingTriggerRetryOutput
}

type Mutation {
eventingTriggerRetryFromStep(
eventstepinstance_id: Int!
retry_all_groups: Boolean
): eventingTriggerRetryFromStepOutput
}

type Mutation {
eventingTriggerRunAgain(
eventgroupinstance_id: Int!
Expand Down Expand Up @@ -387,6 +403,12 @@ type Mutation {
): startStopOutput
}

type Mutation {
testProxy(
callbackport_id: Int!
): testProxyOutput
}

type Mutation {
toggleProxy(
callbackport_id: Int!
Expand Down Expand Up @@ -439,6 +461,8 @@ type Mutation {
webhook: String
admin_id: Int
deleted: Boolean
banner_text: String
banner_color: String
): updateOperationOutput
}

Expand Down Expand Up @@ -481,6 +505,7 @@ type Mutation {
input OperatorInput {
username: String!
password: String
email: String
bot: Boolean
}

Expand Down Expand Up @@ -556,6 +581,7 @@ type createAPITokenResponse {
operator_id: Int
name: String
created_by: Int
token_type: String
}

type OperatorOutput {
Expand All @@ -575,6 +601,7 @@ type OperatorOutput {
failed_login_count: Int
last_failed_login_timestamp: String
account_type: String
email: String
}

type createPayloadOutput {
Expand Down Expand Up @@ -715,6 +742,10 @@ type updateCurrentOperationOutput {
status: String!
error: String
operation_id: Int
name: String
complete: Boolean
banner_text: String
banner_color: String
}

type deleteBlockListOutput {
Expand Down Expand Up @@ -745,6 +776,10 @@ type generateReportOutput {
type previewFileOutput {
status: String!
error: String
size: Int
host: String
full_remote_path: String
filename: String
contents: String
}

Expand Down Expand Up @@ -845,6 +880,8 @@ type updateOperationOutput {
webhook: String
admin_id: Int
deleted: Boolean
banner_text: String
banner_color: String
id: Int
}

Expand Down Expand Up @@ -924,6 +961,7 @@ type globalSettingsOutput {
type exportCallbackConfigOutput {
status: String!
error: String
agent_callback_id: String
config: String
}

Expand Down Expand Up @@ -1036,3 +1074,18 @@ type containerWriteFileOutput {
version: String
}

type eventingTriggerRetryFromStepOutput {
status: String!
error: String
}

type testProxyOutput {
status: String!
error: String
}

type eventingTestFileOutput {
status: String!
error: String
}

33 changes: 33 additions & 0 deletions hasura-docker/metadata/metadata/actions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,16 @@ actions:
- role: operation_admin
- role: mythic_admin
- role: developer
- name: eventingTestFile
definition:
kind: ""
handler: '{{MYTHIC_ACTIONS_URL_BASE}}/eventing_test_file_webhook'
forward_client_headers: true
permissions:
- role: operator
- role: operation_admin
- role: mythic_admin
- role: developer
- name: eventingTriggerCancel
definition:
kind: synchronous
Expand Down Expand Up @@ -371,6 +381,16 @@ actions:
- role: operation_admin
- role: mythic_admin
- role: developer
- name: eventingTriggerRetryFromStep
definition:
kind: synchronous
handler: '{{MYTHIC_ACTIONS_URL_BASE}}/eventing_trigger_retry_from_step_webhook'
forward_client_headers: true
permissions:
- role: operator
- role: operation_admin
- role: mythic_admin
- role: developer
- name: eventingTriggerRunAgain
definition:
kind: synchronous
Expand Down Expand Up @@ -585,6 +605,16 @@ actions:
- role: mythic_admin
- role: operation_admin
- role: operator
- name: testProxy
definition:
kind: synchronous
handler: '{{MYTHIC_ACTIONS_URL_BASE}}/test_proxy_webhook'
forward_client_headers: true
permissions:
- role: operator
- role: operation_admin
- role: mythic_admin
- role: developer
- name: toggleProxy
definition:
kind: synchronous
Expand Down Expand Up @@ -809,4 +839,7 @@ custom_types:
- name: containerListFilesOutput
- name: containerUploadFileOutput
- name: containerWriteFileOutput
- name: eventingTriggerRetryFromStepOutput
- name: testProxyOutput
- name: eventingTestFileOutput
scalars: []
Loading

0 comments on commit e8737b4

Please sign in to comment.