From 1e9d193a6daeb964187537565c4e046cb604066f Mon Sep 17 00:00:00 2001 From: Shreya Malviya Date: Wed, 13 Jul 2022 18:54:13 +0530 Subject: [PATCH] UI: Clear configured credentials on Island reset --- .../cc/ui/src/components/ui-components/IslandResetModal.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/monkey/monkey_island/cc/ui/src/components/ui-components/IslandResetModal.tsx b/monkey/monkey_island/cc/ui/src/components/ui-components/IslandResetModal.tsx index 5b3db45eb..c744c869a 100644 --- a/monkey/monkey_island/cc/ui/src/components/ui-components/IslandResetModal.tsx +++ b/monkey/monkey_island/cc/ui/src/components/ui-components/IslandResetModal.tsx @@ -107,6 +107,10 @@ const IslandResetModal = (props: Props) => { if (res.status === 200) { return auth.authFetch('/api/clear-simulation-data', {method: 'POST'}) }}) + .then(res => { + if (res.status === 200) { + return auth.authFetch('/api/propagation-credentials/configured-credentials', {method: 'DELETE'}) + }}) .then(res => { if (res.status === 200) { return auth.authFetch('/api/island-mode', {method: 'POST', body: '{"mode": "unset"}'})