Is accessing metadata of other VMs disallowed

asked 2019-03-07 06:27:36 -0600

ogondza gravatar image

I am using user-data passed to an instance to distribute secrets to the VM being provisioned. That works well, though I am looking for a verification of such approach from security perspective. Based on the materials I found or answered questions here it sort of sounds metadata service serves data only to the VM in question, but I am wondering if server metadata including user-data are guaranteed not to be served to other VMs. Or in the broader sense, whether this is considered a secure practice by openstack community.

I am aware those details can be accessed through horizon or openstack rest API by authorized clients, though I am interested in securing things from processes running in VMs.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2019-03-07 10:01:06 -0600

See for some caveats around this, but in general the assumption is that if instances are unable to spoof their metadata API queries and/or listen to the connections between the Nova metadata service and other instances, then you can probably trust it to be confidential. The reason it's hard to say this definitively is that securing access to metadata is more up to local deployment technology choices outside the sphere of any OpenStack software's control to assure. If you can disable the metadata service and switch to configdrive in your deployment (as mentioned in the OSSN), that also may provide better mitigation of these risks.

It also warrants pointing out that instance metadata was never intended for communicating sensitive information in the first place, so treating it as if it were is not officially recommended.

edit flag offensive delete link more


Thanks for the pointers. The document recommends to use config drive to distribute secrets instead. But doing so does not seem to prevent metadata service to continue serving the host metadata leaving my secrets exposed. What am I missing?

ogondza gravatar imageogondza ( 2019-03-11 07:39:55 -0600 )edit

I agree, the suggestion in that document is misdirected at service users when it should have been a suggestion for deployers. If it's an environment under your control, you can mitigate request spoofing by disabling the metadata service entirely and only making configdrive available to your users.

fungi gravatar imagefungi ( 2019-03-11 09:15:29 -0600 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2019-03-07 06:27:36 -0600

Seen: 101 times

Last updated: Mar 07 '19