nixpkgs/nixos/modules
Graham Christensen 83ea88e03f
nixos: ec2 ami: support IMDSv2
AWS's metadata service has two versions. Version 1 allowed plain HTTP
requests to get metadata. However, this was frequently abused when a
user could trick an AWS-hosted server in to proxying requests to the
metadata service. Since the metadata service is frequently used to
generate AWS access keys, this is pretty gnarly. Version two is
identical except it requires the caller to request a token and provide
it on each request.

Today, starting a NixOS AMI in EC2 where the metadata service is
configured to only allow v2 requests fails: the user's SSH key is not
placed, and configuration provided by the user-data is not applied.
The server is useless. This patch addresses that.

Note the dependency on curl is not a joyful one, and it expand the
initrd by 30M. However, see the added comment for more information
about why this is needed. Note the idea of using `echo` and `nc` are
laughable. Don't do that.
2020-11-19 13:00:56 -05:00
..
config Merge pull request #103225 from gebner/hsphfpd 2020-11-11 19:56:35 +01:00
hardware nixos/acpilight: add to packages 2020-11-12 05:22:18 +03:00
i18n/input-method hime: fix enable hime, remove hime-all package 2020-10-17 10:48:31 +08:00
installer Support virtio_scsi devices on nixos-generate-config 2020-11-04 10:00:28 +01:00
misc nixos-help: bundle the desktop item with the script 2020-11-05 11:56:31 +01:00
profiles nixos/hardened: update blacklisted filesystems 2020-09-27 06:16:58 +00:00
programs maintainers: rename filalex77 -> Br1ght0ne 2020-11-17 13:09:31 +02:00
security Merge pull request #101370 from m1cr0man/ssl-test-certs 2020-10-28 17:21:57 +01:00
services Merge #103633: kresd service: switch .listenDoH 2020-11-17 20:06:55 +01:00
system Merge master into staging-next 2020-11-10 10:11:08 +01:00
tasks Merge pull request #103876 from Mic92/lvm-generator-fix 2020-11-16 18:37:36 +01:00
testing nixos/tests: only apply qemu parameters if the options are defined 2020-10-25 13:42:01 +01:00
virtualisation nixos: ec2 ami: support IMDSv2 2020-11-19 13:00:56 -05:00
module-list.nix nixos/mackerel-agent: init 2020-11-07 13:37:33 +09:00
rename.nix Merge pull request #91256 from prusnak/seeks 2020-09-18 16:32:33 +02:00