diff --git a/opium/src/cookie.ml b/opium/src/cookie.ml index f17aef4..bc8dde0 100644 --- a/opium/src/cookie.ml +++ b/opium/src/cookie.ml @@ -395,6 +395,12 @@ let to_set_cookie_header t = | None -> v | Some domain -> Printf.sprintf "%s; Domain=%s" v domain in + let v = + match t.same_site with + | `None -> Printf.sprintf "%s; SameSite=None" v + | `Strict -> Printf.sprintf "%s; SameSite=Strict" v + | `Lax -> Printf.sprintf "%s; SameSite=Lax" v + in let v = match t.expires with | `Date ptime ->