Dev.to Security 🔐 Cybersecurity 👁 1 📖 22 min read

n8n for CyberSecurity SaaS Vendors: 5 Automations for SEC §229.106, CMMC 2.0, and SOC 2 (Free JSON)

CyberSecurity SaaS vendors — MSSPs, MDR providers, EDR vendors, SIEM platforms, and SOC-as-a-Service companies — are themselves subject to a growing stack of compliance obligations that most generic automation guides ign

CyberSecurity SaaS vendors — MSSPs, MDR providers, EDR vendors, SIEM platforms, and SOC-as-a-Service companies — are themselves subject to a growing stack of compliance obligations that most generic automation guides ignore. You are not just helping customers with their compliance; you are on the hook for your own.

This article covers five production-ready n8n workflows built specifically for cybersecurity SaaS vendor operations: customer onboarding drip, SOC ops API health monitor, SEC/FTC/CMMC/SOC2/ISO27001 deadline tracker, SEC material incident disclosure pipeline, and weekly ops KPI dashboard. Import-ready JSON for all five workflows is included.

Why CyberSec SaaS Vendors Have a Unique Compliance Problem

You sell security — and you are judged to a higher standard than your customers. When a breach happens, regulators, customers, and courts ask: What did your own systems look like? The specific obligations that create the most operational urgency:

  • SEC 17 CFR §229.106 Material Incident Disclosure: If your company is (or your parent is) a public company, a material cybersecurity incident requires an Item 1.05 Form 8-K within 4 business days of materiality determination — not 4 days from discovery. The materiality determination itself must be documented and defensible. Running that process on a shared-workspace iPaaS like Zapier means your audit trail for the determination lives in Zapier's 30-day task log.

  • FTC Act §5(a) Unfair or Deceptive Practices: The FTC has enforcement precedent against cybersecurity vendors (and their customers) who make security claims they cannot substantiate. If your marketing says '24/7 SOC monitoring' and your incident pipeline is down at 2 AM, §5(a) exposure follows. The FTC's LabMD case established that even one unremediated configuration gap is an 'unreasonable practice.'

  • CMMC 2.0 Level 2 Annual Affirmation: If you sell to DoD prime contractors or directly to DoD, your CMMC Level 2 status requires an annual self-affirmation in SPRS (Supplier Performance Risk System) and a C3PAO assessment every 3 years. Missing the affirmation date = lapse in DoD contract eligibility. There is no grace period under 32 CFR Part 170.

  • SOC 2 Type II as a Revenue Gate: Enterprise buyers require SOC 2 Type II before signing. Control failures discovered mid-audit generate findings that can delay renewals by 60-90 days — a material revenue risk for an ARR-driven SaaS business. The AICPA Trust Services Criteria CC7.4 requires documented incident response procedures.

  • The iPaaS Irony: A cybersecurity SaaS vendor running its own compliance operations on Zapier or Make.com is doing exactly what its sales team warns customers against — routing sensitive security operations data through a third-party multi-tenant cloud. A penetration testing firm running its engagement tracking on Zapier; a SIEM vendor routing alert metadata through Zapier's shared infrastructure; an MSSP with customer incident data in Zapier task logs — all of these create the same data sovereignty gap the vendor's own pitch deck identifies as a risk.

Customer Tiers

ENTERPRISE_MSSP         $50M+ ARR or 500+ employees
MID_MARKET_MDR          $10M+ ARR or 100+ employees
EDR_VENDOR              Endpoint detection & response SaaS product
SIEM_PLATFORM           Security information & event management SaaS
VULNERABILITY_MGMT_SAAS Vulnerability scanning & management SaaS
SOC_AS_A_SERVICE        Managed SOC / MDR service provider
PENETRATION_TESTING_PLATFORM  Pen test management / attack surface SaaS

Compliance Flags

SEC_CYBERSECURITY_DISCLOSURE_APPLICABLE  Public company or subsidiary — 4-day 8-K clock
CMMC_ASSESSOR_ACCREDITED                 C3PAO accredited — triennial assessment cycle
FTC_ACT_SECTION_5                        All US vendors — unfair/deceptive practices standard
SOC2_TYPE2_CERTIFIED                     Annual audit engagement in scope
NIST_CSF_ALIGNED                         NIST CSF 2.0 Govern function maturity tracking
ISO_27001_CERTIFIED                      Annual surveillance + 3yr recertification cycle
NY_SHIELD_ACT_APPLICABLE                 NY personal data in scope — training + notification

Workflow 1 — Customer Onboarding Drip

Trigger: Google Sheets row added (new customer signed)

What it does: Classifies the customer into one of 7 tiers plus 7 compliance flags, sends a Day 0 compliance setup email tailored to their tier, logs to Postgres (SOC 2 CC7.1 audit trail), waits 3 days for Day 3 SIEM/EDR integration tips, waits 4 more days for Day 7 SOC 2 control evidence automation guide.

