feat: enhance login process with IP capture and improved error handling
- Implemented an internal mutation for login that captures the user's IP address and user agent for better security and tracking. - Enhanced the HTTP login endpoint to extract and log client IP, improving the overall authentication process. - Added validation for IP addresses to ensure only valid formats are recorded, enhancing data integrity. - Updated the login mutation to handle rate limiting and user status checks more effectively, providing clearer feedback on login attempts.
This commit is contained in:
@@ -101,7 +101,8 @@
|
||||
carregandoLogin = true;
|
||||
|
||||
try {
|
||||
// Capturar informações do navegador
|
||||
// Usar mutation normal com WebRTC para capturar IP
|
||||
// getBrowserInfo() tenta obter o IP local via WebRTC
|
||||
const browserInfo = await getBrowserInfo();
|
||||
|
||||
const resultado = await convex.mutation(api.autenticacao.login, {
|
||||
|
||||
Reference in New Issue
Block a user