Index of every page on this site: llms.txt
All skills
jeremylongshore avatar

/sentry-data-handling

@0d57af8
Run it yourself

Configure GDPR-compliant data handling, PII scrubbing, and data retention policies in Sentry. Use when implementing beforeSend filters, server-side data scrubbing rules, IP anonymization, data subject deletion requests, or SOC 2 audit controls. Trigger with phrases like "sentry pii scrubbing", "sentry gdpr", "sentry data privacy", "scrub sensitive data sentry", "sentry data retention", "sentry compliance".

Use this Skill: https://skilld.dev/gh/jeremylongshore/tons-of-skills-marketplace/sentry-data-handling

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencespii-scrubbing.md

≈502 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Pii Scrubbing

PII Scrubbing

Built-in Data Scrubbing

Sentry.init({
  dsn: process.env.SENTRY_DSN,

  // Enable server-side scrubbing
  sendDefaultPii: false, // Default

  // Client-side scrubbing
  beforeSend(event) {
    // Remove sensitive headers
    if (event.request?.headers) {
      delete event.request.headers['Authorization'];
      delete event.request.headers['Cookie'];
      delete event.request.headers['X-API-Key'];
    }
    return event;
  },
});

Custom Data Scrubbing

Sentry.init({
  dsn: process.env.SENTRY_DSN,

  beforeSend(event, hint) {
    // Scrub email addresses
    if (event.user?.email) {
      event.user.email = '[REDACTED]';
    }

    // Scrub credit card numbers
    const ccRegex = /\b\d{4}[-\s]?\d{4}[-\s]?\d{4}[-\s]?\d{4}\b/g;
    if (event.message) {
      event.message = event.message.replace(ccRegex, '[CREDIT_CARD]');
    }

    // Scrub phone numbers
    const phoneRegex = /\b\d{3}[-.]?\d{3}[-.]?\d{4}\b/g;
    if (event.extra) {
      event.extra = JSON.parse(
        JSON.stringify(event.extra).replace(phoneRegex, '[PHONE]')
      );
    }

    return event;
  },
});

Scrub Specific Fields

function scrubSensitiveData(obj: Record<string, unknown>): Record<string, unknown> {
  const sensitiveKeys = [
    'password', 'secret', 'token', 'apiKey', 'api_key',
    'ssn', 'social_security', 'credit_card', 'cvv',
  ];

  return Object.entries(obj).reduce((acc, [key, value]) => {
    if (sensitiveKeys.some(k => key.toLowerCase().includes(k))) {
      acc[key] = '[FILTERED]';
    } else if (typeof value === 'object' && value !== null) {
      acc[key] = scrubSensitiveData(value as Record<string, unknown>);
    } else {
      acc[key] = value;
    }
    return acc;
  }, {} as Record<string, unknown>);
}

Sentry.init({
  dsn: process.env.SENTRY_DSN,
  beforeSend(event) {
    if (event.extra) {
      event.extra = scrubSensitiveData(event.extra);
    }
    return event;
  },
});

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts2mo3 checks · Risk SAFE
  • Gen Agent Trust Hub2mo

    The skill provides patterns for PII scrubbing and GDPR compliance with Sentry. It includes network operations to the Sentry API and a potential vulnerability to indirect prompt injection where user-provided identifiers are used in API search queries without sanitization.

  • Socket2mo

    No alerts

  • Snyk2mo

    Risk: LOW · No issues

Signed by skilld at 0d57af8. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 3 months ago
What it can do
Reads files Edits files Runs commands
version
1.51.0
author
Jeremy Longshore <jeremy@intentsolutions.io>
compatibility
Designed for Claude Code
All 6 allowed tools
ReadWriteEditGrepBash(curl:*)Bash(node:*)
Other metadata
tags
[
  "saas",
  "sentry",
  "security",
  "compliance",
  "gdpr",
  "pii",
  "data-privacy"
]

README badge

README badge for jeremylongshore/tons-of-skills-marketplace/sentry-data-handling