Documentation
¶
Index ¶
- Constants
- Variables
- func GetSession(ctx *echo.Context) (domain.SessionExtended, error)
- func GetSessionCookie(ctx *echo.Context) (string, error)
- func NewID() string
- func ParseScoreURL(scoreURL string) (int, error)
- func ReadAuthStateCookie(ctx *echo.Context) (string, error)
- func SetAuthStateCookie(ctx *echo.Context, domain, value string)
- func SetSession(ctx *echo.Context, session domain.SessionExtended)
- func SetSessionCookie(ctx *echo.Context, domain, sessionId string)
- func UnsetAuthStateCookie(ctx *echo.Context, domain string)
- func UnsetSessionCookie(ctx *echo.Context, domain string)
- func ValidateTurnstile(token, secret string) error
- type Map
- type TurnstileError
- type TurnstileRequest
- type TurnstileResponse
Constants ¶
View Source
const (
AuthStateCookieName = "auth_state"
)
View Source
const (
SessionCookieName = "rank_guessr_session"
)
Variables ¶
Functions ¶
func GetSession ¶
func GetSession(ctx *echo.Context) (domain.SessionExtended, error)
func ParseScoreURL ¶
func SetAuthStateCookie ¶
func SetSession ¶
func SetSession(ctx *echo.Context, session domain.SessionExtended)
func SetSessionCookie ¶
func UnsetAuthStateCookie ¶
func UnsetSessionCookie ¶
func ValidateTurnstile ¶
Types ¶
type TurnstileError ¶
type TurnstileError struct {
Code string
}
func (*TurnstileError) Error ¶
func (e *TurnstileError) Error() string
type TurnstileRequest ¶
type TurnstileResponse ¶
Click to show internal directories.
Click to hide internal directories.