Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider blocking AWS metadata service access to non-root processes #71

Open
gozer opened this issue Mar 5, 2015 · 1 comment
Open
Labels

Comments

@gozer
Copy link
Contributor

gozer commented Mar 5, 2015

Not sure it's such a good idea, but would be easy as pie.

Adding this at the end of bootup:

Block AWS metadata service to non-root users

iptables -A OUTPUT -p tcp -d 169.254.169.254 -m owner --uid-owner root -j ACCEPT
iptables -A OUTPUT -p tcp -m tcp -d 169.254.169.254 -j REJECT

@gozer
Copy link
Contributor Author

gozer commented Jun 5, 2015

Even simpler, turns out cloud-init supports this out of the box with the disable_ec2_metadata configuration option, just need to drop that in /etc/cloud.cfg.d/

@gozer gozer added feature and removed enhancement labels Jun 11, 2015
@gozer gozer modified the milestones: v1.1, v1.1.0 Jun 15, 2015
@tinnightcap tinnightcap modified the milestone: v1.1.0 Jul 24, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants