Audit Logging

VivaEdu maintains comprehensive audit logs for security, compliance, and accountability. This page explains what is logged, why it is logged, and how audit data supports regulatory compliance.

Summary

  • All sensitive actions are recorded in an audit log
  • Logs support GDPR Article 30 (records of processing activities)
  • Default retention is 365 days (configurable 30 to 3,650 days)
  • Audit log access is restricted to administrators
  • Viewing and exporting audit logs is itself logged

What Gets Logged

VivaEdu logs actions that affect personal data, security, or compliance. The following tables summarise the key action categories.

Data Operations

ActionWhen TriggeredDescription
EXPORT_CSVCSV exportUser exports data as CSV file
EXPORT_ZIPZIP exportUser exports data as ZIP archive
DELETERecord deletionManual deletion of records

GDPR and Privacy Operations

ActionWhen TriggeredDescription
STUDENT_RECORDING_CONSENT_GIVENConsent grantedStudent grants recording consent
GDPR_DATA_EXPORT_REQUESTEDData export requestStudent requests their data export
GDPR_ACCOUNT_DELETION_REQUESTEDDeletion requestStudent requests account deletion

Administrative Operations

ActionWhen TriggeredDescription
ADMIN_AUDIT_LOG_QUERYViewing logsAdmin views audit logs
ADMIN_AUDIT_LOG_EXPORT_CSVExporting logsAdmin exports audit logs to CSV
ADMIN_OPS_RETENTION_QUERYViewing retentionAdmin views retention policy
ADMIN_OPS_RETENTION_UPDATEUpdating retentionAdmin updates retention policy

Automated Operations

ActionWhen TriggeredDescription
RETENTION_DELETE_AUDIOAudio deletionAutomated media file deletion
RETENTION_PURGE_ASSIGNMENTAssignment purgeAutomated full assignment deletion
RETENTION_PURGE_CLASSClass purgeAutomated class data deletion
RETENTION_AUDIT_LOGS_CLEANUPLog cleanupAutomated audit log pruning

Log Entry Structure

Each audit log entry captures the action, the actor, and contextual information to enable traceability.

FieldDescriptionExample
idUnique identifier550e8400-e29b-41d4-a716-446655440000
createdAtTimestamp (UTC)2026-01-15T10:30:00.000Z
actorUserIdUser who performed the actionUUID or "system"
actorRoleRole of actorSTUDENT, TEACHER, TA, ADMIN
actionAction identifierEXPORT_CSV
entityTypeType of affected entityassignment, user, class
entityIdID of affected entityUUID
metadataAdditional contextJSON object
ipIP address (best-effort)192.168.1.100
userAgentBrowser user agentMozilla/5.0...

Metadata Examples

The metadata field captures action-specific context. Examples for key actions:

CSV Export

{
  "filters": { "from": "2026-01-01", "to": "2026-01-31" },
  "rowCount": 150
}

Recording Consent Given

{
  "consentVersion": "2025-12-25-v1",
  "consentTextHash": "<sha256>",
  "source": "student_preferences_put"
}

Retention Cleanup

{
  "retentionDays": 365,
  "cutoff": "2025-01-15T00:00:00.000Z",
  "deletedCount": 42,
  "job": "retention-sweeper"
}

Access Control

Who Can View Audit Logs

  • ADMIN role only: Audit log access is restricted to administrators
  • Meta-logging: Viewing logs is itself logged (ADMIN_AUDIT_LOG_QUERY)
  • Export logging: Exporting logs is logged (ADMIN_AUDIT_LOG_EXPORT_CSV)

Demo Tenant Isolation

  • Demo administrators only see logs from their demo tenant
  • Production logs are isolated from demo logs
  • Cross-tenant log access is not possible

Retention

Default Period365 days
Configurable Range30 to 3,650 days (10 years)
Cleanup ScheduleDaily at 03:00 UTC
Cleanup LoggingCleanup action itself is logged

Compliance Note: Your institution's Data Processing Agreement may commit to longer retention (for example, 7 years). Administrators should configure the retention period to meet institutional and regulatory requirements.

Export Capabilities

Export Format

Audit logs can be exported as CSV with BOM (Excel-compatible). The export includes the following columns:

  1. Created At (ISO timestamp)
  2. Action
  3. Actor User ID
  4. Actor Role
  5. Actor Name
  6. Actor Email
  7. Entity Type
  8. Entity ID
  9. IP Address
  10. User Agent
  11. Metadata (JSON)
  12. Audit Log ID

Export Limits and Filtering

  • Maximum rows: 50,000 rows per export
  • Date range: Filter by from/to dates
  • Action type: Filter by specific actions
  • Entity: Filter by entity type or ID
  • Actor: Filter by user ID
  • Search: Free-text search across all fields

Compliance Standards

VivaEdu's audit logging supports compliance with the following standards:

StandardRequirement
GDPR Article 30Records of processing activities
ISO 27001Information security event logging
SOC 2Audit trail requirements

System Actor

Some actions are performed automatically by background workers rather than human users. These are logged with a special system actor:

  • Actor ID: system
  • Actor Role: Null (system, not a user role)
  • Common system actions: Retention cleanup, automated media deletion, audit log pruning

A dedicated system user record is auto-created to maintain referential integrity in the audit log.

IP Address Capture

IP addresses are captured on a best-effort basis:

  • Primary source: x-forwarded-for header (first IP in chain)
  • Fallback: x-real-ip header
  • Limitation: May show proxy IP if infrastructure is not properly configured

Note: IP address logging is intended for security investigation and compliance purposes. The accuracy depends on proper proxy and load balancer configuration.

For Compliance Officers

Audit Evidence for Compliance Reviews

  • GDPR compliance: Audit logs provide evidence of consent collection, data export requests, and deletion requests
  • Traceability: All data access and exports are traceable to specific users and timestamps
  • Deletion documentation: Automated and manual deletion operations are documented with counts and cutoff dates
  • Access control evidence: Meta-logging demonstrates that audit access is controlled and monitored

Contact jex@vivaedu.co.uk for audit log access, compliance documentation, or Data Processing Agreement discussions.

Related Topics

Questions

For questions about audit logging or to discuss compliance requirements, contact jex@vivaedu.co.uk.

Comments

Leave a comment, question, or feedback. Comments are public — please don’t include personal data.

Loading comments…