Published September 4, 2026 · Reviewed by the NextGen engineering team
Trust Services Criteria Mapped to Software Architecture
Audit firms do not inspect your code line by line to see if it is elegant. They audit your software architecture to verify that your system behaves predictably, rejects unauthorized access, and records every operational state change.
The American Institute of Certified Public Accountants (AICPA) defines SOC 2 around five Trust Services Criteria (TSC): Security, Availability, Confidentiality, Processing Integrity, and Privacy. Every B2B SaaS engineering team must satisfy the Security criteria (also known as the Common Criteria). The remaining four are optional, though Availability and Confidentiality are standard for enterprise software.
Translating abstract compliance criteria into actual infrastructure requires explicit architectural mapping:
- CC6.1 (Logical Access Controls) maps to SSO enforcement, multi-factor authentication (MFA), role-based access control (RBAC), and short-lived ephemeral production credentials.
- CC6.6 & CC6.7 (Boundary Protection & Transmission) maps to VPC isolation, Web Application Firewalls (WAF), mutual TLS (mTLS) between microservices, and TLS 1.3 for public endpoints.
- CC6.8 (Malware & Unauthorized Software Protection) maps to container image scanning, automated dependency auditing, and signed commits in your version control system.
- CC7.1 & CC7.2 (Vulnerability Management & Monitoring) maps to continuous static application security testing (SAST), centralized SIEM log ingestion, and automated alerting thresholds.
- CC8.1 (Change Management) maps to protected git branches, mandatory peer pull-request approvals, automated CI/CD security gates, and immutable deployment histories.
If your code runs in AWS, GCP, or Azure without codified boundaries, an auditor will fail your control evaluation. Compliance is an infrastructure design problem.
The Four Mandatory Software Controls for SOC 2
Building a compliant application requires implementing four specific engineering controls before you schedule an audit window.
## Example: Enforcing non-public, encrypted S3 buckets with logging in Terraform
resource "aws_s3_bucket" "audit_logs" {
bucket = "company-production-audit-logs"
}
resource "aws_s3_bucket_public_access_block" "audit_logs_private" {
bucket = aws_s3_bucket.audit_logs.id
block_public_acls = true
block_public_policy = true
ignore_public_acls = true
restrict_public_buckets = true
}
resource "aws_s3_bucket_server_side_encryption_configuration" "audit_logs_encryption" {
bucket = aws_s3_bucket.audit_logs.id
rule {
apply_server_side_encryption_by_default {
sse_algorithm = "aws:kms"
}
}
}
1. Ephemeral Production Access and Zero-Trust Identity
Persistent SSH keys, shared admin credentials, and static database passwords destroy audit readiness immediately. Your system architecture must enforce short-lived access.
Implement zero-trust access proxies like Teleport, AWS SSM Session Manager, or HashiCorp Boundary. Developers log into an identity provider (Okta, Entra ID, or Google Workspace) with MFA. The proxy issues short-lived x509 certificates or SSH keys that expire in hours.
Production database queries must be logged at the query statement level and tied back to an individual engineer's identity, not a shared admin connection pool user.
2. Data Encryption and Automated Key Rotation
All customer data must be encrypted at rest using AES-256 and in transit using TLS 1.3.
Do not store raw KMS keys or secret strings in application repositories, environment files, or unencrypted environment variables. Use secret managers (AWS Secrets Manager, HashiCorp Vault, or GCP Secret Manager) that support automatic rotation.
Your database infrastructure must take automated daily snapshots, store them in a separate geographic region or secondary cloud account, and enforce Object Lock to prevent accidental or malicious deletion.
3. CI/CD Pipeline Enforcement and Change Management
Your git workflow is your primary evidence generator for change management. To satisfy CC8.1:
- Block direct commits to main or production branches. Enforce this at the repository provider level (GitHub, GitLab, Bitbucket).
- Require minimum peer approvals. Every pull request must have at least one approved review from an engineer who is not the pull request author.
- Automate status checks. SAST scanners (Semgrep, Snyk) and dependency checkers (Dependabot, Socket) must pass successfully before a merge is permitted.
- Bind commits to deployments. Your CI/CD runner (GitHub Actions, CircleCI) should deploy code using scoped, least-privilege IAM roles, attaching the git commit hash and build logs to your deployment pipeline tracking.
4. Immutable Audit Logs and Centralized Aggregation
Applications must write structured JSON logs capturing security-relevant events: login attempts, password resets, privilege escalations, data exports, and permission changes.
Piping logs to a local disk or an unmonitored CloudWatch log group is insufficient. Application logs, CloudTrail streams, VPC Flow Logs, and system logs must stream to a centralized logging engine (Datadog, Sumo Logic, or Elastic) or an S3 log archive bucket with Object Lock enabled.
Log access must be strictly isolated. An engineer with write access to application code must not have delete access to audit log archives.
SOC 2 Engineering Costs, Tooling, and Labor Allocations
Achieving SOC 2 compliance requires capital for compliance automation tools, auditor fees, and senior engineering labor.
For a 20-to-100-person engineering organization, expect the total implementation budget to land between $120,000 and $320,000 in Year 1.
| Control Domain | Recommended Tech Stack | Internal Engineering Hours | Tooling & Auditor Cost Range |
|---|---|---|---|
| Compliance Automation Platform | Vanta, Drata, Secureframe | 40 - 80 hours | $15,000 - $35,000 / year |
| Identity & Ephemeral Access | Okta, Teleport, AWS SSM | 80 - 160 hours | $8,000 - $25,000 / year |
| CI/CD & Code Security | GitHub Enterprise, Semgrep, Snyk | 60 - 120 hours | $5,000 - $18,000 / year |
| Infrastructure Hardening & IaC | Terraform, AWS KMS, CloudTrail | 120 - 240 hours | Included in Cloud Spend |
| SIEM & Centralized Logging | Datadog Security, Sumo Logic | 40 - 80 hours | $12,000 - $40,000 / year |
| External Audit Firm (Type II) | A-LIGN, Schellman, Prescient Assurance | 30 - 60 hours | $25,000 - $60,000 / audit |
If your platform architecture contains severe technical debt—such as legacy monolithic code bases sharing hardcoded credentials, unsegregated staging/production data, or manual deployment processes—engineering remediation costs rise rapidly. Teams routinely bring in external /enterprise modernizers or dedicated /security engineers to execute IaC refactoring and pipeline isolation without stalling their product roadmap.
Automated Compliance Platforms vs. Real Engineering Work
Compliance platforms like Vanta, Drata, and Secureframe collect evidence effectively. They connect via API to AWS, GitHub, and Okta, continuously pulling configuration states and flagging unencrypted buckets or missing MFA.
However, compliance automation tools do not write code, refactor databases, or fix architectural defects.
A compliance tool will notify you that your production database is publicly accessible or that your developers lack scoped IAM roles. Resolving that issue requires senior engineering execution:
- Writing Terraform scripts to move the database into private subnets.
- Updating application code to use dynamic credentials or secret managers.
- Establishing network security groups and database proxies.
- Testing application failover to ensure zero downtime.
Buying a compliance platform without allocating engineering capacity creates an expensive dashboard filled with failing security tests.
A 12-Week SOC 2 Type II Technical Implementation Sequence
SOC 2 Type II audits evaluate the operational effectiveness of your controls over a minimum observation window (typically 3 to 6 months). Follow this 12-week sequence to build, test, and lock down your environment before your observation window opens.
- Weeks 1-2: Audit Scope Reduction & Environment Isolation. Separate production workloads into dedicated, clean cloud accounts (e.g., AWS Organizations). Move staging and dev workloads completely out of the production blast radius. Ensure no live customer PII exists in staging environments.
- Weeks 3-5: Identity Infrastructure & Access Lockdown. Enforce SSO and mandatory hardware/app MFA across all software vendors. Deploy access proxies (Teleport or SSM). Remove all static, long-lived AWS IAM keys and SSH keys from developer laptops.
- Weeks 6-8: Infrastructure as Code & Encryption Enforcement. Audit all databases, buckets, and persistent disks using automated policy-as-code tools (like Open Policy Agent or Checkov). Remediate unencrypted resources. Codify all infrastructure changes in Terraform or Pulumi.
- Weeks 9-10: Pipeline Controls & Vulnerability Scanners. Turn on branch protections on all core repositories. Integrate automated SAST, secret detection (TruffleHog), and container image scanning into your CI/CD pipelines. Configure pipelines to block non-compliant builds automatically.
- Weeks 11-12: Logging Consolidation & Dry Run. Route all CloudTrail, access, application, and system logs to a secure, immutable log archive. Conduct a full internal mock audit using your compliance platform to verify 100% test pass rates across all selected Trust Services Criteria.
Once Week 12 completes, enter your formal Type II observation period. From this day forward, every commit, access request, and deployment leaves a permanent evidence trail for your auditor.
Four Architectural Pitfalls That Cause Audit Findings
Audit failures rarely stem from missing policies. They happen when system reality diverges from what engineering leaders promised on paper.
- Production PII Copying to Staging: Engineers pull production database dumps down to local environments or staging instances to debug complex edge cases. Auditors run automated scans on staging databases; if unanonymized customer data turns up in unencrypted staging stores, you fail the control.
- Orphaned Infrastructure and Manual Tweaks: An engineer logs into the cloud console and manually modifies a Security Group during an outage, forgetting to update the underlying Terraform state. The automated scanner flags this manual drift as an unapproved change control violation.
- Unscoped CI/CD Service Accounts: The service account running your GitHub Actions runner has
AdministratorAccessin production. If an attacker compromises a third-party dependency inside your CI pipeline, they inherit full control of your infrastructure. Scrape CI/CD credentials down to narrow, specific IAM roles using OpenID Connect (OIDC). - Unverified Disaster Recovery Plans: Organizations state they run daily database backups. When auditors ask for proof of a successful data restoration test from the last six months, engineering teams discover nobody ever ran a restore drill. Write an automated script that spins up an isolated test instance from a snapshot, verifies database integrity, teardown the instance, and logs the successful output automatically every quarter.
What This Means for Your Team
SOC 2 compliance is not a paperwork exercise managed by legal or HR. It is a technical refactoring project that directly impacts your deployment pipelines, database architectures, and developer workflows.
Attempting to bolt security controls onto an uncodified, legacy system weeks before an audit forces engineering teams to stop feature development entirely. Treating security architecture as a first-class engineering priority ensures your platform scales smoothly through enterprise procurement security reviews without breaking velocity.
If you need senior engineers to implement zero-trust access, codify your cloud infrastructure in Terraform, or refactor legacy systems for enterprise compliance, reach out to our team at /contact.
Frequently asked
- What are the core technical requirements for SOC 2 software compliance?
- The primary technical requirements include zero-trust access controls (SSO, MFA, ephemeral credentials), end-to-end data encryption at rest and in transit, centralized immutable logging, and strict change management in CI/CD pipelines. Engineering teams must enforce these controls at the infrastructure level using Infrastructure-as-Code. Buying compliance software alone does not satisfy audit controls without underlying infrastructure refactoring.
- How much does it cost to implement SOC 2 software controls?
- For a mid-sized engineering team, initial SOC 2 implementation costs range between $120,000 and $320,000. This includes compliance automation platforms ($15,000–$35,000), external audit fees ($25,000–$60,000), security tooling, and engineering labor allocations. Technical debt and legacy system refactoring can increase these figures further.
- What is the difference between SOC 2 Type I and Type II for software?
- A SOC 2 Type I audit evaluates whether your security controls are designed properly at a single point in time. A SOC 2 Type II audit evaluates the operational effectiveness of those controls over an extended monitoring period, typically three to six months. Enterprise buyers almost universally require a SOC 2 Type II report before closing major SaaS contracts.
- Can automated compliance platforms like Vanta or Drata handle all SOC 2 requirements?
- No, compliance automation platforms only continuously collect evidence and flag non-compliant resource states via API. They cannot write software code, move databases into private subnets, configure zero-trust access proxies, or enforce branch protections in CI/CD pipelines. Senior engineers must execute the underlying infrastructure and code changes.
- How does change management work under SOC 2 for engineering teams?
- SOC 2 change management requires blocking direct commits to production branches and mandating peer pull-request approvals. CI/CD pipelines must enforce automated security checks (SAST and dependency scanning) before merges are allowed. Every production deployment must be traceable to specific git commit hashes and peer approvals.
More answers in Insights or see AI development services.

