DataSunrise Achieves AWS DevOps Competency Status in AWS DevSecOps and Monitoring, Logging, Performance

Data Audit for Aurora PostgreSQL

Introduction

Organizations face mounting pressure to protect their data assets and comply with regulatory requirements. Database administrators must implement robust monitoring processes, making data audit for Aurora PostgreSQL essential for modern security strategies.

While Amazon Aurora PostgreSQL provides native auditing tools, integrating advanced third-party solutions can enhance your auditing capabilities. Recent cybersecurity statistics highlight increasing insider threats, with 48% of organizations reporting more frequent attacks over the past year.

This article guides you through Aurora PostgreSQL's native auditing capabilities and explores how DataSunrise can enhance your compliance and security posture.

Data Audit for Aurora PostgreSQL with Native Capabilities

Amazon Aurora PostgreSQL includes two powerful built-in auditing mechanisms that allow administrators to monitor database activities: Database Activity Streams and the pgAudit extension. These tools provide different approaches to capturing, storing, and analyzing audit data.

Database Activity Streams

Architecture diagram showing database activity streams from an Aurora DB cluster consumed by Firehose

Database Activity Streams provides a near real-time stream of database activity that integrates with monitoring tools for security and compliance purposes.

Key Features:

  • Near real-time monitoring of database activity
  • Integration with AWS services like Amazon Kinesis, Lambda, and SNS
  • Separation of duties between DBAs and security personnel
  • Encrypted audit data using AWS KMS
  • Support for both synchronous and asynchronous modes

Enabling Database Activity Streams:

  1. Navigate to your Aurora cluster
  2. Under Actions menu, choose "Start database activity stream"
  3. Select "Apply immediately" and choose "Continue"

Reviewing Audit Data: Once enabled, Database Activity Streams delivers audit data to an Amazon Kinesis Data Stream, which can be consumed by various AWS services:

  • Store in Amazon S3 via Kinesis Data Firehose
  • Process with AWS Lambda for real-time alerting
  • Analyze with Amazon Athena for compliance reporting

Considerations:

  • Performance Impact: Synchronous mode prioritizes audit accuracy but may impact performance
  • Cost: While the feature itself is free, you pay for Kinesis Data Streams and storage
  • Coverage: Captures all database actions across the entire cluster

pgAudit Extension

The PostgreSQL Audit Extension (pgAudit) provides detailed session and object audit logging through PostgreSQL's standard logging facility. This extension focuses on what happened within the database while satisfying requests.

Key Features:

  • Granular control over audit logging (session vs. object level)
  • Detailed logging of SQL statements and operations
  • Configurable at instance, database, or user level
  • Integration with PostgreSQL's native logging system

Enabling pgAudit:

-- Install the pgAudit extension
CREATE EXTENSION pgaudit;

-- Configure via parameter groups
-- shared_preload_libraries = 'pgaudit'
-- pgaudit.log = 'ddl,role,read,write'

-- Set audit logging for specific database
ALTER DATABASE yourdb SET pgaudit.log = 'ALL';

-- Set audit logging for specific user
ALTER ROLE username SET pgaudit.log = 'ROLE,WRITE,DDL,FUNCTION';

Available Audit Classes:

  • READ – SELECT and COPY operations
  • WRITE – INSERT, UPDATE, DELETE, TRUNCATE operations
  • FUNCTION – Function calls and DO blocks
  • ROLE – Role and privilege management
  • DDL – Data definition language commands
  • MISC – Other commands like DISCARD, FETCH, VACUUM
  • ALL – Include all audit classes

For details on implementing pgAudit with Aurora PostgreSQL, refer to AWS's comprehensive guide

Data Audit for Aurora PostgreSQL with DataSunrise

Amazon Aurora

Although Aurora PostgreSQL's native auditing tools provide essential capabilities, they may not meet the demands of complex environments requiring robust compliance and security.

DataSunrise enhances Aurora PostgreSQL with a comprehensive suite of features designed to meet stringent regulatory requirements.

Advantages of Data Audit for Aurora PostgreSQL with DataSunrise:

Implementing a Complete Audit Solution: AWS and DataSunrise

For organizations seeking a comprehensive audit solution, combining AWS native tools with DataSunrise provides the most robust approach:

  1. Use Database Activity Streams for foundational auditing and integration with AWS services
  2. Implement pgAudit for detailed SQL-level auditing of specific databases or users
  3. Deploy DataSunrise for enhanced security, centralized management, and advanced compliance features

This layered approach ensures complete visibility while providing the flexibility to address specific compliance requirements.

For details, see our setup guide for Aurora PostgreSQL auditing.

Conclusion

As cloud databases like Aurora PostgreSQL continue to manage sensitive business data, robust audit capabilities are essential for ensuring security and compliance. While Aurora offers strong native auditing features through Database Activity Streams and pgAudit, it is often crucial to supplement these with additional solutions to meet evolving compliance standards.

DataSunrise provides a comprehensive data auditing solution for Aurora PostgreSQL, addressing the compliance and security challenges businesses face. Through real-time monitoring, intelligent analytics, and broad platform compatibility, DataSunrise delivers the robust audit infrastructure needed to maintain security and meet regulatory requirements.

Want to enhance your data audit and security capabilities for Aurora PostgreSQL? Schedule a demo to see DataSunrise in action.

Next

What is CockroachDB Audit Trail

Learn More

Need Our Support Team Help?

Our experts will be glad to answer your questions.

General information:
[email protected]
Customer Service and Technical Support:
support.datasunrise.com
Partnership and Alliance Inquiries:
[email protected]