{
  "name": "CyberSecurity SaaS Vendor \u2014 Customer Onboarding Drip",
  "nodes": [
    {
      "id": "1",
      "name": "New Customer Trigger",
      "type": "n8n-nodes-base.googleSheetsTrigger",
      "parameters": {
        "sheetId": "YOUR_SHEET_ID",
        "range": "Customers!A:Z",
        "event": "rowAdded"
      },
      "position": [
        100,
        300
      ]
    },
    {
      "id": "2",
      "name": "Classify Tier & Flags",
      "type": "n8n-nodes-base.code",
      "parameters": {
        "jsCode": "\nconst r = $input.first().json;\nconst arr = Number(r.arr_usd || 0);\nconst employees = Number(r.employees || 0);\nconst soc = String(r.soc_analysts || 0);\nlet tier = 'BOUTIQUE_PENTEST_FIRM';\nif (arr >= 50000000 || employees >= 500) tier = 'ENTERPRISE_MSSP';\nelse if (arr >= 10000000 || employees >= 100) tier = 'MID_MARKET_MDR';\nelse if (String(r.product_type||'').includes('EDR')) tier = 'EDR_VENDOR';\nelse if (String(r.product_type||'').includes('SIEM')) tier = 'SIEM_PLATFORM';\nelse if (String(r.product_type||'').includes('VULN')) tier = 'VULNERABILITY_MGMT_SAAS';\nelse if (String(r.product_type||'').includes('SOC')) tier = 'SOC_AS_A_SERVICE';\nconst flags = {\n  SEC_CYBERSECURITY_DISCLOSURE_APPLICABLE: String(r.sec_registrant||'') === 'true',\n  CMMC_ASSESSOR_ACCREDITED: String(r.cmmc_c3pao||'') === 'true',\n  FTC_ACT_SECTION_5: String(r.ftc_applicable||'') !== 'false',\n  SOC2_TYPE2_CERTIFIED: String(r.soc2_certified||'') === 'true',\n  NIST_CSF_ALIGNED: String(r.nist_csf||'') === 'true',\n  ISO_27001_CERTIFIED: String(r.iso27001||'') === 'true',\n  NY_SHIELD_ACT_APPLICABLE: String(r.ny_customers||'') === 'true'\n};\nreturn [{json: {...r, tier, flags, onboarding_start: new Date().toISOString()}}];\n"
      },
      "position": [
        300,
        300
      ]
    },
    {
      "id": "3",
      "name": "Day 0 \u2014 Welcome + Compliance Setup",
      "type": "n8n-nodes-base.gmail",
      "parameters": {
        "operation": "send",
        "to": "={{ $json.email }}",
        "subject": "Welcome to {{ $json.product_name }} \u2014 Your Compliance Automation Setup",
        "message": "={{ 'Hi ' + $json.name + ',\\n\\nWelcome! Here is your Day 0 compliance checklist based on your tier (' + $json.tier + '):\\n\\n' + ($json.flags.SEC_CYBERSECURITY_DISCLOSURE_APPLICABLE ? '\u2022 SEC 17 CFR \u00a7229.106: Wire your material incident pipeline now \u2014 4 business days from discovery, no extensions.\\n' : '') + ($json.flags.CMMC_ASSESSOR_ACCREDITED ? '\u2022 CMMC 2.0: Confirm your C3PAO accreditation annual affirmation is scheduled.\\n' : '') + ($json.flags.SOC2_TYPE2_CERTIFIED ? '\u2022 SOC 2 Type II: Continuous control monitoring starts at onboarding \u2014 export your control evidence log weekly.\\n' : '') + '\\nYour CSM will follow up in 3 days.\\n\\nTeam ' + $json.product_name }}"
      },
      "position": [
        500,
        200
      ]
    },
    {
      "id": "4",
      "name": "Log to Postgres",
      "type": "n8n-nodes-base.postgres",
      "parameters": {
        "operation": "executeQuery",
        "query": "INSERT INTO cyber_onboarding (customer_id, email, tier, flags, onboarded_at) VALUES ('{{ $json.customer_id }}','{{ $json.email }}','{{ $json.tier }}','{{ JSON.stringify($json.flags) }}'::jsonb, NOW()) ON CONFLICT (customer_id) DO UPDATE SET tier=EXCLUDED.tier, flags=EXCLUDED.flags, onboarded_at=NOW()"
      },
      "position": [
        500,
        400
      ]
    },
    {
      "id": "5",
      "name": "Wait 3 Days",
      "type": "n8n-nodes-base.wait",
      "parameters": {
        "amount": 3,
        "unit": "days"
      },
      "position": [
        700,
        300
      ]
    },
    {
      "id": "6",
      "name": "Day 3 \u2014 Threat Detection & SIEM Integration Tips",
      "type": "n8n-nodes-base.gmail",
      "parameters": {
        "operation": "send",
        "to": "={{ $json.email }}",
        "subject": "Day 3 \u2014 Connecting n8n to Your SIEM & EDR Stack",
        "message": "={{ 'Hi ' + $json.name + ',\\n\\nDay 3 tips for ' + $json.tier + ':\\n\\n\u2022 n8n Webhook node \u2192 your SIEM alert pipeline (Splunk/Elastic/Microsoft Sentinel webhook)\\n\u2022 HTTP Request node \u2192 EDR API (CrowdStrike/SentinelOne/Carbon Black REST) for real-time endpoint status\\n\u2022 Postgres ON CONFLICT DO NOTHING deduplication on alert_id\\n\\nThis is your foundation for the SEC \u00a7229.106 4-day incident materiality determination workflow.\\n\\nSee you at Day 7.\\n\\nTeam ' + $json.product_name }}"
      },
      "position": [
        900,
        300
      ]
    },
    {
      "id": "7",
      "name": "Wait 4 Days",
      "type": "n8n-nodes-base.wait",
      "parameters": {
        "amount": 4,
        "unit": "days"
      },
      "position": [
        1100,
        300
      ]
    },
    {
      "id": "8",
      "name": "Day 7 \u2014 SOC 2 Control Evidence & Audit Trail",
      "type": "n8n-nodes-base.gmail",
      "parameters": {
        "operation": "send",
        "to": "={{ $json.email }}",
        "subject": "Day 7 \u2014 Automate Your SOC 2 Control Evidence Collection",
        "message": "={{ 'Hi ' + $json.name + ',\\n\\nFinal onboarding check-in:\\n\\n\u2022 SOC 2 CC7.2: n8n logs every alert, response, and escalation to Postgres with immutable timestamps\\n\u2022 NIST CSF 2.0 Govern function: workflow version history in Git = auditor-ready change log\\n\u2022 ISO 27001:2022 \u00a79.1: scheduled evidence exports to your auditor folder weekly\\n\\nSchedule your 30-day compliance review with your CSM.\\n\\nTeam ' + $json.product_name }}"
      },
      "position": [
        1300,
        300
      ]
    }
  ],
  "connections": {
    "New Customer Trigger": {
      "main": [
        [
          {
            "node": "Classify Tier & Flags",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Classify Tier & Flags": {
      "main": [
        [
          {
            "node": "Day 0 \u2014 Welcome + Compliance Setup",
            "type": "main",
            "index": 0
          },
          {
            "node": "Log to Postgres",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Day 0 \u2014 Welcome + Compliance Setup": {
      "main": [
        [
          {
            "node": "Wait 3 Days",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait 3 Days": {
      "main": [
        [
          {
            "node": "Day 3 \u2014 Threat Detection & SIEM Integration Tips",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Day 3 \u2014 Threat Detection & SIEM Integration Tips": {
      "main": [
        [
          {
            "node": "Wait 4 Days",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait 4 Days": {
      "main": [
        [
          {
            "node": "Day 7 \u2014 SOC 2 Control Evidence & Audit Trail",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Workflow 2 — SOC Ops & Threat Detection API Health Monitor

Trigger: Every 3 minutes

What it does: Pings 5 critical endpoints (SIEM ingestion, EDR, threat intel, vulnerability scan, incident response APIs), classifies status (OK / DOWN / AUTH_ERROR / DEGRADED) using $getWorkflowStaticData to detect UP→DOWN transitions only (no alert storms), fires Slack to #soc-ops, logs to Postgres cyber_incidents with ON CONFLICT DO NOTHING.

Why this matters for SEC §229.106: The SEC explicitly states that the 4-day clock runs from when the company determines the incident is material — not from when it was first detected. Having a timestamped API monitor log in Postgres gives your GC a documented timeline of when each system was confirmed down vs. degraded, which is the foundation of the materiality determination memo.

Endpoint Regulatory Annotation
siem_ingestion_api SOC 2 CC7.2 — log all alert events for auditor
edr_endpoint_api NIST CSF 2.0 DE.CM-4 — endpoint monitoring continuity
threat_intel_api NIST CSF 2.0 ID.RA-2 — threat intelligence feed availability
vulnerability_scan_api NIST CSF 2.0 ID.RA-1 — asset vulnerability identification
incident_response_api NIST CSF 2.0 RS.RP-1 + SEC §229.106 4-day clock trigger
{
  "name": "CyberSec SaaS \u2014 SOC Ops & API Health Monitor",
  "nodes": [
    {
      "id": "1",
      "name": "Every 3 Minutes",
      "type": "n8n-nodes-base.scheduleTrigger",
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "minutes",
              "minutesInterval": 3
            }
          ]
        }
      },
      "position": [
        100,
        300
      ]
    },
    {
      "id": "2",
      "name": "Load Endpoints from Postgres",
      "type": "n8n-nodes-base.postgres",
      "parameters": {
        "operation": "executeQuery",
        "query": "SELECT endpoint_name, url, regulatory_annotation FROM cyber_endpoints WHERE active = true"
      },
      "position": [
        300,
        300
      ]
    },
    {
      "id": "3",
      "name": "Split by Endpoint",
      "type": "n8n-nodes-base.splitInBatches",
      "parameters": {
        "batchSize": 1
      },
      "position": [
        500,
        300
      ]
    },
    {
      "id": "4",
      "name": "Ping Endpoint",
      "type": "n8n-nodes-base.httpRequest",
      "parameters": {
        "url": "={{ $json.url }}",
        "method": "GET",
        "timeout": 8000,
        "ignoreResponseCode": true
      },
      "position": [
        700,
        300
      ]
    },
    {
      "id": "5",
      "name": "Classify Status",
      "type": "n8n-nodes-base.code",
      "parameters": {
        "jsCode": "\nconst ep = $('Load Endpoints from Postgres').first().json;\nconst res = $input.first().json;\nconst status_code = res.$response?.statusCode || 0;\nconst latency = res.$response?.headers?.['x-response-time'] || 0;\nlet status = 'OK';\nlet severity = 'INFO';\nif (status_code === 0 || status_code >= 500) { status = 'DOWN'; severity = 'CRITICAL'; }\nelse if (status_code === 401 || status_code === 403) { status = 'AUTH_ERROR'; severity = 'HIGH'; }\nelse if (Number(latency) > 3000) { status = 'DEGRADED'; severity = 'WARNING'; }\nconst state_key = 'status_' + ep.endpoint_name;\nconst prev = $getWorkflowStaticData('global')[state_key] || 'OK';\nconst changed = prev !== status;\n$getWorkflowStaticData('global')[state_key] = status;\nreturn [{json: {...ep, status, severity, changed, status_code, latency}}];\n"
      },
      "position": [
        900,
        300
      ]
    },
    {
      "id": "6",
      "name": "Only Alert on Change",
      "type": "n8n-nodes-base.if",
      "parameters": {
        "conditions": {
          "boolean": [
            {
              "value1": "={{ $json.changed }}",
              "value2": true
            }
          ]
        }
      },
      "position": [
        1100,
        300
      ]
    },
    {
      "id": "7",
      "name": "Slack #soc-ops Alert",
      "type": "n8n-nodes-base.slack",
      "parameters": {
        "channel": "#soc-ops",
        "text": "={{ ':' + ($json.severity === 'CRITICAL' ? 'red_circle' : 'warning') + ': *' + $json.endpoint_name + '* is ' + $json.status + ' (' + $json.status_code + ') \u2014 ' + $json.regulatory_annotation }}"
      },
      "position": [
        1300,
        200
      ]
    },
    {
      "id": "8",
      "name": "Log Incident to Postgres",
      "type": "n8n-nodes-base.postgres",
      "parameters": {
        "operation": "executeQuery",
        "query": "INSERT INTO cyber_incidents (endpoint_name, status, severity, status_code, regulatory_annotation, detected_at) VALUES ('{{ $json.endpoint_name }}','{{ $json.status }}','{{ $json.severity }}',{{ $json.status_code }},'{{ $json.regulatory_annotation }}',NOW()) ON CONFLICT DO NOTHING"
      },
      "position": [
        1300,
        400
      ]
    }
  ],
  "connections": {
    "Every 3 Minutes": {
      "main": [
        [
          {
            "node": "Load Endpoints from Postgres",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Load Endpoints from Postgres": {
      "main": [
        [
          {
            "node": "Split by Endpoint",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split by Endpoint": {
      "main": [
        [
          {
            "node": "Ping Endpoint",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Ping Endpoint": {
      "main": [
        [
          {
            "node": "Classify Status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Classify Status": {
      "main": [
        [
          {
            "node": "Only Alert on Change",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Only Alert on Change": {
      "main": [
        [
          {
            "node": "Slack #soc-ops Alert",
            "type": "main",
            "index": 0
          },
          {
            "node": "Log Incident to Postgres",
            "type": "main",
            "index": 0
          }
        ],
        []
      ]
    }
  }
}

Workflow 3 — SEC/FTC/CMMC/SOC2/ISO27001 Compliance Deadline Tracker

Trigger: Weekdays at 8 AM

What it does: Reads a Google Sheet with all compliance deadlines, classifies urgency (OVERDUE / CRITICAL ≤4 days / URGENT ≤14 days / WARNING ≤30 days / NOTICE ≤60 days), deduplicates with $getWorkflowStaticData (one alert per deadline per day), routes OVERDUE/CRITICAL to #compliance-ops Slack @here and emails the deadline owner with penalty citation.

Note the 4-day CRITICAL threshold: This is not arbitrary — it matches the SEC §229.106 4-business-day 8-K filing window. Any SEC-related deadline that crosses the 4-day mark fires a CRITICAL alert with the Board Audit Committee notification requirement included in the email body.

Deadline Type Description Regulation Penalty
SEC_10K_CYBERSECURITY_DISCLOSURE Annual 10-K Item 1C — material risks and strategy SEC 17 CFR §229.106(b) SEC enforcement, restatement risk
SEC_8K_MATERIAL_INCIDENT_4DAY 4 business days from materiality determination SEC 17 CFR §229.106(a) + Item 1.05 Form 8-K SEC enforcement, investor litigation
FTC_RED_FLAGS_RULE_ANNUAL_REVIEW Annual review of identity theft Red Flags program FTC 16 CFR Part 681 $50,120/violation
CMMC_ANNUAL_AFFIRMATION Annual CMMC Level 2 self-affirmation in SPRS 32 CFR Part 170 §170.22(c) Debarment from DoD contracts
CMMC_C3PAO_TRIENNIAL_ASSESSMENT CMMC Level 2 C3PAO assessment every 3 years 32 CFR Part 170 §170.17 Loss of DoD contract eligibility
SOC2_TYPE2_ANNUAL Annual SOC 2 Type II audit engagement AICPA TSC + customer contract SLAs Contract termination, enterprise churn
ISO_27001_ANNUAL_SURVEILLANCE ISO 27001:2022 annual surveillance audit ISO/IEC 27001:2022 §9.3 Certificate suspension
ISO_27001_RECERTIFICATION_3YR Full ISO 27001 recertification every 3 years ISO/IEC 27001:2022 §9.3 Certificate lapse
NIST_CSF_ASSESSMENT_ANNUAL Annual NIST CSF 2.0 maturity assessment NIST CSF 2.0 Govern GV.OC-01 Insurance premium increase, RFP disqualification
NY_SHIELD_ACT_ANNUAL_TRAINING Annual employee cybersecurity training for NY data NY SHIELD Act Gen. Bus. Law §899-bb $5,000/violation
STATE_BREACH_NOTIFICATION_REVIEW Annual review of all 50-state breach notification obligations 50-state breach notification laws + GDPR Art.33 AG enforcement, class action risk
ANNUAL_PENTEST Annual penetration test + remediation tracking SOC 2 CC4.1 + CMMC CA.L2-3.12.1 + ISO 27001 §8.8 SOC 2 finding, CMMC deficiency
{
  "name": "CyberSec SaaS \u2014 SEC/FTC/CMMC/SOC2/ISO27001 Compliance Deadline Tracker",
  "nodes": [
    {
      "id": "1",
      "name": "Weekdays at 8 AM",
      "type": "n8n-nodes-base.scheduleTrigger",
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "cronExpression",
              "expression": "0 8 * * 1-5"
            }
          ]
        }
      },
      "position": [
        100,
        300
      ]
    },
    {
      "id": "2",
      "name": "Load Deadlines from Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "parameters": {
        "operation": "getAll",
        "sheetId": "YOUR_DEADLINES_SHEET_ID",
        "range": "Deadlines!A:H"
      },
      "position": [
        300,
        300
      ]
    },
    {
      "id": "3",
      "name": "Classify Urgency",
      "type": "n8n-nodes-base.code",
      "parameters": {
        "jsCode": "\nconst today = new Date();\nreturn $input.all().map(item => {\n  const d = item.json;\n  const due = new Date(d.due_date);\n  const days = Math.ceil((due - today) / 86400000);\n  let urgency = null;\n  if (days < 0) urgency = 'OVERDUE';\n  else if (days <= 4) urgency = 'CRITICAL'; // SEC 4-business-day clock\n  else if (days <= 14) urgency = 'URGENT';\n  else if (days <= 30) urgency = 'WARNING';\n  else if (days <= 60) urgency = 'NOTICE';\n  const alert_key = d.deadline_type + '_' + d.due_date;\n  const state = $getWorkflowStaticData('global');\n  const last_alerted = state[alert_key] || '';\n  const today_str = today.toISOString().slice(0, 10);\n  if (!urgency || last_alerted === today_str) return null;\n  state[alert_key] = today_str;\n  return {json: {...d, urgency, days_remaining: days}};\n}).filter(Boolean);\n"
      },
      "position": [
        500,
        300
      ]
    },
    {
      "id": "4",
      "name": "Route by Urgency",
      "type": "n8n-nodes-base.switch",
      "parameters": {
        "dataType": "string",
        "value1": "={{ $json.urgency }}",
        "rules": {
          "rules": [
            {
              "value2": "OVERDUE"
            },
            {
              "value2": "CRITICAL"
            },
            {
              "value2": "URGENT"
            },
            {
              "value2": "WARNING"
            }
          ]
        }
      },
      "position": [
        700,
        300
      ]
    },
    {
      "id": "5",
      "name": "Slack @here Alert",
      "type": "n8n-nodes-base.slack",
      "parameters": {
        "channel": "#compliance-ops",
        "text": "={{ '<!here> *' + $json.urgency + '* \u2014 ' + $json.deadline_type + ' due ' + $json.due_date + ' (' + $json.days_remaining + 'd) | Owner: ' + $json.owner + ' | Reg: ' + $json.regulation }}"
      },
      "position": [
        900,
        200
      ]
    },
    {
      "id": "6",
      "name": "Email Owner",
      "type": "n8n-nodes-base.gmail",
      "parameters": {
        "operation": "send",
        "to": "={{ $json.owner_email }}",
        "subject": "={{ '[' + $json.urgency + '] ' + $json.deadline_type + ' due ' + $json.due_date }}",
        "message": "={{ $json.urgency + ': ' + $json.deadline_type + '\\nDue: ' + $json.due_date + ' (' + $json.days_remaining + ' days)\\nRegulation: ' + $json.regulation + '\\nPenalty: ' + $json.penalty_note + '\\nAction: ' + $json.action_required }}"
      },
      "position": [
        900,
        400
      ]
    }
  ],
  "connections": {
    "Weekdays at 8 AM": {
      "main": [
        [
          {
            "node": "Load Deadlines from Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Load Deadlines from Sheets": {
      "main": [
        [
          {
            "node": "Classify Urgency",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Classify Urgency": {
      "main": [
        [
          {
            "node": "Route by Urgency",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Route by Urgency": {
      "main": [
        [
          {
            "node": "Slack @here Alert",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Slack @here Alert",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Email Owner",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Email Owner",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Workflow 4 — Cybersecurity Incident & SEC Material Disclosure Pipeline

Trigger: POST webhook (/cyber-incident)

What it does: Classifies 8 incident types, each with SLA hours, regulatory citation, and escalation list. Uses $getWorkflowStaticData for 30-minute per-incident deduplication. Fires <!channel> Slack, appends to Postgres security_incidents with ON CONFLICT DO NOTHING. Returns ACK with incident_id, deadline, and regulation in the response body.

The SEC §229.106 4-business-day problem: The regulation requires disclosure within 4 business days of the company determining the incident is material — but the determination process itself can take hours or days. Every hour of that process that runs through Zapier is an hour logged in Zapier's 30-day task history, which may be gone before an SEC investigation subpoenas it. Running the determination workflow on self-hosted n8n means your Postgres append-only log is the audit trail — available to your GC and SEC examiners for as long as you retain it.

Incident Type SLA Regulation Fastest Clock
SEC_MATERIAL_CYBERSECURITY_INCIDENT 4 business days SEC 17 CFR §229.106(a) Item 1.05 Form 8-K ⚡ 96h
FTC_SECTION_5_COMPLAINT 10 business days FTC Act §5(a) unfair/deceptive security practices
CMMC_SECURITY_INCIDENT 72h DFARS 252.204-7012 — DC3 notification
SOC2_CONTROL_FAILURE 48h AICPA TSC CC7.4 — auditor + customer notification
ISO27001_MAJOR_NONCONFORMITY 72h ISO 27001:2022 §10.1 — treatment within cert cycle
RANSOMWARE_ATTACK 24h Multiple: SEC §229.106 materiality + CMMC + state breach
DATA_BREACH_CUSTOMER_PII 72h State breach notification (fastest 30 days) + GDPR Art.33
INSIDER_THREAT_CONFIRMED 24h SOC 2 CC6.8 + NIST CSF 2.0 RS.RP-1
{
  "name": "CyberSec SaaS \u2014 Incident & SEC Material Disclosure Pipeline",
  "nodes": [
    {
      "id": "1",
      "name": "Incident Webhook",
      "type": "n8n-nodes-base.webhook",
      "parameters": {
        "path": "cyber-incident",
        "responseMode": "responseNode"
      },
      "position": [
        100,
        300
      ]
    },
    {
      "id": "2",
      "name": "Classify Incident",
      "type": "n8n-nodes-base.code",
      "parameters": {
        "jsCode": "\nconst inc = $input.first().json;\nconst type = String(inc.incident_type || '').toUpperCase();\nconst INCIDENTS = {\n  'SEC_MATERIAL_CYBERSECURITY_INCIDENT': {severity:'CRITICAL', sla_hours:96, regulation:'SEC 17 CFR \u00a7229.106(a) \u2014 4 business days from materiality determination', escalate_to:'CISO + GC + CFO + Board Audit Committee'},\n  'FTC_SECTION_5_COMPLAINT': {severity:'HIGH', sla_hours:240, regulation:'FTC Act \u00a75(a) \u2014 unfair or deceptive security practices', escalate_to:'GC + CISO + PR'},\n  'CMMC_SECURITY_INCIDENT': {severity:'HIGH', sla_hours:72, regulation:'DFARS 252.204-7012 \u2014 72h DoD Cyber Crime Center (DC3) notification', escalate_to:'ISSO + CISO + Contracts'},\n  'SOC2_CONTROL_FAILURE': {severity:'HIGH', sla_hours:48, regulation:'AICPA TSC CC7.4 \u2014 incident response + auditor notification', escalate_to:'CISO + Auditor + Customer Success'},\n  'ISO27001_MAJOR_NONCONFORMITY': {severity:'HIGH', sla_hours:72, regulation:'ISO 27001:2022 \u00a710.1 \u2014 documented treatment within certification cycle', escalate_to:'ISMS Manager + CISO + Certification Body'},\n  'RANSOMWARE_ATTACK': {severity:'CRITICAL', sla_hours:24, regulation:'Multiple: SEC \u00a7229.106 materiality check + CMMC + state breach laws', escalate_to:'CISO + GC + CEO + Board (if material)'},\n  'DATA_BREACH_CUSTOMER_PII': {severity:'HIGH', sla_hours:72, regulation:'State breach notification (fastest: 30 days) + GDPR Art.33 72h supervisory authority', escalate_to:'CISO + GC + DPO + Customer Legal'},\n  'INSIDER_THREAT_CONFIRMED': {severity:'HIGH', sla_hours:24, regulation:'SOC 2 CC6.8 + NIST CSF 2.0 RS.RP-1 + employment law', escalate_to:'CISO + HR + GC + ISSO'}\n};\nconst meta = INCIDENTS[type] || {severity:'MEDIUM', sla_hours:168, regulation:'Internal policy', escalate_to:'CISO'};\nconst incident_id = inc.incident_id || type + '_' + Date.now();\nconst state = $getWorkflowStaticData('global');\nconst last = state['last_' + incident_id] || 0;\nconst now = Date.now();\nif (now - last < 1800000) { return [{json: {_skip: true, incident_id}}]; }\nstate['last_' + incident_id] = now;\nconst deadline = new Date(now + meta.sla_hours * 3600000).toISOString();\nreturn [{json: {...inc, ...meta, incident_id, deadline, detected_at: new Date().toISOString()}}];\n"
      },
      "position": [
        300,
        300
      ]
    },
    {
      "id": "3",
      "name": "Skip Duplicate?",
      "type": "n8n-nodes-base.if",
      "parameters": {
        "conditions": {
          "boolean": [
            {
              "value1": "={{ $json._skip }}",
              "value2": true
            }
          ]
        }
      },
      "position": [
        500,
        300
      ]
    },
    {
      "id": "4",
      "name": "Slack <!channel> Alert",
      "type": "n8n-nodes-base.slack",
      "parameters": {
        "channel": "#security-incidents",
        "text": "={{ '<!channel> *[' + $json.severity + '] ' + $json.incident_type + '*\\nDeadline: ' + $json.deadline + ' (' + $json.sla_hours + 'h SLA)\\nRegulation: ' + $json.regulation + '\\nEscalate to: ' + $json.escalate_to }}"
      },
      "position": [
        700,
        200
      ]
    },
    {
      "id": "5",
      "name": "Log Incident to Postgres",
      "type": "n8n-nodes-base.postgres",
      "parameters": {
        "operation": "executeQuery",
        "query": "INSERT INTO security_incidents (incident_id, incident_type, severity, sla_hours, regulation, escalate_to, deadline, detected_at) VALUES ('{{ $json.incident_id }}','{{ $json.incident_type }}','{{ $json.severity }}',{{ $json.sla_hours }},'{{ $json.regulation }}','{{ $json.escalate_to }}','{{ $json.deadline }}','{{ $json.detected_at }}') ON CONFLICT DO NOTHING"
      },
      "position": [
        700,
        400
      ]
    },
    {
      "id": "6",
      "name": "ACK 200",
      "type": "n8n-nodes-base.respondToWebhook",
      "parameters": {
        "respondWith": "json",
        "responseBody": "={{ JSON.stringify({status:'received', incident_id: $json.incident_id, deadline: $json.deadline, regulation: $json.regulation}) }}"
      },
      "position": [
        900,
        300
      ]
    }
  ],
  "connections": {
    "Incident Webhook": {
      "main": [
        [
          {
            "node": "Classify Incident",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Classify Incident": {
      "main": [
        [
          {
            "node": "Skip Duplicate?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Skip Duplicate?": {
      "main": [
        [],
        [
          {
            "node": "Slack <!channel> Alert",
            "type": "main",
            "index": 0
          },
          {
            "node": "Log Incident to Postgres",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Slack <!channel> Alert": {
      "main": [
        [
          {
            "node": "ACK 200",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Log Incident to Postgres": {
      "main": [
        [
          {
            "node": "ACK 200",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Workflow 5 — Weekly CyberSec Ops KPI Dashboard

Trigger: Monday 8 AM

What it does: Two parallel Postgres queries (platform metrics + compliance event counts), merges, computes ARR WoW% with $getWorkflowStaticData, builds color-coded HTML table (green/orange/red), emails CEO + CISO, BCC Board Audit Committee, posts to #exec-kpis Slack.

Why Board Audit Committee BCC: SEC 17 CFR §229.106(b)(1)(iii) requires disclosure of how the Board or board committee oversees cybersecurity risks. Having the Board Audit Committee on a weekly KPI that includes SEC_MATERIAL_INCIDENT (OPEN) count is documented Board oversight — directly responsive to the 10-K Item 1C governance disclosure requirement.

{
  "name": "CyberSec SaaS \u2014 Weekly Ops KPI Dashboard",
  "nodes": [
    {
      "id": "1",
      "name": "Monday 8 AM",
      "type": "n8n-nodes-base.scheduleTrigger",
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "cronExpression",
              "expression": "0 8 * * 1"
            }
          ]
        }
      },
      "position": [
        100,
        300
      ]
    },
    {
      "id": "2a",
      "name": "Fetch Platform Metrics",
      "type": "n8n-nodes-base.postgres",
      "parameters": {
        "operation": "executeQuery",
        "query": "SELECT COUNT(*) as total_customers, SUM(arr_usd) as total_arr, COUNT(*) FILTER (WHERE tier='ENTERPRISE_MSSP') as enterprise_count FROM customers"
      },
      "position": [
        300,
        200
      ]
    },
    {
      "id": "2b",
      "name": "Fetch Compliance Events",
      "type": "n8n-nodes-base.postgres",
      "parameters": {
        "operation": "executeQuery",
        "query": "SELECT COUNT(*) FILTER (WHERE incident_type='SEC_MATERIAL_CYBERSECURITY_INCIDENT' AND resolved_at IS NULL) as sec_open, COUNT(*) FILTER (WHERE incident_type='CMMC_SECURITY_INCIDENT' AND resolved_at IS NULL) as cmmc_open, COUNT(*) FILTER (WHERE severity='CRITICAL' AND resolved_at IS NULL) as critical_open, COUNT(*) FILTER (WHERE detected_at >= NOW() - INTERVAL '7 days') as incidents_this_week FROM security_incidents"
      },
      "position": [
        300,
        400
      ]
    },
    {
      "id": "3",
      "name": "Merge Metrics",
      "type": "n8n-nodes-base.merge",
      "parameters": {
        "mode": "combine",
        "combinationMode": "mergeByPosition"
      },
      "position": [
        500,
        300
      ]
    },
    {
      "id": "4",
      "name": "Build HTML Report",
      "type": "n8n-nodes-base.code",
      "parameters": {
        "jsCode": "\nconst d = $input.first().json;\nconst state = $getWorkflowStaticData('global');\nconst prevArr = state.prev_arr || d.total_arr;\nconst arrWoW = d.total_arr > 0 ? (((d.total_arr - prevArr) / prevArr) * 100).toFixed(1) : '0.0';\nstate.prev_arr = d.total_arr;\nconst secColor = d.sec_open > 0 ? 'red' : 'green';\nconst critColor = d.critical_open > 0 ? 'red' : 'green';\nconst arrColor = parseFloat(arrWoW) >= 2 ? 'green' : parseFloat(arrWoW) >= 0 ? 'orange' : 'red';\nconst html = '<h2>CyberSec SaaS \u2014 Weekly Ops KPI</h2>' +\n  '<p><b>ARR:</b> <span style=\"color:' + arrColor + '\">$' + Number(d.total_arr||0).toLocaleString() + ' (' + arrWoW + '% WoW)</span></p>' +\n  '<p><b>Customers:</b> ' + d.total_customers + ' (' + d.enterprise_count + ' Enterprise MSSP)</p>' +\n  '<p><b>Incidents This Week:</b> ' + d.incidents_this_week + '</p>' +\n  '<p><b>SEC Material Incident (Open):</b> <span style=\"color:' + secColor + '\">' + d.sec_open + '</span></p>' +\n  '<p><b>CMMC Incidents (Open):</b> ' + d.cmmc_open + '</p>' +\n  '<p><b>Critical Unresolved:</b> <span style=\"color:' + critColor + '\">' + d.critical_open + '</span></p>' +\n  '<hr/><p style=\"font-size:11px;color:#888\">SEC 17 CFR \u00a7229.106 Board governance: material incidents require Board Audit Committee notification before SEC Form 8-K filing. This dashboard closes that governance gap.</p>';\nreturn [{json: {...d, html, arrWoW}}];\n"
      },
      "position": [
        700,
        300
      ]
    },
    {
      "id": "5",
      "name": "Email CEO + CISO BCC Board",
      "type": "n8n-nodes-base.gmail",
      "parameters": {
        "operation": "send",
        "to": "[email protected]",
        "cc": "[email protected]",
        "bcc": "[email protected]",
        "subject": "Weekly CyberSec Ops KPI \u2014 {{ new Date().toISOString().slice(0,10) }}",
        "message": "={{ $json.html }}",
        "isHtml": true
      },
      "position": [
        900,
        200
      ]
    },
    {
      "id": "6",
      "name": "Post to Slack #exec-kpis",
      "type": "n8n-nodes-base.slack",
      "parameters": {
        "channel": "#exec-kpis",
        "text": "={{ '*Weekly CyberSec KPI* | ARR: $' + Number($json.total_arr||0).toLocaleString() + ' (' + $json.arrWoW + '% WoW) | SEC INCIDENT OPEN: ' + $json.sec_open + ' | CMMC OPEN: ' + $json.cmmc_open + ' | CRITICAL: ' + $json.critical_open }}"
      },
      "position": [
        900,
        400
      ]
    }
  ],
  "connections": {
    "Monday 8 AM": {
      "main": [
        [
          {
            "node": "Fetch Platform Metrics",
            "type": "main",
            "index": 0
          },
          {
            "node": "Fetch Compliance Events",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Platform Metrics": {
      "main": [
        [
          {
            "node": "Merge Metrics",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Compliance Events": {
      "main": [
        [
          {
            "node": "Merge Metrics",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Merge Metrics": {
      "main": [
        [
          {
            "node": "Build HTML Report",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Build HTML Report": {
      "main": [
        [
          {
            "node": "Email CEO + CISO BCC Board",
            "type": "main",
            "index": 0
          },
          {
            "node": "Post to Slack #exec-kpis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Self-Hosting: Why CyberSec Vendors Specifically Need On-Premise n8n

Argument Regulation Why It Applies to CyberSec SaaS
SEC §229.106 attestation chain 17 CFR §229.106 + Item 1.05 Form 8-K Materiality determination memo must cite timestamped evidence — Zapier 30-day log may not survive SEC investigation timeline
FTC §5 substantiation FTC Act §5(a) + LabMD precedent Security vendor's own operations are held to the same 'reasonable practices' standard they sell — shared iPaaS in your own IR pipeline is a §5(a) vulnerability
CMMC 2.0 enclave boundary 32 CFR Part 170 + DFARS 252.204-7012 CMMC Level 2 requires CUI stays within assessed boundary — adding Zapier to your compliance workflow expands the scope your C3PAO must assess
SOC 2 CC9.2 subprocessor scope AICPA TSC CC9.2 Zapier added to your compliance workflow appears in your SOC 2 subprocessor list — auditors will test its security; self-hosted n8n stays inside your boundary
ISO 27001 §6.1.2 risk treatment ISO/IEC 27001:2022 §6.1.2 n8n workflow JSON in Git = version-controlled risk treatment evidence auditors can inspect during surveillance audit

Buyer Q&A

Q: How do we determine SEC materiality and document the process in n8n?

A: Workflow 4 fires on incident detection and creates a Postgres record with detected_at timestamp. Your GC then runs a materiality determination checklist (a separate n8n workflow or manual process) and updates the record with material_determined_at. The delta between those timestamps is your documented determination timeline. The 4-business-day clock starts at material_determined_at, not detected_at.

Q: How do we handle the FTC §5 'reasonable practices' benchmark?

A: The FTC's §5 enforcement against cybersecurity vendors focuses on claims substantiation — can you prove you did what you said you did? n8n's Postgres append-only log is your proof. Every alert fired, every SLA met or missed, every escalation sent — all timestamped and immutable in your own database.

Q: When does CMMC Level 2 require a C3PAO vs. self-attestation?

A: CMMC Level 2 has two paths: self-attestation for lower-risk contracts, and C3PAO assessment for contracts handling sensitive CUI with higher criticality. The 32 CFR Part 170 §170.17 rule is: if the contract specifies Level 2 with assessment, you need a C3PAO. If it specifies Level 2 with self-attestation, annual SPRS affirmation suffices. Workflow 3 tracks both deadlines separately.

Q: Can we use n8n evidence in a SOC 2 Type II audit?

A: Yes. SOC 2 auditors accept Postgres query results and exported logs as control evidence. CC7.2 (monitoring) and CC4.1 (risk assessment) both benefit from showing the auditor a scheduled query against your security_incidents table proving continuous monitoring. Some auditors will ask to see the n8n workflow JSON as evidence of automated control design.

Q: How does NIST CSF 2.0 change the Govern function obligations?

A: NIST CSF 2.0 (February 2024) added a new Govern function (GV) that was not in version 1.1. GV.OC-01 requires organizational policies for cybersecurity be established and aligned to stakeholder expectations. For a cybersecurity SaaS vendor, this means your own n8n workflows should be documented in your ISMS and version-controlled in Git — that version history is your Govern function audit evidence.

Ready to deploy?

All five workflows are available individually or as a bundle at stripeai.gumroad.com — the CyberSecurity SaaS bundle includes pre-configured endpoint tables, Postgres schema, and Slack channel mapping guides.

Have a question about a specific compliance scenario? Drop it in the comments — I'll answer every one.

📰 Read the original article on Dev.to Security

Originally published by Dev.to Security. Aggregated on AIWithGhost for educational purposes — full credit and traffic to the original publisher.