szuntis-backend/authentication/types.go
KoCoder 1e41dd833f
Some checks failed
build-docker-imge / Build the docker container (push) Failing after 2m24s
Experiment with Authentication and Websockets
2024-08-27 18:20:17 +02:00

60 lines
1005 B
Go

package authentication
import (
"time"
"gorm.io/gorm"
)
type UserAccount struct {
gorm.Model
Username string
FirstName string
LastName string
}
type HashingAlgorithm struct {
gorm.Model
AlgoritmName string
}
type EmailValidationStatus struct {
gorm.Model
StatusDescription string
}
type UserLoginData struct {
gorm.Model
LoginName string
PasswordHash []byte
PassswordSalt []byte
EmailAddress string
ConfirmationToken string
TokenGenerationTime time.Time
PasswordRecoveryToken string
RecoveryTokenTime time.Time
EmailValidationStatusId int
EmailValidationStatus EmailValidationStatus
UserAccountID int
UserAccount UserAccount
HashingAlgorithmID int
HashingAlgorithm HashingAlgorithm
}
type UserLoginDataExternal struct {
gorm.Model
ExternalProviderToken string
ExternalProviderID int
ExternalProvider ExternalProvider
}
type ExternalProvider struct {
gorm.Model
ProviderName string
WSEndPoint string
}