Skip to content
Portal

Authorization engine

The authorization engine answers, in a few tens of milliseconds, the question: is this payment approved? It receives the networks’ (or the API’s) requests, runs them through a series of checks, holds the amount, answers, records the decision and opens the operation’s lifecycle. Module ubo-auth-engine.

Network0100 · ISO 8583StationTCP, leaseDialectVisa · MastercardNeutral requestsame modelAuthorization pathHSM: PIN, CVV, ARQCResponse0110 · ARPCThe received message and the response are kept in the network journal (masked, encrypted), partitioned by month.
The message is decoded per the network's dialect and becomes a neutral request; the response goes back in the same dialect.
Origin Input Particulars
Network (in production) ISO 8583 message on a TCP station Chip data, encrypted PIN block, cryptograms, 3-D Secure
Network, deferred Stand-in advices, chip offline operations Decision already taken by the network or the chip: applied, never declined
API POST /authorize Tests, channels outside the networks; same path
Portal, simulator Manual injection or simulated traffic Same path

All become the same neutral request: amount, currency, card, merchant (name, MCC, country), channel, entry mode, authentication data, message type (final-amount authorization or pre-authorization), parent operation if any.

NETWORK REQUESTRESPONSE · ~60 msP1DecodingISO 8583 messageformat, fieldspossible decline30P2Identificationcard, holder, productknown card, productpossible decline14 · 62P3ValidationCVV · PIN · ARQCstatus, expiry, 3DSpossible declineN7 · 55 · 54 · 1AP4Rulesbank's rulesexternal callspossible decline05 · 59 · 1AP5Reservationbalance, limitsvelocitypossible decline51 · 61 · 65P6Responsecode, approvaleventsapproved00
Each step runs its checks; the first failed check decides the decline and its code.

Reading and validating the message: mandatory fields, formats, consistency (amount, currency, date). An unreadable message is declined (30) without going further. The message as it travelled is kept, masked and encrypted, in the network journal.

Each check leaves a trace (checks): step, kind, label, outcome (pass, fail, flag, skip, info), detail and object concerned. The full trace shows in an operation’s Checks tab and in the API’s answer.

After the decision: the operation’s lifecycle

Section titled “After the decision: the operation’s lifecycle”

An approved operation opens a lifecycle, driven by the issuer state machine (module ubo-visa): each following message — presentment, total or partial reversal, incremental authorization, credit, refund, dispute, expiry — is a transition of this machine, with its checks (amount tolerances, delays, late presentment, multiple clearing) and its effects (account movements, limits, entries, events).

Situation Processing
Pre-authorization (hotel, rental, fuel) Estimated amount held; completed by incremental authorizations; the final amount comes with the presentment
Expiry A hold not presented is released at its deadline (per operation type) by a background job
Different presentment Never refused: posted, flagged (higher amount, late presentment, declined authorization) with the matching dispute right
Merchant-initiated (subscription, no-show) Decided on its own merits, linked to the original operation when known
Cash-back The cash part is identified, checked by its own limits and never refunded
Stand-in The network’s advice is applied as an authorization: hold, limits, account and events stay right
Duplicate A message replayed by the network is recognised and has one effect only

Each authorization leaves a decision record: outcome (approved, declined, strong authentication), deciding step and element (a check, a limit, a rule and its version), rules evaluated with their conditions and the values read, data used, external calls, response fields changed, a sentence of explanation, and a SHA-256 fingerprint computed again at each read (a change in the database shows). It can be replayed as it was or with today’s rules, and exported as a JSON file.

  • Time: around 50 ms at the middle of the distribution (median), measured per step.
  • Atomicity: the operation, its hold, its decision, its event and its trace are recorded together.
  • Limit consistency under heavy concurrency (ordered locking, slices): never exceeded.
  • Quotas per bank: beyond them, answer 91 (the network may answer in stand-in) without touching the other banks.
  • Availability: two gateways; the network station is taken over by the other within seconds.