Skip to content

RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.

Feat: Reject default admin account log in to normal services (#11994)

Magicbook11087baa67dfe853
diff --git a/api/apps/user_app.py b/api/apps/user_app.py
index 53876826cd..50c0b4d764 100644
--- a/api/apps/user_app.py
+++ b/api/apps/user_app.py
@@ -98,6 +98,9 @@ async def login():
return get_json_result(data=False, code=RetCode.AUTHENTICATION_ERROR, message="Unauthorized!")
email = json_body.get("email", "")
+ if email == "[email protected]":
+ return get_json_result(data=False, code=RetCode.AUTHENTICATION_ERROR, message="Default admin account cannot be used to login normal services!")
+
users = UserService.query(email=email)
if not users:
return get_json_result(