Difference between AWS Access Key IDs and Secret Access Keys

0

Hi, I am trying to create a script that picks up Secret Access Keys and want to filter out the Access Key IDs. So far I've noticed Secret Access Keys seem to be longer (usually character length of 40) than Access Key IDs (usually character length of 20). Is this 100% accurate? And are there any other differences I can use?

Thank you.

2 Risposte
1
Risposta accettata

Hi,

I recommend you check public projects that already solved this, for example https://github.com/awslabs/git-secrets/blob/master/git-secrets In particular you will realize that they use the following regex to capture the access keys and secret keys

  1. Access Key: (A3T[A-Z0-9]|AKIA|AGPA|AIDA|AROA|AIPA|ANPA|ANVA|ASIA)[A-Z0-9]{16}
  2. Secret Key: [A-Za-z0-9/\+=]{40}

Hope this helps!

AWS
con risposta 5 mesi fa
profile picture
ESPERTO
verificato un mese fa
profile pictureAWS
ESPERTO
verificato 5 mesi fa
0

thank you four super

con risposta 5 mesi fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande