summaryrefslogtreecommitdiff
path: root/vendor/code.superseriousbusiness.org/oauth2/v4/model.go
diff options
context:
space:
mode:
authorLibravatar tobi <31960611+tsmethurst@users.noreply.github.com>2025-04-25 15:15:36 +0200
committerLibravatar GitHub <noreply@github.com>2025-04-25 15:15:36 +0200
commitffde1b150faca940bc6c172068aa068cf468aa39 (patch)
tree2b325bf50946b95502d948d5700c148d667346d8 /vendor/code.superseriousbusiness.org/oauth2/v4/model.go
parent[chore] Update `activity` to v1.14.0 (#4038) (diff)
downloadgotosocial-ffde1b150faca940bc6c172068aa068cf468aa39.tar.xz
[chore] Move deps to code.superseriousbusiness.org (#4054)
Diffstat (limited to 'vendor/code.superseriousbusiness.org/oauth2/v4/model.go')
-rw-r--r--vendor/code.superseriousbusiness.org/oauth2/v4/model.go59
1 files changed, 59 insertions, 0 deletions
diff --git a/vendor/code.superseriousbusiness.org/oauth2/v4/model.go b/vendor/code.superseriousbusiness.org/oauth2/v4/model.go
new file mode 100644
index 000000000..121a42d67
--- /dev/null
+++ b/vendor/code.superseriousbusiness.org/oauth2/v4/model.go
@@ -0,0 +1,59 @@
+package oauth2
+
+import (
+ "time"
+)
+
+type (
+ // ClientInfo the client information model interface
+ ClientInfo interface {
+ GetID() string
+ GetSecret() string
+ GetDomain() string
+ GetUserID() string
+ }
+
+ // ClientPasswordVerifier the password handler interface
+ ClientPasswordVerifier interface {
+ VerifyPassword(string) bool
+ }
+
+ // TokenInfo the token information model interface
+ TokenInfo interface {
+ New() TokenInfo
+
+ GetClientID() string
+ SetClientID(string)
+ GetUserID() string
+ SetUserID(string)
+ GetRedirectURI() string
+ SetRedirectURI(string)
+ GetScope() string
+ SetScope(string)
+
+ GetCode() string
+ SetCode(string)
+ GetCodeCreateAt() time.Time
+ SetCodeCreateAt(time.Time)
+ GetCodeExpiresIn() time.Duration
+ SetCodeExpiresIn(time.Duration)
+ GetCodeChallenge() string
+ SetCodeChallenge(string)
+ GetCodeChallengeMethod() CodeChallengeMethod
+ SetCodeChallengeMethod(CodeChallengeMethod)
+
+ GetAccess() string
+ SetAccess(string)
+ GetAccessCreateAt() time.Time
+ SetAccessCreateAt(time.Time)
+ GetAccessExpiresIn() time.Duration
+ SetAccessExpiresIn(time.Duration)
+
+ GetRefresh() string
+ SetRefresh(string)
+ GetRefreshCreateAt() time.Time
+ SetRefreshCreateAt(time.Time)
+ GetRefreshExpiresIn() time.Duration
+ SetRefreshExpiresIn(time.Duration)
+ }
+)