Skip to content

Security: alexpota/jobguard

.github/SECURITY.md

Security Policy

Reporting Vulnerabilities

πŸ”’ Please do NOT open public issues for security vulnerabilities.

If you discover a security issue, please Create a private security advisory

We will respond within 48 hours and work with you to address the issue.

Supported Versions

Version Supported
0.1.x βœ…

Security Best Practices

When using JobGuard in production:

PostgreSQL Security

  • βœ… Use SSL/TLS for PostgreSQL connections (ssl: true)
  • βœ… Store connection strings in environment variables, not code
  • βœ… Use least-privilege database user with only required permissions:
    GRANT SELECT, INSERT, UPDATE, DELETE ON jobguard_jobs TO jobguard_user;
  • βœ… Rotate database credentials regularly
  • βœ… Set appropriate max_connections for your PostgreSQL instance
  • βœ… Enable PostgreSQL audit logging for compliance requirements

Application Security

  • βœ… Keep dependencies up to date (npm audit and npm update)
  • βœ… Validate job data in your application before enqueueing
  • βœ… Implement idempotent job handlers to prevent duplicate processing issues
  • βœ… Monitor logs for suspicious activity (unusual error patterns, connection failures)

What JobGuard Does

  • βœ… Sanitizes error messages to remove credentials and sensitive data
  • βœ… Uses parameterized SQL queries to prevent SQL injection
  • βœ… Validates job data size and format
  • βœ… Implements circuit breaker pattern for fault tolerance

What JobGuard Does NOT Do

  • ❌ JobGuard does not encrypt job data at rest (use PostgreSQL encryption if needed)
  • ❌ JobGuard does not implement authentication (secure your PostgreSQL instance)
  • ❌ JobGuard does not sanitize job data payloads (validate in your application)

Known Security Considerations

Race Conditions

See Known Limitations in the README for details on edge-case race conditions inherent to distributed systems.

Multi-Instance Reconciliation

Only enable reconciliation on one JobGuard instance per queue to prevent duplicate re-enqueue attempts. See Configuration for details.

Security Update Policy

  • Critical vulnerabilities: Patch released within 48 hours
  • High severity: Patch released within 7 days
  • Medium/Low severity: Patch released in next minor version

Acknowledgments

We appreciate responsible disclosure of security issues. Contributors who report valid security issues will be acknowledged in the CHANGELOG (unless they prefer to remain anonymous).

There aren’t any published security advisories