Skip to content

fix(stripe): guard invalid webhook tolerance config - #873

Open
aiirvizionz wants to merge 1 commit into
profullstack:masterfrom
aiirvizionz:clientkit/stripe-session-timeout-guard
Open

fix(stripe): guard invalid webhook tolerance config#873
aiirvizionz wants to merge 1 commit into
profullstack:masterfrom
aiirvizionz:clientkit/stripe-session-timeout-guard

Conversation

@aiirvizionz

Copy link
Copy Markdown
Contributor

Summary

  • Keep Stripe webhook timestamp tolerance enforcement active when config receives invalid numeric values.
  • Preserve the existing explicit { webhookToleranceSeconds: 0 } escape hatch for disabling timestamp checks.
  • Add a regression test showing NaN falls back to the default tolerance instead of bypassing stale-signature protection.

Validation

  • git diff --check

I attempted pnpm vitest run packages/payments/stripe/src/index.test.ts and pnpm --filter @profullstack/sh1pt-payment-stripe typecheck, but this checkout stops during dependency preparation because the committed lockfile fails the active supply-chain policy: @profullstack/autoblog@0.4.0 has no tarball integrity field. I did not modify the lockfile; the regression test is included for maintainers' normal CI/runtime.

Copilot AI review requested due to automatic review settings July 29, 2026 04:27

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants