Team Members:
| Full Name | Student ID | Role |
|---|---|---|
| Võ Tấn Phát | SE194484 | Team Leader |
| Bùi Minh Hiển | SE190829 | Member |
| Dương Nguyên Bình | SE194067 | Member |
| Trần Vinh | SE193927 | Member |
| Nguyễn Duy Tùng | SE196572 | Member |
| Nguyễn Đức Trí | SE194091 | Member |
GuardScript is a script distribution platform with loader-based access control. Instead of distributing source code directly, the system serves script content through controlled endpoints with signature checks, timestamp/nonce validation, license enforcement, HWID binding, and workspace access policies.
The solution uses a serverless AWS architecture to reduce operational overhead, support scale, and satisfy cloud workshop objectives.
The team identified three key issues in script delivery workflows:
The proposed system addresses these issues through:
The architecture follows a serverless model with edge delivery for frontend and Lambda-based API processing.
Typical request flow:
Client (browser / loader)
→ CloudFront Distribution (SSL termination, cache layer)
→ Static assets: S3 bucket (frontend)
→ API /api/*, /files/*: Lambda Function URL origin
→ DynamoDB (users, workspaces, projects, licenses, logs, rate_limits, ...)
→ S3 (script/content objects)
→ API Gateway WebSocket (real-time updates)
→ CloudWatch Logs / Alarms / Dashboard

| Layer | Service | Details |
|---|---|---|
| Runtime API | AWS Lambda (Node.js 20.x) | Modular monolith backend handlers |
| Database | Amazon DynamoDB | Multi-table model, PAY_PER_REQUEST, TTL for temporary records |
| Object Storage | Amazon S3 | Frontend hosting and content objects |
| CDN & Edge | Amazon CloudFront | Static delivery and route behaviors for /api/*, /files/* |
| Edge Security | AWS WAF | Protects against malicious web requests at CloudFront edge |
| TLS/SSL | AWS Certificate Manager | Manages SSL/TLS certificates for HTTPS |
| Notification | Amazon SNS / SES | Sends alerts and email notifications (invitations, alarms) |
| Monitoring | Amazon CloudWatch | Alarms for errors/throttles/p95 duration + operational dashboard |
| Real-time | API Gateway WebSocket API | Workspace/user/admin event broadcasting |
| Delivery | GitHub Actions + SAM | Automated infrastructure and frontend deployment |
Errors, Throttles, and p95 Duration.Functional Requirements:
Non-Functional Requirements:
| Category | Requirement |
|---|---|
| Security | HMAC-signed requests, ECDH key exchange, replay protection via nonce + timestamp |
| Performance | p95 API response < 500ms; CloudWatch alarms for latency breaches |
| Scalability | Serverless Lambda + DynamoDB on-demand auto-scales with load |
| Availability | CloudFront edge delivery; S3 high-durability object storage (99.999999999%) |
| Maintainability | Modular Lambda monolith; SAM/CloudFormation IaC for reproducible infrastructure |
| Observability | CloudWatch metrics, alarms, and dashboard; structured per-workspace application logs |
Technical Stack:
| Component | Technology |
|---|---|
| Runtime | Node.js 20.x on AWS Lambda |
| Database | Amazon DynamoDB (PAY_PER_REQUEST) |
| Storage | Amazon S3 |
| Edge / CDN | Amazon CloudFront + AWS WAF |
| Real-time | API Gateway WebSocket API |
| Auth | Custom HMAC-SHA256 token system |
| Encryption | AES-256-GCM, ECDH X25519, PBKDF2-SHA256 |
| IaC | AWS SAM / CloudFormation |
| CI/CD | GitHub Actions |
| Monitoring | Amazon CloudWatch (Logs, Alarms, Dashboard) |
The project follows Agile Scrum methodology with 6 sprints (1 week each):
Sprint 1 — Analysis & Architecture Design
Sprint 2 — Backend Foundation
Sprint 3 — Script & File Management
Sprint 4 — Security & Access Control
Sprint 5 — Frontend & Realtime
Sprint 6 — CI/CD & Deployment
| Phase | Content | Timeline |
|---|---|---|
| 1. Analysis & Architecture Design | AWS onboarding, GuardScript scope definition, architecture design, DynamoDB schema, API planning | Week 1–6 |
| 2. Backend Foundation | Project kickoff, auth, workspace, project, file, and license APIs | Week 7–8 |
| 3. Script, File & AWS Migration | Encryption module, S3 integration, Lambda/DynamoDB/CloudFront setup, loader protocols | Week 8–9 |
| 4. Security & Access Control | Loader v2/v3 hardening, HWID lock, access-list policies, rate-limit validation | Week 9–11 |
| 5. Frontend & Realtime | Dashboard/workspace UI, WebSocket integration, responsive design, overall testing | Week 7–10 |
| 6. CI/CD & Documentation | SAM/CloudFormation deployment, CloudWatch monitoring, validation checklist, final reporting | Week 11–12 |
Typical monthly infrastructure cost (Free Tier / Small Scale): ~$4.32/month
| Service | Estimated Cost | Notes |
|---|---|---|
| AWS Lambda | ~$0.00/month | Free tier: 1M requests/month |
| Amazon DynamoDB | ~$0.60/month | On-demand; 25 GB free storage |
| Amazon S3 | ~$0.80/month | Frontend hosting + content storage |
| Amazon CloudFront | ~$0.77/month | 1 TB free transfer (first year) |
| Amazon CloudWatch | ~$0.50/month | 30-day log retention, alarms, dashboard |
| API Gateway WebSocket | ~$0.35/month | WebSocket connections |
| Amazon SES | ~$0.09/month | Email notifications and invitations |
| Amazon SNS | ~$0.00/month | Alert notifications (mostly free tier) |
| AWS WAF | ~$0.21/month | Edge protection rules |
| AWS ACM | ~$0.00/month | SSL/TLS certificates (free for CloudFront) |
| AWS IAM | ~$0.00/month | No direct cost |
| Total | ~$4.32/month | Usage-based, serverless pay-per-use |
Lambda and DynamoDB are mostly covered by the free tier at low usage levels.
| Risk | Impact | Probability | Mitigation |
|---|---|---|---|
| Lambda cold start latency | Medium | Medium | Optimize handlers and monitor p95 |
| DynamoDB throttling | High | Low | On-demand scaling, CloudWatch alerts |
| S3 PUT/GET failures | High | Low | Retry logic, versioning enabled |
| Budget overrun | Medium | Low | AWS Budgets alerts, optimize TTL/cache |
| Replay attacks | High | Low | Timestamp + nonce + HMAC required |
Contingency Plan:
Technical Outcomes:
Long-term Value: