Skip to main content

HIPAA Compliance Controls

HIPAA Compliance Controls

Status: Controls and operational practices intended to support HIPAA alignment.

Note: This document describes technical and administrative controls implemented in Bounded Health. It does not constitute a certification or attestation of HIPAA compliance. Organizations deploying this system must conduct their own compliance assessment and implement additional controls as required by their specific use case.

Overview

Bounded Health implements controls and operational practices designed to align with HIPAA (Health Insurance Portability and Accountability Act) requirements for handling Protected Health Information (PHI).

Technical Safeguards

Access Control (§164.312(a)(1))

User Authentication:

  • Multi-factor authentication (MFA) support available
  • Session management with automatic timeout
  • Password complexity requirements enforced by Clerk

Role-Based Access Control (RBAC):

  • Authorization enforcement: authorizePatientAccess(), authorizeEmployerAccess() functions
  • Principle of least privilege applied across API routes

Unique User Identification:

  • Clerk User ID as primary identifier
  • Database User ID as internal identifier
  • Audit logs track all user actions with user ID

Audit Controls (§164.312(b))

Audit Logging:

  • Logged events include:
    • PHI access (read operations)
    • PHI modifications (create, update, delete)
    • Authentication events
    • Authorization failures
    • Administrative actions

Audit Log Contents:

  • Actor user ID and role
  • Patient ID (for patient-related actions)
  • Action type
  • Timestamp (automatic via Prisma)
  • IP address and user agent (where available)
  • Metadata (specific to action type)

Audit Log Protection:

  • Append-only architecture (no update/delete operations)
  • Database-level constraints prevent modification
  • Access restricted to ADMIN role only

Integrity Controls (§164.312(c)(1))

Data Integrity:

  • Database constraints enforce referential integrity
  • Transaction management via Prisma
  • Input validation on all API endpoints

PHI Transmission Integrity:

  • Content-Security-Policy headers prevent tampering
  • File upload checksums (via Google Cloud Storage)

Transmission Security (§164.312(e)(1))

Encryption in Transit:

  • HTTPS/TLS 1.2+ required for all connections
  • HSTS header enforces HTTPS (Strict-Transport-Security: max-age=31536000)

Encryption at Rest:

  • Database: PostgreSQL with encryption at rest (deployment-specific)
  • File storage: Google Cloud Storage with default encryption
  • Credentials: Environment variables, never committed to source control

Administrative Safeguards

Security Management Process (§164.308(a)(1))

Risk Analysis:

  • Security audit performed (see docs/audits/)

Security Incident Response:

  • See: docs/compliance/BREACH_NOTIFICATION.md
  • Error monitoring via Sentry
  • Audit logs enable incident investigation

Workforce Security (§164.308(a)(3))

Authorization and Supervision:

  • Role-based access control limits PHI access by role
  • ADMIN role required for sensitive operations
  • Employer access limited to their organization's patients only

Workforce Clearance:

  • Access provisioning process (organizational responsibility)
  • Access termination via Clerk user deactivation
  • Audit logs track all access for review

Information Access Management (§164.308(a)(4))

Access Authorization:

  • authorizePatientAccess() enforces access rules
  • Patients can only access their own data
  • Employers can only access referred patients within their organization
  • ADMINs have full access with audit trail

Access Establishment and Modification:

  • Role assignment via database User model
  • Changes logged in audit trail
  • API enforcement in all routes

Physical Safeguards

Note: Physical safeguards are deployment-specific and responsibility of the hosting organization.

Recommendations:

  • Use SOC 2 Type II certified cloud providers
  • Enable physical access controls at data center level
  • Implement workstation security policies
  • Ensure device and media controls per organizational policy

PHI Inventory

The following models contain Protected Health Information:

  • Demographics: date of birth
  • Health data: height, weight, medications, conditions
  • Contact: email, phone (via User relation)
  1. MealLog

    • Photos of food (indirect health indicator)
    • Glucose predictions
    • Timestamps and patterns
  2. TaperingLog

    • Medication dosage history
    • Side effects and symptoms
  3. LabReport

    • Laboratory test results
    • Clinical findings
  4. MedicalImage

    • Medical imaging files (X-ray, MRI, CT, etc.)
    • DICOM metadata
  5. AuditLog

    • Contains patient IDs and action metadata
    • Protected at same level as PHI

Organizational Responsibilities

Organizations deploying Bounded Health must:

  1. Designate Privacy and Security Officials

    • HIPAA Privacy Officer
    • HIPAA Security Officer
  2. Implement Business Associate Agreements (BAA)

    • Execute BAAs with all vendors processing PHI
    • Template: docs/compliance/BAA_TEMPLATE.md
  3. Provide Workforce Training

    • HIPAA awareness training
    • System-specific access control training
  4. Establish Policies and Procedures

    • Data retention policy (see docs/compliance/DATA_RETENTION_POLICY.md)
    • Breach notification procedure (see docs/compliance/BREACH_NOTIFICATION.md)
    • PHI handling policy (see docs/compliance/PHI_HANDLING_POLICY.md)
  5. Conduct Regular Risk Assessments

    • Annual security risk analysis
    • Penetration testing
    • Vulnerability assessments

Compliance Gaps and Limitations

This implementation provides technical controls but does not include:

  • Business Associate Agreements (organizational responsibility)
  • Workforce training programs (organizational responsibility)
  • Physical safeguard implementation (hosting provider responsibility)
  • Disaster recovery and business continuity plans (organizational responsibility)
  • Full encryption at rest verification (deployment-specific)

References

  • HIPAA Security Rule: 45 CFR Part 164, Subpart C
  • HIPAA Privacy Rule: 45 CFR Part 164, Subpart E
  • HHS HIPAA Resources: https://www.hhs.gov/hipaa/