Moving your systems to the cloud does not automatically make them secure or insecure. The most common cloud incidents do not come from the provider being vulnerable, but from customer configurations: public storage, an access key in a repository, a user with administrator permissions that nobody reviewed. Here is a practical approach for AWS, applicable in general to other providers.
Short answer: AWS security is built on the shared responsibility model: AWS protects the infrastructure and you protect your data, access, and configuration. The principle of least privilege, with MFA, specific roles, and CloudTrail audit logs, prevents most configuration-related incidents.
What is shared responsibility in AWS?
The principle of least privilege is the practice of giving each person, application, or process only the permissions needed for its task, for as long as needed, to limit the damage if an account is compromised.
AWS explains it with a model: the provider takes care of security of the cloud (data centers, hardware, the base infrastructure); you take care of security in the cloud (your data, access, network configuration, operating systems you manage, applications). The exact split changes by service: on a virtual machine (EC2) you manage more; on a managed service (such as a managed database) you manage less. Check the documentation for the specific service.
What is the principle of least privilege in AWS?
Each person, application, or process should have only the permissions needed for its task, for as long as needed. If an account is compromised, the damage stays limited.
In practice, in AWS this means:
- Do not use the root user for daily work. Enable MFA on it, store its credentials carefully, and use it only for tasks that require it.
- Individual users or single sign-on instead of shared accounts, with mandatory MFA.
- Groups and roles instead of permissions assigned person by person.
- Specific policies, not
AdministratorAccessor wildcard (*) actions and resources unless justified. - Roles for applications (for example, instance or execution roles) instead of fixed access keys embedded in code.
- Temporary credentials whenever possible.
- Periodic review: remove users, keys, and permissions that are not used. IAM Access Analyzer and last-used reports help identify what is surplus.
Accounts and organization
Separate environments (development, testing, production) into distinct accounts when size justifies it, managed with AWS Organizations. That way a mistake in testing does not touch production and you can apply control policies at the organization level. For a small company, at least separate access and resources by environment with tags and distinct roles.
Critical configurations
Storage (S3)
- Enable public access blocking at the account level except in justified cases.
- Encrypt objects and enable versioning on important data.
- Use presigned URLs with short expiry to share files.
- Enable access logs on sensitive buckets.
Networking
- Security groups should open only the necessary ports and to specific sources; avoid opening SSH (22) or remote desktop (3389) to the whole internet.
- Place databases in private subnets, with no direct access from the internet.
- To administer servers, use mechanisms such as Systems Manager Session Manager or a VPN instead of exposing ports.
Data and keys
- Encrypt databases and volumes at rest, with keys managed in KMS.
- Store secrets in Secrets Manager or Parameter Store, not in code or in unprotected variables.
- Rotate credentials and keys periodically.
How do I detect suspicious activity in AWS?
What is not logged cannot be investigated:
- CloudTrail enabled in all regions, with logs sent to a protected bucket.
- AWS Config to detect changes and configuration drift.
- GuardDuty to detect suspicious activity.
- Billing and unusual-usage alerts, because a sudden spike in spending is often the first sign of stolen credentials being used to mine cryptocurrency.
- Alarms for key events: root user usage, policy changes, logging being disabled.
The cost of these services depends on volume and region; check the AWS pricing calculator before enabling them to estimate the figure.
Compliance and data location
If you handle personal data of customers in Mexico or other Latin American countries, consider where it is stored and who accesses it, and what transfers your architecture implies, based on the applicable data protection regulation. Choosing the region and documenting the architecture makes it easier to respond to audits and corporate customers. Consult legal counsel for the specific requirements of your industry.
Common mistakes
- Access keys in code repositories, even private ones.
- Users with administrator permissions "for convenience."
- Public buckets to "share quickly."
- No MFA on the root account or on administrators.
- Logging disabled to save a few pesos.
- Databases reachable from any IP.
- Nobody knows who has access to what, or who left the company.
- Infrastructure created by hand, impossible to reproduce or audit.
What can you do this week to secure your AWS account?
- Enable MFA on the root account and delete its access keys if they exist.
- Inventory users, roles, and keys; delete what is not used.
- Review security groups with ports open to the world.
- Enable CloudTrail and billing alerts.
- Enable public access blocking on S3.
- Move secrets out of code.
- Define infrastructure as code so you have a record of every change.
When the cloud makes sense and when it does not
The cloud offers capabilities that are hard to match on your own servers, such as redundancy, scaling, and managed services. But it demands configuration discipline. If nobody on your team can administer it, a provider who does so or a simpler, well-documented environment is a better fit.
At DaltoAura we deploy and configure cloud infrastructure with role-based access, logging, and backups from day one.
Complement this guide with MFA and password managers, 3-2-1 backups, and secure CI/CD pipelines.
Frequently asked questions
What is the AWS root user and how is it protected?
It is the account's original identity, with total control. Protect it with MFA, a long password stored in a manager, a corporate email under the company's control, and no access keys. Use it only for tasks that require it and work day to day with users or roles with limited permissions.
How do I avoid exposing access keys in a code repository?
Avoid fixed keys: use IAM roles and temporary credentials for applications. Add secret scanning in the repository and in the pipeline, block commits containing credentials, and, if a key leaks, revoke and rotate it immediately, even if the repository is private.
Is my data in AWS encrypted by default?
It depends on the service and its current configuration; many offer encryption at rest and in transit, but you should verify it and enable it explicitly where appropriate. Review each service's documentation, define who manages the keys, and check the configuration periodically instead of assuming it.
What does it cost to enable CloudTrail and basic alerts?
It depends on event volume, retention, and the additional services you use; the basic tier is usually inexpensive compared with the risk it covers. Check the AWS pricing calculator with your case, and start by logging management activity in all regions.
Let's talk
If your infrastructure lives on AWS or you plan to migrate, we can review your account configuration and tidy up access, networking, and backups. Tell us how it is set up today.