Lion Cipher Lab
Install and configure the AWS CLI the safe way — named profiles, no root keys, and a LocalStack fallback
- Cloud Security
- Beginner
- ~60 min
- Free · no account required
Why it matters
Almost every hands-on cloud-security lab on this site — finding over-privileged roles with Access Analyzer, auditing an account with Prowler, reading CloudTrail, locking down a Lambda function, walking an attack path on LocalStack — starts with the AWS CLI already installed and already configured. The CLI is also where beginners make the single most expensive mistake in cloud: they create access keys for the root user, paste them into `aws configure`, and now a plain-text file in their home folder can do anything to the account, including run up a bill. This lab installs the tool and, more…
What you'll learn
- installing the AWS CLI v2
- IAM users and access keys
- named profiles and where credentials live
- STS get-caller-identity (who am I)
- environment variables vs config files
- LocalStack with --endpoint-url
- access key rotation and hygiene
- reading CLI errors
Steps in this lab
- What the AWS CLI is, and why every cloud lab uses it instead of the website
- Before you start: what is free here, and what this lab refuses to touch
- Windows: install with the MSI, then open a NEW terminal
- macOS: install the pkg (double-click, or two commands)
- Linux: download, VERIFY the signature, then install
- The decision that matters: an IAM user's key, never root's (and what to do if you already made one)
- Create the CLI user: no console password, read-only, one key
- aws configure — with a NAMED profile, and where the files land
- Two commands that tell you the truth: configure list, and "who am I"
- Environment variables vs the files — and the order the CLI checks them
- The LocalStack fallback: a fake AWS on your own machine (no AWS account needed)
- One call against each: IAM on the real account, S3 on LocalStack
- Credential hygiene: the four rules, and how to rotate and delete a key
- The errors you'll actually hit, and what each one is really saying
- Prove it: four lines that say you did this the safe way
- What you just did — and why the profile name is the whole lesson