Mantieni tutto organizzato con le raccolte
Salva e classifica i contenuti in base alle tue preferenze.
Scopri come risolvere alcuni errori generati da Security Command Center. Questo argomento tratta
gli errori la cui risoluzione richiede più passaggi di quelli che possono essere facilmente descritti in un
messaggio di errore.
Notifiche
Quando utilizzi la funzionalità di notifiche dell'API Security Command Center, potresti visualizzare i seguenti errori.
Errore durante la lettura del file delle credenziali dalla variabile di ambiente
java.lang.RuntimeException: java.io.IOException: Error reading credential file
from environment variable GOOGLE_APPLICATION_CREDENTIALS
Questo errore si verifica quando tenti di utilizzare l'API Security Command Center Notifications
e le chiavi delaccount di serviziot non sono accessibili. Per risolvere questo errore:
Se utilizzi un IDE come IntelliJ, assicurati che l'ambiente di sviluppo sia configurato in modo da puntare alla posizione in cui è archiviata la chiave dell'account di servizio.
Questo errore si verifica più comunemente quando non utilizzi la versione più recente
di Google Cloud CLI. Per risolvere questo errore, esegui l'aggiornamento all'ultima
versione di gcloud CLI eseguendo:
gcloudcomponentsupdate
Web Security Scanner
Per contattarci in merito ai messaggi di errore riportati di seguito,
invia un feedback sulla scansione specifica.
Messaggio di errore
Descrizione
L'app reindirizzava spesso lo scanner a una pagina di autenticazione
Se utilizzi l'autenticazione Google, lo scanner rileva i reindirizzamenti di autenticazione.
Molto probabilmente le credenziali che stai utilizzando per eseguire la scansione del sito non sono valide.
Per verificare la validità delle credenziali, avvia una sessione di navigazione in incognito di Chrome e
prova ad accedere con le credenziali di test nella tua applicazione.
L'app ha generato un numero elevato di errori durante questa scansione
Web Security Scanner ha rilevato che un'alta percentuale di richieste ha generato risposte HTTP 4xx o 5xx. Verifica le
credenziali di scansione e l'URL di destinazione. Se il problema persiste, segnala un bug.
La scansione ha trovato un numero ridotto di risultati durante la scansione
Web Security Scanner non ha trovato molte pagine da testare. Questo errore è
previsto per i siti che non modificano spesso l'URL e per i siti che hanno
funzionalità dell'applicazione dietro le barre di navigazione in più passaggi. Prova ad aggiungere altri
URL base, ad esempio l'URL di ogni funzionalità a cui porta una barra di navigazione.
La scansione ha rilevato troppi URL durante la scansione dei risultati e non li ha testati tutti.
Questo problema può verificarsi se la tua app ha molti URL che rimandano allo stesso
modello. In questo caso,
invia una richiesta di funzionalità e il team potrebbe
essere in grado di ottimizzare la logica delle pagine duplicate per te.
Si è verificato un errore interno durante la scansione.
Questo messaggio può indicare uno o più errori interni. Se ricevi questo
messaggio, invia un feedback sulla scansione
specifica.
La scansione è scaduta durante la scansione dell'app
Esiste un limite di tempo per ogni fase del crawler.
Se hai un sito di grandi dimensioni, questo errore potrebbe verificarsi.
Invia una richiesta di funzionalità e il team potrà
aumentare manualmente il timeout di scansione.
Se hai un sito di piccole dimensioni, potrebbe essersi verificato un problema con
il crawler. Segnala un bug con i dettagli della scansione per richiedere una revisione.
La scansione ha attivato un meccanismo di protezione DDoS ed è stata interrotta
Questo errore è causato da un numero eccessivo di query troppo rapide. Prova a ridurre le query al secondo (QPS).
Risolvere i problemi
Se Web Security Scanner segnala un problema, devi disattivare la protezione
cross-site scripting (XSS) del browser e poi verificare la posizione. Per ulteriori
informazioni, consulta
Verifica il problema.
[[["Facile da capire","easyToUnderstand","thumb-up"],["Il problema è stato risolto","solvedMyProblem","thumb-up"],["Altra","otherUp","thumb-up"]],[["Difficile da capire","hardToUnderstand","thumb-down"],["Informazioni o codice di esempio errati","incorrectInformationOrSampleCode","thumb-down"],["Mancano le informazioni o gli esempi di cui ho bisogno","missingTheInformationSamplesINeed","thumb-down"],["Problema di traduzione","translationIssue","thumb-down"],["Altra","otherDown","thumb-down"]],["Ultimo aggiornamento 2025-09-05 UTC."],[],[],null,["| Standard, Premium, and Enterprise [service tiers](/security-command-center/docs/service-tiers)\n\nLearn how to resolve some errors raised by Security Command Center. This topic discusses\nerrors whose resolutions require more steps than can be easily described in an\nerror message.\n| **Note:** For more troubleshooting information, see [Troubleshooting](/security-command-center/docs/troubleshooting). In addition, Security Command Center provides error detectors, which report configuration errors that prevent Security Command Center and its services from working properly. Each error finding includes suggested remediation steps. For more information, see [Security Command Center errors](/security-command-center/docs/concepts-scc-errors).\n\nNotifications\n\nYou might get the following errors when you use the Security Command Center API\nnotifications feature.\n\nError reading credential file from environment variable\n\n`java.lang.RuntimeException: java.io.IOException: Error reading credential file\nfrom environment variable GOOGLE_APPLICATION_CREDENTIALS`\n\nThis error occurs when you try to use the Security Command Center notifications API\nand the service account keys aren't accessible. To resolve this error, do the\nfollowing:\n\n- Complete the steps to [set up a service account](/security-command-center/docs/how-to-notifications) and get the service account key.\n- If you're using an IDE like Intellij, make sure that your development environment is configured to point to the location where the service account key is stored.\n\nInvalid choice: `add-iam-policy-binding`\n\n`ERROR: (gcloud.pubsub.topics) Invalid choice: 'add-iam-policy-binding'`\n\nThis error most commonly occurs when you aren't using the most current version\nof the Google Cloud CLI. To resolve this error, update to the latest\ngcloud CLI version by running: \n\n gcloud components update\n\nWeb Security Scanner\n\nTo contact us about the error messages below,\n[send feedback](/security-command-center/docs/getting-support) about the specific scan.\n\n| Error message | Description |\n|-------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| The app often redirected the scanner to an authentication page | If you're using Google authentication, the scanner detects auth redirects. Most likely the credentials you're using to scan the site are invalid. To check the validity of credentials, start a Chrome incognito session and try to log in with the test credentials on your application. |\n| The app produced a high number of errors during this scan | Web Security Scanner found that a high percentage of requests resulted in `4xx` or `5xx` HTTP responses. Verify your scanning credentials and the target URL. If the problem continues to occur, [file a bug](/security-command-center/docs/getting-support). |\n| The scan found a small number of results during crawling | Web Security Scanner didn't find many pages to test. This error is expected for sites that don't often change the URL and sites that have application features behind multi-step navigation bars. Try adding more seed URLs, like the URL for each feature that a navigation bar leads to. |\n| The scan found too many URLs while crawling results and has not tested all of them. | This problem can appear if your app has many URLs that lead to the same template. In this case, [file a feature request](/security-command-center/docs/getting-support) and the team might be able to tune the duplicate-page logic for you. |\n| An internal error occurred during the scan. | This message can indicate one or more internal errors. If you get this message, [send feedback](/security-command-center/docs/getting-support) about the specific scan. |\n| The scan timed out while crawling the app | There is a time limit for each stage of the crawler. - If you have a large site, then this error may occur. [File a feature request](/security-command-center/docs/getting-support), and the team can manually increase your crawl timeout. - If you have a small site, then something might have gone wrong with the crawler. [File a bug](/security-command-center/docs/getting-support) with your scan details to request a review. |\n| The scan triggered a DDOS protection mechanism and has been stopped | This error is caused by too many queries, too fast. Try reducing the Queries Per Second (QPS). |\n\nFixing issues\n\nIf Web Security Scanner reports an issue, you need to disable browser\ncross-site scripting (XSS) protection and then verify the location. For more\ninformation, see\n[Verify the issue](/security-command-center/docs/how-to-remediate-web-security-scanner-findings#verify_the_issue).\n| **Important:** If you disable XSS protection in the browser, only use that browser instance to test your own security issues.\n\nWhat's next\n\nLearn about [Security Command Center errors](/security-command-center/docs/concepts-scc-errors)."]]