From 361c596bf2d7f3b725d4ca3bd069dc683f3ac2c1 Mon Sep 17 00:00:00 2001 From: "Cimon Lucas (LCM)" Date: Wed, 21 Feb 2018 18:54:48 +0100 Subject: [PATCH] Adding support for ISSO_CORS_ORIGIN env variable to allow defining wildcard CORS origins --- isso/wsgi.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/isso/wsgi.py b/isso/wsgi.py index 1788d47..60c1a58 100644 --- a/isso/wsgi.py +++ b/isso/wsgi.py @@ -84,6 +84,8 @@ def origin(hosts): hosts = [urlsplit(h) for h in hosts] def func(environ): + if 'ISSO_CORS_ORIGIN' in environ: + return environ['ISSO_CORS_ORIGIN'] if not hosts: return "http://invalid.local"