Skip to content
Back to skills

2149 Signature Verification Ea328765

ASecurity

```typescript function verifyVercelSignature( payload: Buffer, signature: string, timestamp: string ): boolean { const secret = process.env.VERCEL_WEBHOOK_SECRET!;

  • 11 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added October 11, 2026
testingtypescript

Security analysis

A100/100

Scanned October 11, 2026

npx -y skills add tools-only/X-Skills --skill 2149-signature-verification_ea328765 --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of 2149 Signature Verification Ea328765?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for 2149 Signature Verification Ea328765
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tools-only-2149-signature-verification-ea328765/badge)](https://www.skillsdirectory.com/skills/tools-only-2149-signature-verification-ea328765)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

SKILL.md
# Signature Verification

## Signature Verification

```typescript
function verifyVercelSignature(
  payload: Buffer,
  signature: string,
  timestamp: string
): boolean {
  const secret = process.env.VERCEL_WEBHOOK_SECRET!;

  // Reject old timestamps (replay attack protection)
  const timestampAge = Date.now() - parseInt(timestamp) * 1000;
  if (timestampAge > 300000) { // 5 minutes
    console.error('Webhook timestamp too old');
    return false;
  }

  // Compute expected signature
  const signedPayload = `${timestamp}.${payload.toString()}`;
  const expectedSignature = crypto
    .createHmac('sha256', secret)
    .update(signedPayload)
    .digest('hex');

  // Timing-safe comparison
  return crypto.timingSafeEqual(
    Buffer.from(signature),
    Buffer.from(expectedSignature)
  );
}
```

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in testing →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.