Proof Portal

Project overview

litellm

BerriAI117 findings · 107 requirements

LiteLLM Python->Rust migration audit (proof mirroring).

93 withheld (location undisclosed)

All requirements
RequirementSW-REQ-260802-P100SoftwareDraft

validate_anthropic_messages_environment builds Azure authentication headers for the /v1/messages endpoint via BaseAzureLLM._base_validate_azure_environment (resolving an Azure api-key or Entra Bearer from litellm_params, into which the api_key parameter is injected), then converts a resolved api-key header to x-api-key iff an api-key header is present and no x-api-key header is already present, sets anthropic-version to 2023-06-01 and content-type to application/json when each is absent, applies anthropic-beta headers, and never logs the credential

All automated checks pass and 2/2 obligations are satisfied. Human review is still pending.
PriorityshallTypeguaranteeCategoryfunctionalComponentazure_messagesAssuranceEFindingsnone open

Specification

The requirement exactly as authored — its complete prose text and, where present, the formal FRETish sentence it compiles to.

Description

validate_anthropic_messages_environment builds Azure authentication headers for the /v1/messages endpoint via BaseAzureLLM._base_validate_azure_environment (resolving an Azure api-key or Entra Bearer from litellm_params, into which the api_key parameter is injected), then converts a resolved api-key header to x-api-key iff an api-key header is present and no x-api-key header is already present, sets anthropic-version to 2023-06-01 and content-type to application/json when each is absent, applies anthropic-beta headers, and never logs the credential

FRETish formula
the azure_messages shall always satisfy (x_api_key_set <-> (api_key_header_present & !x_api_key_present))
View full formal model

Verification & provenance

How this requirement was checked: the review trail, edit history, and the machine-analysis status terms (each ⓘ explains what it means).

Assurance levelE
Formalizationvalid
Strategyfretish

Review

Status
pending

History

Created
Aug 2, 2026, 00:45 UTC · Claude Opus 4 8 · AI agent
Modified
Aug 2, 2026, 00:45 UTC · Claude Opus 4 8 · AI agent

Change history

Every recorded revision of this requirement's source file — newest first, each with its commit message and the diff for that change.

Obligations

What this requirement must witness to be considered satisfied — the required evidence, and the tests that discharge each one.

2 obligations · 2 discharged

Browse the catalogue
Discharged

Happy-path behavior with valid inputs.

Discharging evidence1/1 required witnessed
  • nominalrequiredpresent
    Covered by 2 tests
Discharged

Authorization headers, session IDs, secrets, and PII never appear in logs.

If it were violatedHigh

If the Azure api-key/x-api-key value or the Entra Bearer Authorization header is written to debug/verbose logs, anyone with access to log aggregation, support bundles, or a shared console exfiltrates a live Azure Foundry credential and can bill usage to the customer and read every prompt they submit

Discharging evidence1/1 required witnessed
  • nominalrequiredpresent
    No covering test recorded
  • negativerecommendedpresent
    No covering test recorded

Formula evidence

The formal formula behind this requirement, the variables it is written over, and the tests that exercise it (each term is explained inline).

FRETish formula

the azure_messages shall always satisfy (x_api_key_set <-> (api_key_header_present & !x_api_key_present))

MC/DC truth table· 5 rows

Each row assigns the formula's conditions (T/F) and shows the Result— the formula's value for that input row, not a test pass/fail. A row proves a condition when flipping only that condition flips the outcome. The test that covers each row is linked.

Covereda test exercises this rowExempteda reviewed mcdc:ignoreNo-actionfalse-result row satisfied by designUncoveredneeds a covering test
#api_key_header_presentx_api_key_presentx_api_key_setResultProvesCovering test
1FFFTapi_key_header_present—
2FFTFx_api_key_setExempted · defensive — x_api_key_set records the api-key->x-api-key move; with no api-key header present the move never happens, so a set=T outcome is unreachable in a correct build (reviewed: agent:claude-opus-4-8)
3TFFFapi_key_header_presentExempted · defensive — when an api-key header is present and no x-api-key exists the conversion always fires, so a present-key-yet-unset state is unreachable in a correct build (reviewed: agent:claude-opus-4-8)
4TFTTx_api_key_present—
5TTTFx_api_key_presentExempted · defensive — an existing x-api-key is never overwritten by the api-key conversion, so a set=T outcome when x-api-key is already present is unreachable in a correct build (this test pins the reachable no-overwrite behavior) (reviewed: agent:claude-opus-4-8)

Its place

How this requirement connects — what proves it, what it affects, and what it rests on. Authored links only here; automatically derived links come from the audit index.

Loading graph…

Trace evidence

The concrete artifacts linked to this requirement — implementing code, verifying tests, documents, and the findings raised against it.

Mirrors

Ports this requirement participates in — it carries a reviewed exemption on one side, or a finding raised against it is tracked as part of the port.

  • Azure AI messages: Python -> RustMIR-008
    DiffersPython → Rust
    View in Mirrors

Impact

Blast radius — authored trace links only (automatically derived links come from the audit index and aren't shown here).

If you change this

Requirements
0
Files
2
Tests
0
At-risk contracts
0

Files to re-check (2)

  • messages_transformation.pylitellm/llms/azure_ai/anthropic/messages_transformation.py
  • transformation.rslitellm-rust/crates/core/src/providers/azure_ai/messages/transformation.rs

What this rests on

Discussions

Discuss this with the proof team. Nothing changes in your audit automatically — you open a request and a staff member records any outcome inside the thread.

Sign in to discuss this with the proof team.Sign in