- Debojyoti Mishra
- Phuong Khanh Pham
A real-time trust engine for web applications (e.g. banking portal) that flags malicious users based on:
- Behavior patterns
- Relationships
- Metadata
The system makes split-second decisions on user access levels.
- High-stakes data: financial info, personal data
- Real-world fraud detection
- Simulate trust decisions like:
- Flagging unusual transactions
- Locking accounts on suspicious logins
- Detects suspicious behavior
- Rich metadata: location, device, time, transaction patterns
- Maps user relationships, IPs, device, behavior
- Detects patterns like:
- Shared devices/IPs
- Suspicious user networks
- Stores raw logs and semi-structured data:
- Login attempts
- Device/browser data
- User history and flags
- User-uploaded content
- Real-time scoring and blacklist decisioning
- Caching known results
- Queueing behavior events
- User logs in
- Redis fetches cached trust score (FAST). If borderline:
- MongoDB provides raw metadata
- Neo4j checks user’s network links
- If user is linked (e.g. 3 hops from a known bot), access is restricted
- Redis updates trust score → future calls blocked instantly
-
User Logs In
- Sends device, IP, username to backend
-
Redis Checks Trust Score
- If cached, returns immediately
- Otherwise, proceed to MongoDB
-
MongoDB Logs User Info
- Stores login data, profile, device/browser, location
-
Neo4j Evaluates User Connections
- Example query:
MATCH (a:User)-[:SHARED_IP_WITH]-(b:User {blacklisted: true}) RETURN a
- Example query:
-
Trust Score Calculated (Rule-Based)
-
Suspicious connection → −20 pts
-
New account → −5 pts
-
Same IP/MAC as 5+ users → −30 pts
-
If the user has circular transaction → -30 pts
-
Spend >2x average → −30 pts
- Final score stored in Redis for ultra-fast lookup
- For the clearer flow explanation, checkout the doc AntiScamFlow.md
-
-
Limitations based on Trust Score
Score | Description | Limitations |
---|---|---|
90 – 100 | Trusted user | No restrictions |
75 – 89 | Normal user | Max €5,000 total in 3 months |
50 – 74 | Risky user | Max 3 transactions > €1,000 in 1 months |
30 – 49 | Fraud-prone user | Max 10 transactions/month, each < €100 |
< 30 | Critical – Account temporarily locked | No transactions allowed, identity verification required |
- Create a .env file, follow the
.env.sample
file - Run
docker compose up --build
- Transition from rule-based to ML-based scoring
- Visualization of trust graphs
- Admin dashboard with alerts and logs