Commit Graph

9 Commits

Author SHA1 Message Date
62917633c4 feat(auth): add logout functionality
- Implement LogoutHandler to handle user logout requests
- Add DeleteTokenInfo and GetUserIDFromToken functions to auth module
- Update README.md with logout endpoint documentation
2026-03-03 23:06:36 +08:00
461f2fc775 temp 2026-02-28 23:00:57 +08:00
686c3dcd4e refactor: consolidate debug flag and update gitignore
- Rename debugMode to isDebug for consistency across codebase
- Move debug flag check in ValidateTimeStamp to match other validations
- Add database.db to gitignore and remove unused config file
- Update README.md to clarify user registration rules
2026-02-28 15:48:01 +08:00
b661118180 refactor(auth): move authentication params to headers and simplify validation
- Move token and timestamp validation to HTTP headers
- Simplify ValidateTimeStamp to return boolean
- Update AddUser to use default "visitor" type
- Remove redundant timestamp and token fields from request structs
- Update API documentation to reflect header-based authentication
2026-02-28 15:32:32 +08:00
aa70e7c0f0 refactor(api): simplify instance management endpoints
- Change delete endpoint to use request body instead of path parameter
- Modify endpoint now takes field as path parameter and instance name in body
- Update README to reflect API changes
- Remove unused description field from software info
- Fix error message in auth token lookup
2026-02-28 11:55:52 +08:00
e3b3a3aa98 feat(logging): add detailed logging throughout application components
- Implement logging in router setup, auth handlers, and frpc operations
- Add SoftwareInfo struct for version tracking and logging
- Enhance error messages with more context and logging
- Replace direct error returns with formatted error logging
- Add debug logs for token operations and request validations
2026-02-27 23:44:41 +08:00
af5af2a04f fix(auth): skip timestamp validation in debug mode
Modify ValidateTimeStamp to bypass validation when in debug mode. Also update request validation to make timestamp optional in debug mode while maintaining security checks in production.
2026-02-27 23:13:15 +08:00
1eb9351604 refactor(auth): extract timestamp validation to separate function
Move timestamp validation logic from handlers to ValidateTimeStamp function in auth.go to avoid code duplication and improve maintainability
2026-02-27 21:21:18 +08:00
934190eebf feat: implement core functionality for super-frpc service
This commit introduces the core functionality for the super-frpc service including:
- Configuration management
- User authentication and authorization
- Database integration
- FRPC instance management
- API endpoints for user operations
- Token-based authentication system
- Password hashing and validation
2026-02-23 00:19:57 +08:00