]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
CORS repare for api
authorRurik19 <rurik19@yandex.ru>
Wed, 4 Oct 2017 09:19:09 +0000 (12:19 +0300)
committerJeremy Benoist <jeremy.benoist@gmail.com>
Mon, 11 Feb 2019 10:57:52 +0000 (11:57 +0100)
app/config/config.yml

index 0c2b6a1daf02dbc8f54129d87bc806c632089bd3..8bef8312d366d0fd903e8a86fc81f7937f48ee05 100644 (file)
@@ -147,18 +147,18 @@ nelmio_cors:
     paths:
         '^/api/':
             allow_origin: ['*']
-            allow_headers: ['X-Custom-Auth']
+            allow_headers: ['Authorization','content-type']
             allow_methods: ['POST', 'PUT', 'PATCH','GET', 'DELETE']
             max_age: 3600
         '^/oauth/':
             allow_origin: ['*']
-            allow_headers: ['X-Custom-Auth']
+            allow_headers: ['Authorization','content-type']
             allow_methods: ['POST', 'PUT', 'GET', 'DELETE']
             max_age: 3600
         '^/':
             #origin_regex: true
-            allow_origin: ['^http://localhost:[0-9]+']
-            allow_headers: ['X-Custom-Auth']
+            allow_origin: ['*']
+            allow_headers: ['Authorization','content-type']
             allow_methods: ['POST', 'PUT', 'GET', 'DELETE']
             max_age: 3600
             hosts: ['^api\.']