Skip to content

Add CORS middleware plugin #24

Description

@0xReLogic

Description

Add a CORS (Cross-Origin Resource Sharing) middleware plugin to handle cross-origin requests.

Requirements

  • Implement CORS plugin in internal/plugins/cors/
  • Support configurable allowed origins, methods, and headers
  • Handle preflight OPTIONS requests
  • Add to plugin chain configuration

Configuration Example

plugins:
  enabled: true
  chain:
    - name: cors
      config:
        allowed_origins: ["*"]
        allowed_methods: ["GET", "POST", "PUT", "DELETE"]
        allowed_headers: ["Content-Type", "Authorization"]
        max_age: 3600

Acceptance Criteria

  • CORS plugin implementation with config support
  • Unit tests for CORS functionality
  • Documentation in README
  • Example configuration in helios.yaml

References

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions