Regular Expressions 101

Community Patterns

1...34567...283

Amazon AWS Access Key ID (Legacy)

0

Regular Expression
ECMAScript (JavaScript)

/
AKIA[0-9A-Z]{16}
/
gmisu

Description

{
    "Expressions": {
        "Amazon AWS Access Key ID (Legacy)": {
            "Expression": "AKIA[0-9A-Z]{16}",
            "Unit-Tests": [
                {
                    "Title": "Baseline",
                    "Input": "AKIA123456789abcderf",
                    "Description": "Prefix, Numerics, Character Match",
                    "Truthy": true
                },
                {
                    "Title": "Non-Numerics",
                    "Input": "AKIAabcdefghijklmnop",
                    "Description": "Stripped of Numbers",
                    "Truthy": true
                },
                {
                    "Title": "Under 16 Characters",
                    "Input": "AKIA",
                    "Description": "Only Prefix Found",
                    "Truthy": false
                }
            ],
            "External": "https://regex101.com/r/hDdc88/1",
            "Comment": "...",
            "Provider": "AWS",
            "Context": "Cloud"
        }
    }
}
Submitted by Jacob Sanders - 2 years ago