{"id":15589516,"url":"https://github.com/sokil/corsbundle","last_synced_at":"2025-03-29T09:42:13.882Z","repository":{"id":57055116,"uuid":"95854147","full_name":"sokil/CorsBundle","owner":"sokil","description":"Handling CORS Requests","archived":false,"fork":false,"pushed_at":"2017-08-04T09:15:19.000Z","size":12,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-04T00:42:55.807Z","etag":null,"topics":["cors","php","preflight"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sokil.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-06-30T05:59:57.000Z","updated_at":"2019-06-24T16:19:25.000Z","dependencies_parsed_at":"2022-08-24T14:00:29.756Z","dependency_job_id":null,"html_url":"https://github.com/sokil/CorsBundle","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sokil%2FCorsBundle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sokil%2FCorsBundle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sokil%2FCorsBundle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sokil%2FCorsBundle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sokil","download_url":"https://codeload.github.com/sokil/CorsBundle/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246168097,"owners_count":20734389,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cors","php","preflight"],"created_at":"2024-10-02T23:02:20.636Z","updated_at":"2025-03-29T09:42:13.862Z","avatar_url":"https://github.com/sokil.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CorsBundle\n\nHandling CORS Requests\n\n[![Total Downloads][badge-totalDownloads-img]][badge-totalDownloads-url]\n\n# Installation\n\nAdd composer dependency:\n```\ncomposer.phar require sokil/cors-bundle\n```\n\nRegister bundle in your AppKernel:\n\n```php\n\u003c?php\n\nclass AppKernel extends Kernel\n{\n    public function registerBundles()\n    {\n        $bundles = array(\n            new Sokil\\CorsBundle\\CorsBundle(),\n        );\n    }\n}\n```\n\n# Configuration\n\nConfigure bundle in your `/app/config/config.yml`:\n\n```yaml\ncors:\n  allowedOrigins: # list of hosts, allowed to do CORS requests to your app. \n    - https://fb.com\n    - https://google.com\n  withCredentials: true # allow send cookies to your hosts between requests\n  maxAge: 86400 # agte of prefligt request cache\n```\n\n# Useage\n\nListener `CorsRequestListener` is listened to kernel events of requests and add headers if this is CORS request and CORS allowed for that host.\n\n[badge-totalDownloads-img]: http://img.shields.io/packagist/dt/sokil/cors-bundle.svg?2\n[badge-totalDownloads-url]: https://packagist.org/packages/sokil/cors-bundle\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsokil%2Fcorsbundle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsokil%2Fcorsbundle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsokil%2Fcorsbundle/lists"}