mirror of
https://github.com/lunchcat/sif.git
synced 2026-07-28 14:37:01 -07:00
add recon modules for unauthenticated proxy and server admin interfaces that should be loopback-only: caddy /config/ returns the full running configuration and accepts a config-replacing post, and envoy /server_info exposes the build and command-line options of an admin interface that also offers config_dump and shutdown.
42 lines
920 B
YAML
42 lines
920 B
YAML
# Envoy Proxy Admin Interface Exposure Detection Module
|
|
|
|
id: envoy-admin-exposure
|
|
info:
|
|
name: Envoy Admin Interface Exposure
|
|
author: sif
|
|
severity: high
|
|
description: Detects an exposed Envoy admin interface that leaks build and config details and exposes runtime shutdown and modification
|
|
tags: [envoy, proxy, service-mesh, admin, controlplane, exposure, unauth, recon]
|
|
|
|
type: http
|
|
|
|
http:
|
|
method: GET
|
|
paths:
|
|
- "{{BaseURL}}/server_info"
|
|
|
|
matchers:
|
|
- type: word
|
|
part: body
|
|
words:
|
|
- "\"hot_restart_version\""
|
|
- "\"command_line_options\""
|
|
condition: and
|
|
|
|
- type: regex
|
|
part: body
|
|
regex:
|
|
- '"state"\s*:\s*"(LIVE|PRE_INITIALIZING|INITIALIZING|DRAINING)"'
|
|
|
|
- type: status
|
|
status:
|
|
- 200
|
|
|
|
extractors:
|
|
- type: regex
|
|
name: envoy_version
|
|
part: body
|
|
regex:
|
|
- '"version"\s*:\s*"([^"]+)"'
|
|
group: 1
|