modulepackage
0.3.3
Repository: https://github.com/aaronland/go-http-cookie.git
Documentation: pkg.go.dev
# README
go-http-cookie
Go package for working with HTTP cookies.
Example
Error handling omitted for the sake of brevity.
package main
import (
"fmt"
"github.com/aaronland/go-http-cookie"
)
func main() {
name := "c"
secret := "s33kret"
salt := "s4lty"
cookie_uri := fmt.Sprintf("encrypted://?name=%s&secret=%s&salt=%s", name, secret, salt)
ck, _ := cookie.NewCookie(ctx, cookie_uri)
}
Interfaces
type Cookie interface { Get(*http.Request) (*memguard.LockedBuffer, error) GetString(*http.Request) (string, error) Set(http.ResponseWriter, *memguard.LockedBuffer) error SetString(http.ResponseWriter, string) error SetWithCookie(http.ResponseWriter, *memguard.LockedBuffer, *http.Cookie) error SetStringWithCookie(http.ResponseWriter, string, *http.Cookie) error Delete(http.ResponseWriter) error }
See also
# Packages
No description provided by the author
# Functions
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Structs
No description provided by the author
# Interfaces
No description provided by the author
# Type aliases
No description provided by the author