| name | theme-hr_portal |
| description | HR / workforce application palette: variants, pages, entities, and flows for building a varied HR app. Use when theme_preset is hr_portal.
|
HR portal theme
Domain
Internal apps where employees manage their own info and managers/HR act on
others. The org hierarchy (employee โ manager โ HR/admin) and ownership of
payroll/PII are where privilege and access exploits live.
Application variants โ pick ONE per lab
Honor any hint in theme_free_text / custom_prompt; otherwise pick one.
- Employee self-service โ profile, payslips, PTO, documents, directory.
- Recruiting / ATS โ job reqs, candidates, applications, interview notes.
- Payroll & benefits โ payslips, tax forms, benefit enrollment.
- Performance reviews โ goals, review cycles, peer feedback.
- Time & attendance โ clock in/out, timesheets, approvals.
- Learning & development โ courses, enrollments, completions, certifications.
- Expense & travel reimbursement โ expense reports, receipts, approval, payout.
Roles โ choose the set that fits the variant
- user (employee) โ own profile, payslips, PTO requests, documents.
- manager โ approve direct reports' requests, view their info.
- admin (HR) โ all employees, payroll, role assignment.
Most exploits run as user.
Candidate pages โ select a coherent subset
Size the subset to endpoint_count. Candidates: dashboard/overview, my profile,
payslips, tax documents, PTO request & balance, my documents, org directory,
team view (manager), approvals (manager), profile/settings, notifications,
candidates / applications / interview notes (ATS), benefits enrollment / plans
(payroll & benefits), review cycle / goals / feedback (performance), timesheets /
clock in-out / shifts (time & attendance), admin employees, admin payroll.
Candidate entities (seed tables) โ select what the variant needs
- users โ id, email, password_hash, role, employee_id
- employees โ id, name, title, department, manager_id, salary_cents
- payslips โ id, employee_id, period, gross_cents, net_cents, document_path?
- pto_requests โ id, employee_id, kind, start, end, status, approver_id
- documents โ id, owner_employee_id, kind, path
- notifications โ id, employee_id, kind, body, read_at
Recruiting / ATS (variant):
- job_reqs โ id, title, department, hiring_manager_id, status
- candidates โ id, name, email, source, current_stage
- applications โ id, candidate_id, job_req_id, stage, status
- interviews โ id, application_id, interviewer_id, scheduled_at, notes, rating
Payroll & benefits (variant):
- benefit_plans โ id, name, kind, premium_cents, employer_match_bps
- enrollments โ id, employee_id, benefit_plan_id, coverage, status, effective_at
- tax_forms โ id, employee_id, year, kind, document_path?
Performance reviews (variant):
- review_cycles โ id, name, period, status
- goals โ id, employee_id, cycle_id, title, target, progress, status
- reviews โ id, employee_id, reviewer_id, cycle_id, body, rating
- feedback โ id, subject_employee_id, author_employee_id, body, visibility
Time & attendance (variant):
- timesheets โ id, employee_id, period, total_hours, status, approver_id
- time_entries โ id, timesheet_id, date, clock_in, clock_out, hours
- shifts โ id, employee_id, start, end, role, status
Seed several employees under โฅ2 managers so cross-report access is testable.
Candidate user flows โ select the ones matching chosen pages/features
- Dashboard โ view my payslips โ download a payslip.
- Submit a PTO request โ manager approves โ balance updates.
- Update my profile / emergency contact.
- Browse org directory โ open a colleague's public profile.
- (manager) Review and approve a direct report's request.
- (ATS) Create a job req โ add a candidate โ move them through interview stages, adding notes.
- (ATS) Schedule an interview โ record a rating โ advance or reject the application.
- (payroll & benefits) Browse benefit plans โ enroll in one โ view tax forms.
- (performance) Set a goal in the active cycle โ request peer feedback โ submit a self-review.
- (time & attendance) Clock in/out โ fill a timesheet โ submit for manager approval.
Candidate endpoints โ a feature may span several
Endpoints are a shared surface, not owned 1:1 by a feature (a single feature
often spans several, and an endpoint can back multiple features). Pick a coherent
subset alongside the pages above. Grouped by area:
- profile / employees โ
GET /api/employees/{id}, PUT /api/employees/{id}, GET /api/directory
- payslips โ
GET /api/employees/{id}/payslips, GET /api/payslips/{id}, GET /api/payslips/{id}/download
- pto โ
GET /api/pto, POST /api/pto, POST /api/pto/{id}/approve
- documents โ
GET /api/documents, GET /api/documents/{id}/download?file=
- recruiting (ATS) โ
GET/POST /api/job-reqs, GET/POST /api/candidates, GET/POST /api/applications, POST /api/applications/{id}/stage, GET/POST /api/interviews
- benefits (payroll & benefits) โ
GET /api/benefit-plans, GET/POST /api/enrollments, GET /api/tax-forms/{id}
- performance (performance) โ
GET/POST /api/goals, GET/POST /api/reviews, GET/POST /api/feedback
- time (time & attendance) โ
POST /api/clock, GET/POST /api/timesheets, POST /api/timesheets/{id}/approve, GET/POST /api/shifts
- admin โ
/api/admin/employees, /api/admin/payroll, POST /api/admin/employees/{id}/role
Where vulnerabilities fit naturally
- idor โ
GET /api/employees/{id}/payslips, /api/employees/{id} salary โ read another employee's payroll/PII.
- privilege_escalation โ employee gaining manager/HR role; approving own request.
- business_logic โ approve own PTO, request negative hours, exceed PTO balance, self-approval via manager_id tamper.
- path_traversal โ document/payslip download
file= parameter.
- xss โ review feedback, candidate interview notes rendered to others.
- auth_bypass โ reach admin payroll without a valid HR session.
Diversity guidance
Pick ONE variant and a coherent subset โ an ATS and a payroll app diverge
sharply. Size to endpoint_count; let theme_free_text / custom_prompt bias
the variant and naming. Vary departments, hierarchy depth, and document types so
two HR labs feel like different companies.