Add password validation

This commit is contained in:
2024-04-25 22:51:37 +07:00
commit 2e2fbdf800
51 changed files with 3526 additions and 0 deletions

46
types/types.go Normal file
View File

@ -0,0 +1,46 @@
package types
import (
"github.com/google/uuid"
"time"
)
type Message struct {
Code int
Message string
}
type User struct {
UserID uuid.UUID
Email string
Username string
Authenticated bool
}
type UserWithExpired struct {
UserID uuid.UUID
Username string
Email string
Password string
AccessAt time.Time
}
type FileInfo struct {
Name string `json:"name"`
Size int `json:"size"`
Chunk int `json:"chunk"`
}
type FileInfoUploaded struct {
Name string `json:"name"`
Size int `json:"size"`
Chunk int `json:"chunk"`
UploadedChunk int `json:"uploaded_chunk"`
}
type FileData struct {
ID string
Name string
Size string
Downloaded int
}