ligo/vendors/ocplib-resto/lib_resto-cohttp/cors.mli
Vincent Bernardoff 76bf25646c Resto: fix CORS
CORS also requires to send the "Access-Control-Allow-Origin" header on
direct requests or requests following preflight requests.
2018-05-12 23:58:20 +02:00

23 lines
874 B
OCaml

(**************************************************************************)
(* *)
(* Copyright (c) 2014 - 2018. *)
(* Dynamic Ledger Solutions, Inc. <contact@tezos.com> *)
(* *)
(* All rights reserved. No warranty, explicit or implicit, provided. *)
(* *)
(**************************************************************************)
type t = {
allowed_headers : string list ;
allowed_origins : string list ;
}
val default: t
val add_allow_origin:
Cohttp.Header.t -> t -> string option -> Cohttp.Header.t
val add_headers:
Cohttp.Header.t -> t -> string option -> Cohttp.Header.t