How taylorliu11/securitylog-cleaning works
What this project is (type + purpose)
From the tree + README, this is an ETL pipeline project focused on processing raw AWS Honeypot security logs. It has three major parts:
• ETL scripts (Python): cleaning + loading logic (etl/cleaner.py, etl/database_loader.py)
• Backend service (TypeScript/Node, likely Cloudflare Workers): API/RPC layer (backend/src/index.ts, backend/wrangler.toml)
• Frontend (static HTML): minimal UI entrypoint (frontend/index.html)
• SQL assets: schema + stored procedures/RPC (sql/setup_table.sql, sql/dashboard_rpc.sql)
• CI/CD deployment: GitHub Actions workflow (.github/workflows/deploy.yml)
ETL layer (etl/)
• cleaner.py: transformation/normalization of raw logs (parse, sanitize, dedupe, enrich, etc.)
• database_loader.py: persistence step (connects to DB, inserts/updates tables)
Database layer (sql/)
• setup_table.sql: initial schema/table definitions
• dashboard_rpc.sql: database-side RPC functions / views / stored queries to support dashboarding
Backend API layer (backend/)
• src/index.ts: request handler / API routes / RPC proxy
• wrangler.toml: strong indicator this is Cloudflare Workers (or at least wrangler-based deployment)
• package.json + tsconfig.json: TypeScript build tooling
Frontend (frontend/)
• index.html: likely a static page (maybe a simple dashboard, possibly calling backend endpoints)
Deployment (.github/workflows/deploy.yml)
CI/CD as a side-lane: “GitHub Actions deploy → Worker + (maybe) frontend hosting”. Even if minimal, include it because it explains how things get released.
What to include from the README (and what’s missing)
• which DB is used (D1, Postgres, Supabase, R2, etc.)
• what endpoints exist and whether it’s true “RPC” passthrough
• Inspect etl/database_loader.py for:
• connection string type (psycopg2, sqlalchemy, sqlite, etc.)
• target tables and write patterns (append-only vs upsert, partitioning, etc.)
Raw AWS Honeypot Logs (Source)
• “AWS” boundary around it if applicable
ETL Batch Pipeline (Python)
• Optional: “Scheduler/Trigger” (cron, GitHub Actions, AWS EventBridge) — mark TBD if not found
Database
• “Schema: setup_table.sql”
• “RPC/queries: dashboard_rpc.sql”
Backend API (Cloudflare Worker, TypeScript)
• src/index.ts
• Deployed via wrangler.toml
• Role: serves dashboard data, calls DB RPC or runs queries
Frontend (Static Web UI)
• frontend/index.html
• Role: calls backend API, renders dashboard
CI/CD
• GitHub Actions workflow (deploy.yml) deploying worker and possibly frontend/sql migrations
• Logs Source → ETL Cleaner
• ETL Cleaner → ETL Loader
• ETL Loader → Database
• Frontend → Backend API
• Backend API → Database
• DB → Backend API → Frontend
• GitHub Actions → Cloudflare Workers
• GitHub Actions → Static Hosting (if used)
Architectural patterns/design principles
• Separation of concerns:
• Batch ETL (Python) is isolated from online serving (Worker + frontend)
• Data contract boundary:
• Cleaned schema in DB becomes the contract between ETL and serving layer
• Serverless edge API:
• Worker provides low-latency API without managing servers
• DB-centric analytics:
• dashboard_rpc.sql implies pushing aggregation logic into DB for efficiency and consistency
Relevant technologies
Where confirmed or strongly implied:
• Python ETL scripts
• TypeScript backend
• Cloudflare Workers/Wrangler (very likely due to wrangler.toml)
• SQL migrations / stored procedures
• GitHub Actions for deploy
If DB type isn’t confirmed yet, put “Database (TBD: Postgres/MySQL/D1/…)” until verified.