Update Readme: Added HttpOnly, Secure flags for setting the cookie
This commit is contained in:
parent
667fe4e346
commit
f5b37263f0
1 changed files with 2 additions and 0 deletions
|
@ -45,6 +45,8 @@ func SetCookieHandler(w http.ResponseWriter, r *http.Request) {
|
|||
Name: "cookie-name",
|
||||
Value: encoded,
|
||||
Path: "/",
|
||||
Secure: true,
|
||||
HttpOnly: true,
|
||||
}
|
||||
http.SetCookie(w, cookie)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue