oasdiff does not enforce --allow-external-refs=false on the git-revision load path (SSRF / local file read)
위협 신호 · CVSS · EPSS · KEV
이론적 심각도 점수
예측 데이터 없음
실측 악용 기록 없음
계획된 패치 주기 내 조치(60일 이내)
CVSS 벡터 · 메트릭
CVSS 벡터 정보 없음
상세 설명
Summary
From v1.13.2 through v1.18.0, oasdiff did not enforce --allow-external-refs=false (library: openapi3.Loader.IsExternalRefsAllowed = false) when loading a spec from a git revision (the rev:path form, e.g. main:openapi.yaml). External $refs were resolved on that load path even when external refs were explicitly disabled, so the mitigation silently did not apply there.
Impact
A caller who set --allow-external-refs=false specifically to safely process untrusted specs remained exposed — on the git-revision load path only — to:
- SSRF via
$ref: "http://<internal-host>/…", and - Local file reads via
$ref: "/path"orfile://.
Affected callers:
- CLI:
oasdiff diff main:openapi.yaml HEAD:openapi.yaml --allow-external-refs=false(andbreaking/changelog/summary, and thegit-diff-driver) run over untrusted spec content. - Go library consumers of
github.com/oasdiff/oasdiff/loadthat setIsExternalRefsAllowed = falseand load from a git-revision source viaload.NewSpecInfo.
The file and URL load paths correctly enforced the setting; only the git-revision path was affected. Callers that left external refs at the default (true) are not in scope for this advisory.
Patches
v1.18.1 enforces the external-refs policy on the git-revision path (so --allow-external-refs=false now blocks external $refs there) and returns a dedicated exit code (123) when an external $ref is refused.
Workarounds
- Upgrade to v1.18.1, or
- Avoid the git-revision input form when processing untrusted specs with external refs disabled.
Notes
- Introduced in v1.13.2 (#832, which added
$ref-chain resolution on the git-revision path); fixed in v1.18.1 (#974, #975). - The permissive default (
allow-external-refs: true) and its zero-interaction exposure in CI via the GitHub Action is tracked separately in GHSA-fhj3-7267-7vv5 (oasdiff-action).
AI 심층 분석
공격 시나리오 · 재현 가능한 PoC 페이로드 · 즉시 적용 가능한 차단 패치를 한 번에 받아 보세요. 보안 운영팀이 그대로 점검·티켓팅에 쓸 수 있는 형태로 정리해 드립니다.