refreshtokenrepo

package
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 21, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CountRTOccurrences

func CountRTOccurrences(tx *sqlx.Tx, rtID uint64) (count int, err error)

CountRTOccurrences counts how many Mytokens use the passed refresh token

func DeleteRefreshToken

func DeleteRefreshToken(tx *sqlx.Tx, rtID uint64) error

DeleteRefreshToken deletes a refresh token

func GetRTID

func GetRTID(tx *sqlx.Tx, myID mtid.MTID) (rtID uint64, err error)

GetRTID returns the refresh token id for a mytoken

func GetRefreshToken

func GetRefreshToken(tx *sqlx.Tx, myid mtid.MTID, jwt string) (string, bool, error)

GetRefreshToken returns the refresh token for a mytoken id

func UpdateRefreshToken

func UpdateRefreshToken(tx *sqlx.Tx, tokenID mtid.MTID, newRT, jwt string) error

UpdateRefreshToken updates a refresh token in the database, all occurrences of the RT are updated.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL