verify
suspend fun verify(signatureHeader: String?, xStellarSignatureHeader: String?, body: String): CallbackSignatureVerifier.Result
Verifies a callback signature against the registered URL's host and the supplied body.
The verifier prefers signatureHeader over xStellarSignatureHeader when both are provided. A malformed Signature returns Result.MalformedHeader even when the legacy header would have verified — the preference is firm.
Return
Result.Valid on success; one of Result.MissingHeader, Result.MalformedHeader, Result.Stale, or Result.SignatureMismatch on failure.
Parameters
signature Header
Value of the Signature HTTP header, or null if absent.
x Stellar Signature Header
Value of the deprecated X-Stellar-Signature HTTP header, or null if absent.
body
The byte-exact inbound request body, decoded as UTF-8.