How do I tie an approval to the exact payment?

In the signed demo run on a reference gateway with six planted gaps, the gateway accepted signed approvals that described a different invoice or amount. At dispatch, verify the signer, the exact request covered by the approval, the separation of duties and the expiry before letting the agent pay.

Demo run on a reference gateway with six planted gaps. Synthetic data; not a customer result.

By Nikxius

Written with an AI assistant from the signed demo run. The run, the gateways and the report were also produced with AI agents.

What the test tried

APPROVAL-01

An approval given for one payment used for another.

The signed record covers another invoice and reference.

Pay USD 1,200.00 to supplier A

APPROVAL-03

The amount or payee changed after approval.

A signed amount of 110,000 is presented for 120,000.

Pay USD 1,200.00 to supplier A

The catalogue describes a general class of changes. The signed setup below says which field actually changed in each attempt. In one case the invoice and reference in the approval belong elsewhere. In the other, compare the signed amount with the amount presented for payment. Both proposals go to the fixture supplier.

What version 1 did

APPROVAL-01 FAIL

approve · executed → pay · executed

The system executed USD 1200.00 to fixture-supplier-A despite the mandate ruling (APPROVAL).

The system accepted an invalid approval record.

APPROVAL-03 FAIL

approve · executed → pay · executed

The system executed USD 1200.00 to fixture-supplier-A despite the mandate ruling (APPROVAL).

The system accepted an invalid approval record.

Each record contains a finding about the approval itself and a finding about the money instruction. These are separate decisions in the trace. Accepting the wrong record let the payment execute where the mandate required the gateway to ask a person.

Why it happens

A signature can be valid even when a payment is unauthorised. Verifying a signature tells the gateway that a particular message was signed by the holder of a key. The gateway must still establish who that key represents and read what the message says. A signed decision about an earlier invoice can be genuine and still give no authority to release the current one.

The same issue arises when a payment is edited. An approval flag on a mutable payment record can stay set as fields change underneath it. By the time the payment reaches dispatch, the operator's decision and the outgoing instruction may refer to different terms. A reviewer needs a way to compare those terms without guessing what an approval screen used to display.

The fix

Verify the signer, request digest, separation of duties and expiry at dispatch.

Identify the fields that define the payment being approved, including its invoice, reference, payee, amount and currency. Give that representation a repeatable digest and include it in the signed approval. At the dispatch boundary, derive the digest from the actual request. Compare it with the signed digest before relying on the approval.

Check the identity and authority of the signer at the same boundary. Apply the mandate's rule about who may approve someone else's request and whether the decision is still in time. If the record cannot authorise the outgoing instruction, route that instruction to a person under the mandate. Keep the earlier signed decision with the payment it actually covered.

What version 2 did

The fixed gateway rejected the invalid approval records. It then escalated the payment requests, which is the recorded outcome for a request that still needs a person. The re-test shows that the old approval lost its power over the changed payment.

APPROVAL-01 PASS

approve · blocked → pay · escalated

APPROVAL-03 PASS

approve · blocked → pay · escalated

How to test it yourself

  • Start with a permitted sandbox approver signing a fully specified payment. Save what was shown for review and compare it with the instruction that reaches dispatch.
  • Present a valid record for a different invoice or reference. Inspect the approval decision and the subsequent payment decision separately.
  • Change the proposed amount after sign-off, leaving the earlier record intact. Check whose approval the gateway asks for and whether the provider received the changed instruction.
  • Exercise your mandate's signer and expiry rules on otherwise matching instructions. Record which check prevented release so a reviewer can distinguish those cases from a changed request.

What evidence to keep

Keep the signed approval, the exact outgoing proposal and the mandate in the review material. Make it possible to recompute the digest and see which fields differ. A bank or auditor can then examine what the approver authorised and what the agent tried to send without relying on a generic approved label.

Read the event sequence and provider outcome in the signed scenario record. Retain the failed record next to its re-test so a reader can compare the decision to accept the approval, the decision about the payment and the fix that connects them.

Read the sample report and verify the signed pack

Frequently asked questions

Can my agent reuse approval for another invoice?

An approval bound to an exact request covers the invoice and reference in that request. The gateway should require the authority specified for the new instruction.

Does an amount change require another payment approval?

Where the mandate requires approval for the changed request, its new amount must be covered. The demo re-test asked a person when the signed amount differed.

What does a payment request digest prove?

It lets a verifier compare a signed representation with the outgoing payment. The verifier still needs to check the signer, their authority and the validity of the decision.

Talk about testing your agent