draincloud-core/internal/storage/models/auth.go

26 lines
382 B
Go
Raw Permalink Normal View History

2024-09-27 22:37:58 +00:00
package models
2024-12-15 16:56:03 +00:00
import (
"time"
"github.com/google/uuid"
)
2024-09-27 22:37:58 +00:00
2024-10-19 23:17:27 +00:00
type Session struct {
2024-12-15 16:56:03 +00:00
ID uuid.UUID
2024-10-27 16:44:05 +00:00
SessionToken string
CsrfToken string
2024-12-15 16:56:03 +00:00
UserID uuid.UUID
2024-10-27 16:44:05 +00:00
CreatedAt time.Time
ExpiredAt time.Time
2024-10-19 23:17:27 +00:00
}
2024-09-27 22:37:58 +00:00
type User struct {
2024-12-15 16:56:03 +00:00
ID uuid.UUID
2024-09-27 22:37:58 +00:00
Username string
Login string
PasswordHash []byte
CreatedAt time.Time
UpdatedAt time.Time
}