summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorms <ms@taler.net>2022-02-03 21:52:26 +0100
committerms <ms@taler.net>2022-02-03 21:52:42 +0100
commite0f7388f319932e1334e21fdbdb82a8650edb38c (patch)
treef8c0e3d0e6a5bfc1fb02188d2d324b4f8344d37a
parentd87965f2b3166a5a627e0ac4daa9ea70c6cc5c1c (diff)
downloadlibeufin-e0f7388f319932e1334e21fdbdb82a8650edb38c.tar.gz
libeufin-e0f7388f319932e1334e21fdbdb82a8650edb38c.tar.bz2
libeufin-e0f7388f319932e1334e21fdbdb82a8650edb38c.zip
CORS
-rw-r--r--sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt7
1 files changed, 7 insertions, 0 deletions
diff --git a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
index d4f6eef5..bebddb4c 100644
--- a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
+++ b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
@@ -418,6 +418,13 @@ val sandboxApp: Application.() -> Unit = {
install(CallLogging) {
this.level = org.slf4j.event.Level.DEBUG
}
+ install(CORS) {
+ anyHost()
+ header(HttpHeaders.Authorization)
+ header(HttpHeaders.ContentType)
+ method(HttpMethod.Options)
+ allowCredentials = true
+ }
install(Authentication) {
// Web-based authentication for Bank customers.
form("auth-form") {