From 25e788578fcdf5f87bbe3a3b16153ecadab30732 Mon Sep 17 00:00:00 2001 From: Sina Date: Tue, 6 Aug 2024 18:18:52 +0200 Subject: [PATCH] [fix] Azure or other cloud Resources (#288) --- src/locales/de-DE/messages.po | 138 ++++++++++-------- src/locales/en-US/messages.po | 138 ++++++++++-------- .../inventory-form/InventoryForm.tsx | 5 +- .../resource-detail/ResourceDetailView.tsx | 90 +++++++----- src/pages/panel/security/AccountCard.tsx | 3 +- .../WorkspaceSettingsAccountRow.tsx | 3 +- src/shared/cloud-avatar/CloudAvatar.tsx | 18 +-- src/shared/event-button/EventButton.tsx | 11 +- src/shared/link-button/ExternalLinkButton.tsx | 19 +++ src/shared/link-button/index.ts | 1 + src/shared/utils/getAccountCloudName.ts | 16 ++ 11 files changed, 257 insertions(+), 185 deletions(-) create mode 100644 src/shared/link-button/ExternalLinkButton.tsx create mode 100644 src/shared/utils/getAccountCloudName.ts diff --git a/src/locales/de-DE/messages.po b/src/locales/de-DE/messages.po index 70478f37..ce4c6198 100644 --- a/src/locales/de-DE/messages.po +++ b/src/locales/de-DE/messages.po @@ -66,18 +66,18 @@ msgstr "" msgid "{0} ago" msgstr "" -#: src/shared/event-button/EventButton.tsx:57 -#: src/shared/event-button/EventButton.tsx:66 +#: src/shared/event-button/EventButton.tsx:58 +#: src/shared/event-button/EventButton.tsx:67 msgid "{0} Cloud account configured, id: {1}" msgstr "{0} Cloud-Konto konfiguriert, ID: {1}" -#: src/shared/event-button/EventButton.tsx:75 -#: src/shared/event-button/EventButton.tsx:84 +#: src/shared/event-button/EventButton.tsx:76 +#: src/shared/event-button/EventButton.tsx:85 msgid "{0} Cloud account degraded, id: {1}" msgstr "{0} Cloud-Konto beeinträchtigt, ID: {1}" -#: src/shared/event-button/EventButton.tsx:93 -#: src/shared/event-button/EventButton.tsx:99 +#: src/shared/event-button/EventButton.tsx:94 +#: src/shared/event-button/EventButton.tsx:102 msgid "{0} Cloud account discovered, id: {1}" msgstr "{0} Cloud-Konto entdeckt, ID: {1}" @@ -225,14 +225,14 @@ msgstr "Akzeptieren" msgid "Access Control (IAM)" msgstr "" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:259 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:385 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:260 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:386 msgid "Access to your account is broken" msgstr "Der Zugriff auf Ihr Konto ist unterbrochen" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:195 #: src/pages/panel/inventory-search/inventory-form/InventoryFormAccount.tsx:65 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:241 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:257 msgid "Account" msgstr "Konto" @@ -334,7 +334,7 @@ msgstr "Erweiterte Suchabfrage" msgid "Affected resources" msgstr "" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:250 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:266 #: src/shared/charts/NetworkDiagram.tsx:378 msgid "Age" msgstr "Alter" @@ -441,7 +441,7 @@ msgid "Are you sure you want to remove the {name} account {0}?" msgstr "Sind Sie sicher, dass Sie das {name}-Konto {0} entfernen möchten?" #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:52 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:454 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:455 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:85 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRow.tsx:107 msgid "Are you sure?" @@ -486,7 +486,7 @@ msgstr "" msgid "Back" msgstr "" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:226 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:242 msgid "Basic Information" msgstr "Grundinformation" @@ -545,10 +545,10 @@ msgstr "Business" #: src/pages/panel/user-settings/UserSettingsSocialNetworkDeleteButton.tsx:68 #: src/pages/panel/user-settings/UserSettingsTotpActivationModal.tsx:121 #: src/pages/panel/user-settings/UserSettingsTotpDeactivationModal.tsx:49 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:305 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:309 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:306 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:310 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:473 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:311 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:474 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:92 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:154 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:158 @@ -563,7 +563,7 @@ msgstr "Business" msgid "Cancel" msgstr "Stornieren" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:500 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:501 msgid "Cannot enable this account" msgstr "" @@ -690,16 +690,16 @@ msgstr "" #: src/pages/panel/user-settings/UserSettingsApiTokensAddToken.tsx:84 #: src/pages/panel/user-settings/UserSettingsTotpRecoveryCodesModal.tsx:36 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:391 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:392 msgid "Close" msgstr "Schließen" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:165 #: src/pages/panel/inventory-search/inventory-form/InventoryFormCloudValues.tsx:62 #: src/pages/panel/inventory-search/inventory-form/InventoryFormMore.tsx:96 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:237 -#: src/pages/panel/security/AccountCard.tsx:37 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:493 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:253 +#: src/pages/panel/security/AccountCard.tsx:38 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:494 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountsTableItem.tsx:59 msgid "Cloud" msgstr "Cloud" @@ -761,7 +761,7 @@ msgstr "Konfiguration geändert" msgid "Configure" msgstr "Konfigurieren" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:403 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:404 msgid "Configure Service Principal" msgstr "" @@ -787,7 +787,7 @@ msgstr "Herzlichen Glückwunsch zu Ihrem Abonnement" msgid "Connect" msgstr "Verbinden" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:401 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:402 msgid "Connect GCP Service Account" msgstr "" @@ -877,7 +877,7 @@ msgstr "" msgid "Created in the last 7 days" msgstr "" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:244 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:260 msgid "Created Time" msgstr "Erstellte Zeit" @@ -956,10 +956,10 @@ msgstr "Verzögerte Wirkung" #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:45 #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:86 #: src/pages/panel/user-settings/UserSettingsSocialNetworkDeleteButton.tsx:79 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:372 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:376 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:373 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:377 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:484 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:378 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:485 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:73 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:77 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:78 @@ -985,7 +985,7 @@ msgstr "" #: src/pages/panel/shared/setup-cloud-button/SetupCloudButton.tsx:13 #: src/pages/panel/shared/setup-cloud-button/SetupCloudButton.tsx:29 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:399 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:400 msgid "Deploy Stack" msgstr "Deploy Stack" @@ -1003,7 +1003,7 @@ msgstr "Für die Organisation bereitstellen" msgid "Description" msgstr "Beschreibung" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:322 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:346 msgid "Details" msgstr "Einzelheiten" @@ -1037,7 +1037,7 @@ msgstr "Zeig es mir nicht noch einmal" msgid "Do not show this message again." msgstr "" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:457 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:458 msgid "Do you want to delete this account?" msgstr "Möchten Sie dieses Konto löschen?" @@ -1080,8 +1080,8 @@ msgstr "" msgid "Drop Service Account Key File" msgstr "" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:321 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:322 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:323 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:175 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:176 msgid "Edit" @@ -1132,7 +1132,7 @@ msgstr "" msgid "Enterprise" msgstr "Unternehmen" -#: src/shared/event-button/EventButton.tsx:135 +#: src/shared/event-button/EventButton.tsx:138 msgid "Events" msgstr "Veranstaltungen" @@ -1312,9 +1312,9 @@ msgstr "" msgid "Id" msgstr "" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:234 -#: src/pages/panel/security/AccountCard.tsx:34 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:490 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:250 +#: src/pages/panel/security/AccountCard.tsx:35 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:491 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountsTableItem.tsx:62 #: src/shared/charts/NetworkDiagram.tsx:376 msgid "ID" @@ -1373,6 +1373,18 @@ msgstr "Verbessert" msgid "in account" msgstr "" +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:124 +msgid "in AWS Console" +msgstr "" + +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:126 +msgid "in Azure Portal" +msgstr "" + +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:128 +msgid "in Google Cloud Console" +msgstr "" + #: src/pages/panel/workspace-settings-accounts-setup-cloud-azure/getInstructions.tsx:73 msgid "In the Azure console search, type App Registrations and go to App Registrations page." msgstr "" @@ -1457,7 +1469,7 @@ msgid "kind" msgstr "" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:189 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:233 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:249 #: src/shared/charts/NetworkDiagram.tsx:375 msgid "Kind" msgstr "Art" @@ -1576,9 +1588,9 @@ msgid "Most Non-Compliant Accounts" msgstr "Die meisten nicht konformen Konten" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:177 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:235 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:251 #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:92 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:496 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:497 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountsTableItem.tsx:65 #: src/pages/panel/workspace-settings-external-directory/AddExternalDirectory.tsx:42 #: src/pages/panel/workspace-settings-external-directory/AddExternalDirectory.tsx:46 @@ -1595,7 +1607,7 @@ msgstr "Die meisten nicht konformen Konten" msgid "Name" msgstr "Name" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:214 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:230 msgid "Neighborhood View" msgstr "Nachbarschaftsansicht" @@ -1663,7 +1675,7 @@ msgstr "" msgid "Non-Compliant Resources" msgstr "" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:460 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:461 msgid "Note: You are about to delete a management or delegated admin account. Please be aware that once deleted, we will no longer have the capability to retrieve any account names, requiring you to edit them manually." msgstr "Sie löschen gerade ein Management- oder delegiertes Admin-Konto. Beachten Sie bitte, dass wir nach der Löschung nicht mehr in der Lage sein werden, Kontonamen abzurufen, wodurch Sie diese manuell bearbeiten müssen." @@ -1701,7 +1713,7 @@ msgid "Objects" msgstr "" #: src/core/auth/WorkspaceGuard.tsx:94 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:504 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:505 msgid "Ok" msgstr "" @@ -1766,10 +1778,6 @@ msgstr "Öffnen Sie den Datenbankzugriff" msgid "Open drawer" msgstr "Öffene die Schublade" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:259 -msgid "Open resource {name} in AWS Console" -msgstr "Öffnen Sie die Ressource {name} in der AWS-Konsole" - #: src/pages/panel/workspace-settings-accounts-setup-cloud-azure/getInstructions.tsx:109 msgid "Open the Manage section and go to the App permissions page:" msgstr "" @@ -1915,11 +1923,11 @@ msgstr "" msgid "Print or copy the following recovery codes" msgstr "Drucken oder kopieren Sie die folgenden Wiederherstellungscodes" -#: src/shared/cloud-avatar/CloudAvatar.tsx:64 +#: src/shared/cloud-avatar/CloudAvatar.tsx:50 msgid "Privileged" msgstr "Privilegiert" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:254 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:255 msgid "Privileged account" msgstr "Privilegiertes Konto" @@ -1991,7 +1999,7 @@ msgstr "Regenerieren" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:183 #: src/pages/panel/inventory-search/inventory-form/InventoryFormMore.tsx:97 #: src/pages/panel/inventory-search/inventory-form/InventoryFormRegionValues.tsx:60 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:242 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:258 msgid "Region" msgstr "Region" @@ -2182,10 +2190,12 @@ msgstr "Sicherheitsbewertung" msgid "Security Score over all {accountCounts} cloud accounts" msgstr "" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:270 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:281 -msgid "See this Resource in AWS Console" -msgstr "Sehen Sie sich diese Ressource in der AWS-Konsole an" +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:276 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:287 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:300 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:305 +msgid "See this resource {buttonName}" +msgstr "" #: src/pages/panel/inventory-search/inventory-form/InventoryFormChangePicker.tsx:166 msgid "Select All" @@ -2255,7 +2265,7 @@ msgstr "" msgid "Setting Up Email Notifications" msgstr "E-Mail-Benachrichtigungen einrichten" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:405 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:406 msgid "Setup cloud" msgstr "" @@ -2295,7 +2305,7 @@ msgstr "" msgid "Some checks have been disabled for this resource" msgstr "Einige Prüfungen wurden für diese Ressource deaktiviert" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:297 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:321 #: src/pages/panel/user-settings/UserSettingsFormEmail.tsx:33 #: src/pages/panel/user-settings/UserSettingsFormPassword.tsx:23 #: src/pages/panel/user-settings/UserSettingsTotpActivationModal.tsx:107 @@ -2322,9 +2332,9 @@ msgid "Submission Error" msgstr "" #: src/pages/panel/workspace-settings-accounts-setup-cloud-azure/WorkspaceSettingsAccountsSetupCloudAzurePage.tsx:17 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:294 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:295 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:300 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:296 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:301 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:147 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:148 msgid "Submit" @@ -2339,7 +2349,7 @@ msgid "Successfully invited {email}" msgstr "{email} erfolgreich eingeladen" #: src/pages/panel/inventory-search/inventory-form/InventoryFormMore.tsx:98 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:307 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:331 msgid "Tags" msgstr "Stichworte" @@ -2376,7 +2386,7 @@ msgstr "" msgid "The OTP or recovery code you entered is incorrect or the OTP has expired. Please try entering it again." msgstr "Das von Ihnen eingegebene OTP oder Wiederherstellungscode ist falsch oder das OTP ist abgelaufen. Bitte versuchen Sie es erneut einzugeben." -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:295 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:319 msgid "The selected resource does not exist anymore." msgstr "Die ausgewählte Ressource existiert nicht mehr." @@ -2400,11 +2410,11 @@ msgstr "" msgid "There's no account configured for this workspace." msgstr "Für diesen Arbeitsbereich ist kein Konto konfiguriert." -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:445 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:446 msgid "This account is currently in a degraded state possibly due to a misconfiguration.<0/>Fix was unable to gather data from this account." msgstr "" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:413 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:414 msgid "This account is currently in a degraded state.<0/>Fix was unable to gather data from this account.<1/><2/>To resume security scans, please log into the {accountName} account ({0}) and re-deploy the CloudFormation stack that establishes the IAM role trust." msgstr "" @@ -2412,7 +2422,7 @@ msgstr "" msgid "This email address is already registered. If this is your email, please try logging in or click on forgot password in login page to reset your password." msgstr "Diese Email-Adresse ist bereits registriert. Wenn dies Ihre E-Mail-Adresse ist, versuchen Sie bitte, sich anzumelden, oder klicken Sie auf der Anmeldeseite auf „Passwort vergessen“, um Ihr Passwort zurückzusetzen." -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:423 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:424 msgid "This project is currently in a degraded state.<0/>Fix was unable to gather data from this project.<1/><2/>To resume security scans, please ensure that the service account you configured is set up correctly.<3/>You may also recreate and upload the service account definition." msgstr "" @@ -2420,7 +2430,7 @@ msgstr "" msgid "This section does not contain any controls that can be automated.<0/>Manual checks or processes are required for compliance." msgstr "" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:434 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:435 msgid "This subscription is currently in a degraded state.<0/>Fix was unable to gather data from this subscription.<1/><2/>To resume security scans, please ensure that the application permissions are set up correctly.<3/>You may also recreate and redefine the access credentials." msgstr "" @@ -2436,9 +2446,9 @@ msgstr "Drei" msgid "Tier" msgstr "Stufe" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:276 -msgid "To access this resource, please ensure that you are logged into the AWS account: {account}" -msgstr "Um auf diese Ressource zuzugreifen, stellen Sie bitte sicher, dass Sie beim AWS-Konto angemeldet sind: {account}" +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:293 +msgid "To access this resource, please ensure that you are logged into the {cloudName} account: {account}" +msgstr "" #: src/pages/panel/workspace-settings-billing/ChangePaymentNoMethodModal.tsx:58 #: src/pages/panel/workspace-settings-billing/ChangeProductTierModal.tsx:137 diff --git a/src/locales/en-US/messages.po b/src/locales/en-US/messages.po index 0130e241..f7d867af 100644 --- a/src/locales/en-US/messages.po +++ b/src/locales/en-US/messages.po @@ -66,18 +66,18 @@ msgstr "{0}" msgid "{0} ago" msgstr "{0} ago" -#: src/shared/event-button/EventButton.tsx:57 -#: src/shared/event-button/EventButton.tsx:66 +#: src/shared/event-button/EventButton.tsx:58 +#: src/shared/event-button/EventButton.tsx:67 msgid "{0} Cloud account configured, id: {1}" msgstr "{0} Cloud account configured, id: {1}" -#: src/shared/event-button/EventButton.tsx:75 -#: src/shared/event-button/EventButton.tsx:84 +#: src/shared/event-button/EventButton.tsx:76 +#: src/shared/event-button/EventButton.tsx:85 msgid "{0} Cloud account degraded, id: {1}" msgstr "{0} Cloud account degraded, id: {1}" -#: src/shared/event-button/EventButton.tsx:93 -#: src/shared/event-button/EventButton.tsx:99 +#: src/shared/event-button/EventButton.tsx:94 +#: src/shared/event-button/EventButton.tsx:102 msgid "{0} Cloud account discovered, id: {1}" msgstr "{0} Cloud account discovered, id: {1}" @@ -225,14 +225,14 @@ msgstr "Accept" msgid "Access Control (IAM)" msgstr "Access Control (IAM)" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:259 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:385 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:260 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:386 msgid "Access to your account is broken" msgstr "Access to your account is broken" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:195 #: src/pages/panel/inventory-search/inventory-form/InventoryFormAccount.tsx:65 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:241 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:257 msgid "Account" msgstr "Account" @@ -334,7 +334,7 @@ msgstr "Advanced search query" msgid "Affected resources" msgstr "Affected resources" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:250 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:266 #: src/shared/charts/NetworkDiagram.tsx:378 msgid "Age" msgstr "Age" @@ -441,7 +441,7 @@ msgid "Are you sure you want to remove the {name} account {0}?" msgstr "Are you sure you want to remove the {name} account {0}?" #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:52 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:454 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:455 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:85 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRow.tsx:107 msgid "Are you sure?" @@ -486,7 +486,7 @@ msgstr "Azure Service Management" msgid "Back" msgstr "Back" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:226 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:242 msgid "Basic Information" msgstr "Basic Information" @@ -545,10 +545,10 @@ msgstr "Business" #: src/pages/panel/user-settings/UserSettingsSocialNetworkDeleteButton.tsx:68 #: src/pages/panel/user-settings/UserSettingsTotpActivationModal.tsx:121 #: src/pages/panel/user-settings/UserSettingsTotpDeactivationModal.tsx:49 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:305 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:309 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:306 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:310 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:473 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:311 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:474 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:92 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:154 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:158 @@ -563,7 +563,7 @@ msgstr "Business" msgid "Cancel" msgstr "Cancel" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:500 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:501 msgid "Cannot enable this account" msgstr "Cannot enable this account" @@ -690,16 +690,16 @@ msgstr "Client secret" #: src/pages/panel/user-settings/UserSettingsApiTokensAddToken.tsx:84 #: src/pages/panel/user-settings/UserSettingsTotpRecoveryCodesModal.tsx:36 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:391 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:392 msgid "Close" msgstr "Close" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:165 #: src/pages/panel/inventory-search/inventory-form/InventoryFormCloudValues.tsx:62 #: src/pages/panel/inventory-search/inventory-form/InventoryFormMore.tsx:96 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:237 -#: src/pages/panel/security/AccountCard.tsx:37 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:493 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:253 +#: src/pages/panel/security/AccountCard.tsx:38 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:494 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountsTableItem.tsx:59 msgid "Cloud" msgstr "Cloud" @@ -761,7 +761,7 @@ msgstr "Configuration changed" msgid "Configure" msgstr "Configure" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:403 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:404 msgid "Configure Service Principal" msgstr "Configure Service Principal" @@ -787,7 +787,7 @@ msgstr "Congratulations on your subscription" msgid "Connect" msgstr "Connect" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:401 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:402 msgid "Connect GCP Service Account" msgstr "Connect GCP Service Account" @@ -877,7 +877,7 @@ msgstr "Created At" msgid "Created in the last 7 days" msgstr "Created in the last 7 days" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:244 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:260 msgid "Created Time" msgstr "Created Time" @@ -956,10 +956,10 @@ msgstr "Delayed Effect" #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:45 #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:86 #: src/pages/panel/user-settings/UserSettingsSocialNetworkDeleteButton.tsx:79 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:372 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:376 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:373 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:377 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:484 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:378 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:485 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:73 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:77 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserInvitationRow.tsx:78 @@ -985,7 +985,7 @@ msgstr "Deleted in the last 7 days" #: src/pages/panel/shared/setup-cloud-button/SetupCloudButton.tsx:13 #: src/pages/panel/shared/setup-cloud-button/SetupCloudButton.tsx:29 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:399 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:400 msgid "Deploy Stack" msgstr "Deploy Stack" @@ -1003,7 +1003,7 @@ msgstr "Deploy to organization" msgid "Description" msgstr "Description" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:322 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:346 msgid "Details" msgstr "Details" @@ -1037,7 +1037,7 @@ msgstr "Do not show me again" msgid "Do not show this message again." msgstr "Do not show this message again." -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:457 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:458 msgid "Do you want to delete this account?" msgstr "Do you want to delete this account?" @@ -1080,8 +1080,8 @@ msgstr "Drill Down" msgid "Drop Service Account Key File" msgstr "Drop Service Account Key File" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:321 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:322 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:323 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:175 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:176 msgid "Edit" @@ -1132,7 +1132,7 @@ msgstr "Enter the secret description and set the expiration date:" msgid "Enterprise" msgstr "Enterprise" -#: src/shared/event-button/EventButton.tsx:135 +#: src/shared/event-button/EventButton.tsx:138 msgid "Events" msgstr "Events" @@ -1312,9 +1312,9 @@ msgstr "IAM Role changes in the last 30 days." msgid "Id" msgstr "Id" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:234 -#: src/pages/panel/security/AccountCard.tsx:34 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:490 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:250 +#: src/pages/panel/security/AccountCard.tsx:35 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:491 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountsTableItem.tsx:62 #: src/shared/charts/NetworkDiagram.tsx:376 msgid "ID" @@ -1373,6 +1373,18 @@ msgstr "Improved" msgid "in account" msgstr "in account" +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:124 +msgid "in AWS Console" +msgstr "in AWS Console" + +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:126 +msgid "in Azure Portal" +msgstr "in Azure Portal" + +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:128 +msgid "in Google Cloud Console" +msgstr "in Google Cloud Console" + #: src/pages/panel/workspace-settings-accounts-setup-cloud-azure/getInstructions.tsx:73 msgid "In the Azure console search, type App Registrations and go to App Registrations page." msgstr "In the Azure console search, type App Registrations and go to App Registrations page." @@ -1457,7 +1469,7 @@ msgid "kind" msgstr "kind" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:189 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:233 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:249 #: src/shared/charts/NetworkDiagram.tsx:375 msgid "Kind" msgstr "Kind" @@ -1576,9 +1588,9 @@ msgid "Most Non-Compliant Accounts" msgstr "Most Non-Compliant Accounts" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:177 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:235 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:251 #: src/pages/panel/user-settings/UserSettingsApiTokensRow.tsx:92 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:496 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:497 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountsTableItem.tsx:65 #: src/pages/panel/workspace-settings-external-directory/AddExternalDirectory.tsx:42 #: src/pages/panel/workspace-settings-external-directory/AddExternalDirectory.tsx:46 @@ -1595,7 +1607,7 @@ msgstr "Most Non-Compliant Accounts" msgid "Name" msgstr "Name" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:214 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:230 msgid "Neighborhood View" msgstr "Neighborhood View" @@ -1663,7 +1675,7 @@ msgstr "No Thanks" msgid "Non-Compliant Resources" msgstr "Non-Compliant Resources" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:460 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:461 msgid "Note: You are about to delete a management or delegated admin account. Please be aware that once deleted, we will no longer have the capability to retrieve any account names, requiring you to edit them manually." msgstr "Note: You are about to delete a management or delegated admin account. Please be aware that once deleted, we will no longer have the capability to retrieve any account names, requiring you to edit them manually." @@ -1701,7 +1713,7 @@ msgid "Objects" msgstr "Objects" #: src/core/auth/WorkspaceGuard.tsx:94 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:504 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:505 msgid "Ok" msgstr "Ok" @@ -1766,10 +1778,6 @@ msgstr "Open Database Access" msgid "Open drawer" msgstr "Open drawer" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:259 -msgid "Open resource {name} in AWS Console" -msgstr "Open resource {name} in AWS Console" - #: src/pages/panel/workspace-settings-accounts-setup-cloud-azure/getInstructions.tsx:109 msgid "Open the Manage section and go to the App permissions page:" msgstr "Open the Manage section and go to the App permissions page:" @@ -1915,11 +1923,11 @@ msgstr "Press: Create Service and fill out the form." msgid "Print or copy the following recovery codes" msgstr "Print or copy the following recovery codes" -#: src/shared/cloud-avatar/CloudAvatar.tsx:64 +#: src/shared/cloud-avatar/CloudAvatar.tsx:50 msgid "Privileged" msgstr "Privileged" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:254 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:255 msgid "Privileged account" msgstr "Privileged account" @@ -1991,7 +1999,7 @@ msgstr "Regenerate" #: src/pages/panel/benchmark-detail/BenchmarkDetailCheckDetail.tsx:183 #: src/pages/panel/inventory-search/inventory-form/InventoryFormMore.tsx:97 #: src/pages/panel/inventory-search/inventory-form/InventoryFormRegionValues.tsx:60 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:242 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:258 msgid "Region" msgstr "Region" @@ -2182,10 +2190,12 @@ msgstr "Security Score" msgid "Security Score over all {accountCounts} cloud accounts" msgstr "Security Score over all {accountCounts} cloud accounts" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:270 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:281 -msgid "See this Resource in AWS Console" -msgstr "See this Resource in AWS Console" +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:276 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:287 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:300 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:305 +msgid "See this resource {buttonName}" +msgstr "See this resource {buttonName}" #: src/pages/panel/inventory-search/inventory-form/InventoryFormChangePicker.tsx:166 msgid "Select All" @@ -2255,7 +2265,7 @@ msgstr "Service Account Key" msgid "Setting Up Email Notifications" msgstr "Setting Up Email Notifications" -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:405 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:406 msgid "Setup cloud" msgstr "Setup cloud" @@ -2295,7 +2305,7 @@ msgstr "Size" msgid "Some checks have been disabled for this resource" msgstr "Some checks have been disabled for this resource" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:297 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:321 #: src/pages/panel/user-settings/UserSettingsFormEmail.tsx:33 #: src/pages/panel/user-settings/UserSettingsFormPassword.tsx:23 #: src/pages/panel/user-settings/UserSettingsTotpActivationModal.tsx:107 @@ -2322,9 +2332,9 @@ msgid "Submission Error" msgstr "Submission Error" #: src/pages/panel/workspace-settings-accounts-setup-cloud-azure/WorkspaceSettingsAccountsSetupCloudAzurePage.tsx:17 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:294 #: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:295 -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:300 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:296 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:301 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:147 #: src/pages/panel/workspace-settings-users/WorkspaceSettingsUserRoles.tsx:148 msgid "Submit" @@ -2339,7 +2349,7 @@ msgid "Successfully invited {email}" msgstr "Successfully invited {email}" #: src/pages/panel/inventory-search/inventory-form/InventoryFormMore.tsx:98 -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:307 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:331 msgid "Tags" msgstr "Tags" @@ -2376,7 +2386,7 @@ msgstr "The Google Cloud Service Account key file is valid but did not allow us msgid "The OTP or recovery code you entered is incorrect or the OTP has expired. Please try entering it again." msgstr "The OTP or recovery code you entered is incorrect or the OTP has expired. Please try entering it again." -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:295 +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:319 msgid "The selected resource does not exist anymore." msgstr "The selected resource does not exist anymore." @@ -2400,11 +2410,11 @@ msgstr "There's already another api tokens with the same description" msgid "There's no account configured for this workspace." msgstr "There's no account configured for this workspace." -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:445 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:446 msgid "This account is currently in a degraded state possibly due to a misconfiguration.<0/>Fix was unable to gather data from this account." msgstr "This account is currently in a degraded state possibly due to a misconfiguration.<0/>Fix was unable to gather data from this account." -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:413 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:414 msgid "This account is currently in a degraded state.<0/>Fix was unable to gather data from this account.<1/><2/>To resume security scans, please log into the {accountName} account ({0}) and re-deploy the CloudFormation stack that establishes the IAM role trust." msgstr "This account is currently in a degraded state.<0/>Fix was unable to gather data from this account.<1/><2/>To resume security scans, please log into the {accountName} account ({0}) and re-deploy the CloudFormation stack that establishes the IAM role trust." @@ -2412,7 +2422,7 @@ msgstr "This account is currently in a degraded state.<0/>Fix was unable to gath msgid "This email address is already registered. If this is your email, please try logging in or click on forgot password in login page to reset your password." msgstr "This email address is already registered. If this is your email, please try logging in or click on forgot password in login page to reset your password." -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:423 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:424 msgid "This project is currently in a degraded state.<0/>Fix was unable to gather data from this project.<1/><2/>To resume security scans, please ensure that the service account you configured is set up correctly.<3/>You may also recreate and upload the service account definition." msgstr "This project is currently in a degraded state.<0/>Fix was unable to gather data from this project.<1/><2/>To resume security scans, please ensure that the service account you configured is set up correctly.<3/>You may also recreate and upload the service account definition." @@ -2420,7 +2430,7 @@ msgstr "This project is currently in a degraded state.<0/>Fix was unable to gath msgid "This section does not contain any controls that can be automated.<0/>Manual checks or processes are required for compliance." msgstr "This section does not contain any controls that can be automated.<0/>Manual checks or processes are required for compliance." -#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:434 +#: src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx:435 msgid "This subscription is currently in a degraded state.<0/>Fix was unable to gather data from this subscription.<1/><2/>To resume security scans, please ensure that the application permissions are set up correctly.<3/>You may also recreate and redefine the access credentials." msgstr "This subscription is currently in a degraded state.<0/>Fix was unable to gather data from this subscription.<1/><2/>To resume security scans, please ensure that the application permissions are set up correctly.<3/>You may also recreate and redefine the access credentials." @@ -2436,9 +2446,9 @@ msgstr "Three" msgid "Tier" msgstr "Tier" -#: src/pages/panel/resource-detail/ResourceDetailView.tsx:276 -msgid "To access this resource, please ensure that you are logged into the AWS account: {account}" -msgstr "To access this resource, please ensure that you are logged into the AWS account: {account}" +#: src/pages/panel/resource-detail/ResourceDetailView.tsx:293 +msgid "To access this resource, please ensure that you are logged into the {cloudName} account: {account}" +msgstr "To access this resource, please ensure that you are logged into the {cloudName} account: {account}" #: src/pages/panel/workspace-settings-billing/ChangePaymentNoMethodModal.tsx:58 #: src/pages/panel/workspace-settings-billing/ChangeProductTierModal.tsx:137 diff --git a/src/pages/panel/inventory-search/inventory-form/InventoryForm.tsx b/src/pages/panel/inventory-search/inventory-form/InventoryForm.tsx index 4eec9049..50e3089d 100644 --- a/src/pages/panel/inventory-search/inventory-form/InventoryForm.tsx +++ b/src/pages/panel/inventory-search/inventory-form/InventoryForm.tsx @@ -7,6 +7,7 @@ import { useUserProfile } from 'src/core/auth' import { getWorkspaceInventorySearchStartQuery } from 'src/pages/panel/shared/queries' import { sendInventoryError } from 'src/pages/panel/shared/utils' import { DefaultPropertiesKeys, Predicate, useFixQueryParser } from 'src/shared/fix-query-parser' +import { getAccountCloudName } from 'src/shared/utils/getAccountCloudName' import { InventoryFormAccount } from './InventoryFormAccount' import { InventoryFormCloud } from './InventoryFormCloud' import { InventoryFormFullTextSearches } from './InventoryFormFullTextSearch' @@ -184,8 +185,8 @@ export const InventoryForm = ({ withChanges }: InventoryFormProps) => { severities: processedStartData.severity.map((severity) => ({ label: severity, value: severity, id: severity })), clouds: (!numberOfCloudFilterSelected && selectedClouds.length) || (numberOfCloudFilterSelected && numberOfCloudSelected) - ? selectedClouds.map((cloud) => ({ label: cloud.toUpperCase(), value: cloud, id: cloud })) - : processedStartData.clouds.map((cloud) => ({ value: cloud, label: cloud.toUpperCase(), id: cloud })), + ? selectedClouds.map((cloud) => ({ label: getAccountCloudName(cloud), value: cloud, id: cloud })) + : processedStartData.clouds.map((cloud) => ({ value: cloud, label: getAccountCloudName(cloud), id: cloud })), }), [processedStartData, selectedClouds, numberOfCloudFilterSelected, numberOfCloudSelected], ) diff --git a/src/pages/panel/resource-detail/ResourceDetailView.tsx b/src/pages/panel/resource-detail/ResourceDetailView.tsx index 3fdfcb05..c0ed582b 100644 --- a/src/pages/panel/resource-detail/ResourceDetailView.tsx +++ b/src/pages/panel/resource-detail/ResourceDetailView.tsx @@ -1,4 +1,4 @@ -import { Trans } from '@lingui/macro' +import { t, Trans } from '@lingui/macro' import { useLingui } from '@lingui/react' import CloseIcon from '@mui/icons-material/Close' import OpenInNewIcon from '@mui/icons-material/OpenInNew' @@ -16,9 +16,9 @@ import { Skeleton, Slide, Stack, + styled, Tooltip, Typography, - styled, } from '@mui/material' import { useQuery } from '@tanstack/react-query' import { AxiosError } from 'axios' @@ -32,9 +32,11 @@ import { useAbsoluteNavigate } from 'src/shared/absolute-navigate' import { NetworkDiagram } from 'src/shared/charts' import { CloudAvatar } from 'src/shared/cloud-avatar' import { panelUI } from 'src/shared/constants' +import { ExternalLinkButton } from 'src/shared/link-button' import { Modal as PopupModal } from 'src/shared/modal' import { StickyAccordionSummaryWithIcon } from 'src/shared/sticky-accordion-summary' -import { FailedCheck } from 'src/shared/types/server-shared' +import { AccountCloud, FailedCheck } from 'src/shared/types/server-shared' +import { getAccountCloudName } from 'src/shared/utils/getAccountCloudName' import { diffDateTimeToDuration, iso8601DurationToString } from 'src/shared/utils/parseDuration' import { getLocationSearchValues, removeLocationSearchValues } from 'src/shared/utils/windowLocationSearch' import { YamlHighlighter } from 'src/shared/yaml-highlighter' @@ -86,7 +88,6 @@ const GridItem = ({ property, value, color, isReactNode }: GridItemProps) => { (value as ReactNode) ) : ( { ) } +const getOpenResourceButtonText = (cloud: AccountCloud) => { + switch (cloud) { + case 'aws': + return t`in AWS Console` + case 'azure': + return t`in Azure Portal` + case 'gcp': + return t`in Google Cloud Console` + default: + return '' + } +} + export default function ResourceDetailView() { const postHog = usePostHog() const { resourceDetailId } = useParams<'resourceDetailId'>() @@ -166,6 +180,8 @@ export default function ResourceDetailView() { const cloud = data?.resource.ancestors?.cloud?.reported?.name ?? (window.decodeURIComponent(getLocationSearchValues(window.location.search)?.cloud || '') || '-') + const cloudName = getAccountCloudName(cloud) + const buttonName = getOpenResourceButtonText(cloud) const accountObj = data?.resource.ancestors?.account?.reported const account = accountObj ? `${accountObj?.name} (${accountObj?.id})` : '-' const region = data?.resource.ancestors?.region?.reported?.name ?? '-' @@ -235,7 +251,7 @@ export default function ResourceDetailView() { Name} value={name} /> Cloud} - value={cloud !== '-' ? {cloud.toUpperCase()} : '-'} + value={cloud !== '-' ? {cloudName} : '-'} isReactNode={cloud !== '-'} /> Account} value={account} /> @@ -253,34 +269,42 @@ export default function ResourceDetailView() { {provider_link ? ( - <> - Open resource {name} in AWS Console} - width={panelUI.minLargeModalWidth} - actions={ - - } - > - - - To access this resource, please ensure that you are logged into the AWS account: {account} - - - - - + cloud === 'aws' ? ( + <> + See this resource {buttonName}} + width={panelUI.minLargeModalWidth} + actions={ + + } + > + + + + To access this resource, please ensure that you are logged into the {cloudName} account: {account} + + + + + + + ) : ( + + See this resource {buttonName} + + ) ) : null} diff --git a/src/pages/panel/security/AccountCard.tsx b/src/pages/panel/security/AccountCard.tsx index 19b3427d..4f1ad621 100644 --- a/src/pages/panel/security/AccountCard.tsx +++ b/src/pages/panel/security/AccountCard.tsx @@ -2,6 +2,7 @@ import { Trans } from '@lingui/macro' import { Card, CardContent, CardHeader, Tooltip, Typography, TypographyProps, cardHeaderClasses, styled } from '@mui/material' import { colorFromRedToGreen } from 'src/shared/constants' import { WorkspaceAccountReportSummary } from 'src/shared/types/server' +import { getAccountCloudName } from 'src/shared/utils/getAccountCloudName' import { shouldForwardProp } from 'src/shared/utils/shouldForwardProp' const AccountCardContainer = styled(Card, { shouldForwardProp })<{ score?: number }>(({ theme, score }) => ({ @@ -34,7 +35,7 @@ export const AccountCard = ({ account }: AccountCardProps) => { ID: {account.id} - Cloud: {account.cloud?.toUpperCase()} + Cloud: {account.cloud ? getAccountCloudName(account.cloud) : '-'} {account.score !== undefined ? Score: {account.score} : undefined} diff --git a/src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx b/src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx index 3c6895e2..a93182bb 100644 --- a/src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx +++ b/src/pages/panel/workspace-settings-accounts/WorkspaceSettingsAccountRow.tsx @@ -28,6 +28,7 @@ import { Modal } from 'src/shared/modal' import { useNonce } from 'src/shared/providers' import { GetWorkspaceInventoryReportSummaryResponse } from 'src/shared/types/server' import { Account } from 'src/shared/types/server-shared' +import { getAccountCloudName } from 'src/shared/utils/getAccountCloudName' import { getAccountName } from 'src/shared/utils/getAccountName' import { deleteAccountMutation } from './deleteAccount.mutation' import { patchAccountMutation } from './patchAccount.mutation' @@ -490,7 +491,7 @@ export const WorkspaceSettingsAccountRow = ({ ID: {account.account_id} - Cloud: {account.cloud.toUpperCase()} + Cloud: {getAccountCloudName(account.cloud)} Name: {accountName} diff --git a/src/shared/cloud-avatar/CloudAvatar.tsx b/src/shared/cloud-avatar/CloudAvatar.tsx index 0b1a3a0f..c78c2e83 100644 --- a/src/shared/cloud-avatar/CloudAvatar.tsx +++ b/src/shared/cloud-avatar/CloudAvatar.tsx @@ -5,6 +5,7 @@ import { ReactNode } from 'react' import { AwsLogo, AzureLogo, Crown, FixLogo, GcpLogo } from 'src/assets/icons' import { useNonce } from 'src/shared/providers' import { AccountCloud } from 'src/shared/types/server-shared' +import { getAccountCloudName } from 'src/shared/utils/getAccountCloudName' export interface CloudAvatarProps { cloud: AccountCloud @@ -36,23 +37,8 @@ const CloudIcon = ({ cloud, small, withCrown }: CloudAvatarProps) => { } } -const cloudDefaultTooltip = (cloud: AccountCloud) => { - switch (cloud) { - case 'aws': - return 'AWS' - case 'azure': - return 'Azure' - case 'fix': - return 'FIX' - case 'gcp': - return 'GCP' - default: - return cloud - } -} - export const CloudAvatar = ({ cloud, small, withCrown, tooltip, error, onErrorClick }: CloudAvatarProps) => ( - + diff --git a/src/shared/event-button/EventButton.tsx b/src/shared/event-button/EventButton.tsx index fdd7e073..063b2f6c 100644 --- a/src/shared/event-button/EventButton.tsx +++ b/src/shared/event-button/EventButton.tsx @@ -6,6 +6,7 @@ import { useEffect, useRef, useState } from 'react' import { useEvents } from 'src/core/events' import { useSnackbar } from 'src/core/snackbar' import { WebSocketEvent } from 'src/shared/types/server' +import { getAccountCloudName } from 'src/shared/utils/getAccountCloudName' import { EventItem } from './EventItem' const PopperContainer = styled(Popper)(({ theme }) => ({ @@ -54,7 +55,7 @@ export const EventButton = () => { void queryClient.invalidateQueries({ predicate: (query) => typeof query.queryKey[0] === 'string' && query.queryKey[0].startsWith('workspace-cloud-account'), }) - void showSnackbar(t`${ev.data.cloud.toUpperCase()} Cloud account configured, id: ${ev.data.account_id}`, { + void showSnackbar(t`${getAccountCloudName(ev.data.cloud)} Cloud account configured, id: ${ev.data.account_id}`, { severity: 'success', autoHideDuration: null, }) @@ -72,7 +73,7 @@ export const EventButton = () => { void queryClient.invalidateQueries({ predicate: (query) => typeof query.queryKey[0] === 'string' && query.queryKey[0].startsWith('workspace-cloud-account'), }) - void showSnackbar(t`${ev.data.cloud.toUpperCase()} Cloud account degraded, id: ${ev.data.account_id}`, { + void showSnackbar(t`${getAccountCloudName(ev.data.cloud)} Cloud account degraded, id: ${ev.data.account_id}`, { severity: 'warning', autoHideDuration: null, }) @@ -81,7 +82,7 @@ export const EventButton = () => { void queryClient.invalidateQueries({ predicate: (query) => typeof query.queryKey[0] === 'string' && query.queryKey[0].startsWith('workspace-cloud-account'), }) - void showSnackbar(t`${ev.data.cloud.toUpperCase()} Cloud account degraded, id: ${ev.data.account_id}`, { + void showSnackbar(t`${getAccountCloudName(ev.data.cloud)} Cloud account degraded, id: ${ev.data.account_id}`, { severity: 'warning', autoHideDuration: null, }) @@ -90,7 +91,9 @@ export const EventButton = () => { void queryClient.invalidateQueries({ predicate: (query) => typeof query.queryKey[0] === 'string' && query.queryKey[0].startsWith('workspace-cloud-account'), }) - void showSnackbar(t`${ev.data.cloud.toUpperCase()} Cloud account discovered, id: ${ev.data.account_id}`, { severity: 'info' }) + void showSnackbar(t`${getAccountCloudName(ev.data.cloud)} Cloud account discovered, id: ${ev.data.account_id}`, { + severity: 'info', + }) break case 'aws_account_discovered': void queryClient.invalidateQueries({ diff --git a/src/shared/link-button/ExternalLinkButton.tsx b/src/shared/link-button/ExternalLinkButton.tsx new file mode 100644 index 00000000..67c1c30c --- /dev/null +++ b/src/shared/link-button/ExternalLinkButton.tsx @@ -0,0 +1,19 @@ +import OpenInNewIcon from '@mui/icons-material/OpenInNew' +import { Button, ButtonProps, ButtonTypeMap } from '@mui/material' +import { ElementType } from 'react' + +type ExternalLinkButtonProps = ButtonProps & { + href: string +} + +export function ExternalLinkButton({ + href, + children, + ...props +}: ExternalLinkButtonProps) { + return ( + + ) +} diff --git a/src/shared/link-button/index.ts b/src/shared/link-button/index.ts index 04e921ae..aed9dbcd 100644 --- a/src/shared/link-button/index.ts +++ b/src/shared/link-button/index.ts @@ -1,3 +1,4 @@ +export { ExternalLinkButton } from './ExternalLinkButton' export { ExternalLinkLoadingButton } from './ExternalLinkLoadingButton' export { InternalLink } from './InternalLink' export { InternalLinkButton } from './InternalLinkButton' diff --git a/src/shared/utils/getAccountCloudName.ts b/src/shared/utils/getAccountCloudName.ts new file mode 100644 index 00000000..d3dee3f5 --- /dev/null +++ b/src/shared/utils/getAccountCloudName.ts @@ -0,0 +1,16 @@ +import { AccountCloud } from 'src/shared/types/server-shared' + +export const getAccountCloudName = (cloud: AccountCloud) => { + switch (cloud.toLowerCase()) { + case 'aws': + return 'AWS' + case 'azure': + return 'Azure' + case 'fix': + return 'FIX' + case 'gcp': + return 'GCP' + default: + return cloud + } +}