Enforce source-time provenance across ingest
This commit is contained in:
@@ -31,6 +31,13 @@ func TestClientCallsProductionV2Endpoints(t *testing.T) {
|
||||
if r.Header.Get("Idempotency-Key") == "" {
|
||||
t.Fatalf("idempotency key missing")
|
||||
}
|
||||
var payload map[string]any
|
||||
if err := json.NewDecoder(r.Body).Decode(&payload); err != nil {
|
||||
t.Fatalf("decode event body: %v", err)
|
||||
}
|
||||
if payload["occurredAt"] == "" {
|
||||
t.Fatalf("occurredAt missing from event body")
|
||||
}
|
||||
json.NewEncoder(w).Encode(EventReceipt{
|
||||
StreamID: "str_123", StreamEventID: "evt_123", SeqNo: 1, EventHash: strings.Repeat("a", 64), StreamHeadHash: strings.Repeat("b", 64),
|
||||
Receipt: SignedReceipt{Payload: M{}, ReceiptHash: strings.Repeat("c", 64), Signature: ReceiptSignature{Alg: "ed25519"}},
|
||||
|
||||
Reference in New Issue
Block a user