Documentation ¶
Index ¶
- func CheckActiveSession(r *http.Request) ([]util.UserData, bool)
- func CreateSession(w http.ResponseWriter, username string) util.UserData
- func DestroySession(w http.ResponseWriter, user []util.UserData)
- func GetActiveSession(username string) util.UserData
- func SessionHandlerNew(w http.ResponseWriter, r *http.Request, username string, decider string)
- type Email
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckActiveSession ¶
CheckActiveSession queries the DB for the current users data, checks the cookie for corresponding data and returns true if the data is as expected, else returns false.
func CreateSession ¶
func CreateSession(w http.ResponseWriter, username string) util.UserData
func DestroySession ¶
func DestroySession(w http.ResponseWriter, user []util.UserData)
DestroySession destroys an existing session before logging the user out
func GetActiveSession ¶
Returns the active session after CheckActiveSession confirms that the data existing in the DB is consistent user data.
func SessionHandlerNew ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.