How damanegi2005/bamtibam works
BAMTIBAM is a web-security practice testbed presented as a shopping mall: users browse products, review them, manage a cart, and place orders, while administrators manage users, products, reviews, and order status. The README describes the security-testing purpose; sampled runtime code shows the storefront and backend API, with MySQL access through a connection pool. Backend endpoint details are only partially excerpted, so links from the API client to server subsystems are documented via the matching API contract where visible, and otherwise omitted.
Main entry points: App.jsx App routes · index.js Express API · api.js HTTP API client · Home.jsx Product catalog
Components 20
Storefront
- App routes
src/App.jsx - Navigation shell
src/components/Layout.jsx - Product catalog
src/pages/Home.jsx - Product details
src/components/ProductModal.jsx - Registration
src/pages/Signup.jsx - Login
src/pages/Login.jsx - Cart and checkout
src/pages/Cart.jsx - My account
src/pages/MyPage.jsx - Admin console
src/pages/Admin.jsx - HTTP API client
src/lib/api.js
Application API
- Express API
server/src/index.js - Input validation
server/src/validators.js - Authentication
server/src/index.js - Catalog endpoints
server/src/index.js - Review endpoints
server/src/index.js - Cart and orders
server/src/index.js - Admin operations
server/src/index.js
Persistence
- MySQL pool
server/src/db.js - MySQL database
Other components
- Shopper
Connections 25
- Shopper → App routes: uses
- App routes → Navigation shell: wraps routes
src/App.jsx - App routes → Product catalog: routes to
src/App.jsx - App routes → Registration: routes to
src/App.jsx - App routes → Login: routes to
src/App.jsx - App routes → Cart and checkout: routes to
src/App.jsx - App routes → My account: routes to
src/App.jsx - App routes → Admin console: routes to
src/App.jsx - Product catalog → HTTP API client: requests products
src/pages/Home.jsx - Product catalog → Product details: opens details
src/pages/Home.jsx - Product details → HTTP API client: requests reviews and cart
src/components/ProductModal.jsx - Registration → HTTP API client: submits account
src/pages/Signup.jsx - Login → HTTP API client: submits credentials
src/pages/Login.jsx - Cart and checkout → HTTP API client: manages cart and orders
src/pages/Cart.jsx - My account → HTTP API client: requests account data
src/pages/MyPage.jsx - Admin console → HTTP API client: manages resources
src/pages/Admin.jsx - HTTP API client → Express API: HTTP requests
src/lib/api.js - Express API → Authentication: handles auth routes
server/src/index.js - Express API → Catalog endpoints: handles product routes
server/src/index.js - Express API → Review endpoints: handles review routes
server/src/index.js - Express API → Cart and orders: handles cart and orders
server/src/index.js - Express API → Admin operations: handles admin routes
server/src/index.js - Express API → MySQL pool: queries
server/src/index.js - Authentication → Input validation: validates inputs
- MySQL pool → MySQL database: connects
server/src/db.js