漏洞描述
The Openstack host is configured as a proxy which allows access to the instance metadata service. This could allow significant access to the host/infrastructure.
id: metadata-service-openstack
info:
name: Openstack Metadata Service Check
author: sullo
severity: critical
verified: false
description: The Openstack host is configured as a proxy which allows access to the instance metadata service. This could allow significant access to the host/infrastructure.
remediation: Disable the proxy or restrict configuration to only allow access to approved hosts/ports. Upgrade to IMDSv2 if possible.
reference:
- https://docs.openstack.org/nova/latest/admin/metadata-service.html
- https://blog.projectdiscovery.io/abusing-reverse-proxies-metadata/
- https://www.mcafee.com/blogs/enterprise/cloud-security/how-an-attacker-could-use-instance-metadata-to-breach-your-app-in-aws/
tags: exposure,config,openstack,proxy,misconfig,metadata
created: 2023/11/30
set:
hostval1: "aws.oast.online"
hostval2: "169.254.169.254"
rules:
r0:
request:
raw: |
GET http://{{hostval1}}/openstack/latest HTTP/1.1
Host: {{hostval1}}
expression: response.body.bcontains(b"vendor_data.json")
r1:
request:
raw: |
GET http://{{hostval2}}/openstack/latest HTTP/1.1
Host: {{hostval2}}
expression: response.body.bcontains(b"vendor_data.json")
expression: r0() || r1()