# Security Architecture, Threat Boundaries & Legal Disclaimer
# 安全架構、風險邊界與免責聲明

## 1. Security Model & Honest Control Boundaries
## 一、 安全模型與控制邊界聲明

`EnterpriseDemo-CBPA` is architected specifically for **asymmetric M365 licensing** (unlicensed regional intake vs. licensed HQ governance). To maintain audit transparency, security controls are classified strictly by their true assurance level:

### A. Record Matching vs. Identity Authentication（記錄比對 vs. 強身分驗證）
- **External Forms (`Demo-Form 1, 2, 4` — `Anyone can respond`)**:
  - Uses a combination of `AppraisalID` (`DEMO-2026-XXXX`), a random 8-character `SubmissionKey`, and expected email matching.
  - **Classification**: **Risk-Based Record Matching / Validation（記錄比對校驗）**. It significantly raises the barrier against accidental submission errors or unauthorized URL guessing, **but does NOT constitute strong cryptographic Identity Authentication** (anyone possessing both the link and email could submit).
  - **Mitigating Controls**: One-way **Status Gate** (`CurrentStatus == ExpectedStatus`) blocks replay submissions; dual confirmation ensures managers and employees independently verify records before HR review.
- **Internal Manager Form & Approvals (`Demo-Form 3` & M365 Approvals)**:
  - **Classification**: **Authenticated Identity Verification（Entra ID 身分驗證）**. Enforces `Only people in my organisation` plus Flow-level authorization verification (`toLower(responder) == toLower(AppraiserEmail)`).

### B. Change Traceability vs. Enterprise Audit Logging（變更追溯 vs. 企業級審計日誌）
- **SharePoint Version History** and **M365 Approvals timestamps** provide operational **change traceability evidence** suitable for SME annual appraisal cycles.
- They are **not** presented as a standalone immutable SIEM or WORM (Write-Once-Read-Many) compliance archive. Organizations requiring tamper-evident cryptographic logging should forward M365 Unified Audit Logs (Purview) to an external SIEM.

### C. Access Control & Data Isolation（存取控制與機密隔離）
- **Backend Isolation**: Inheritance is broken on `Demo_Appraisal_2026`. Only HR Approver (`Full Control`), HR Support (`Edit`), and Executive Approver (`Read/View Only`) can access the list.
- **Section D Confidentiality**: Employee confirmation emails dynamically render Sections A–C only; HR recommendations (Section D) are strictly isolated to the SharePoint backend and Executive Approval summary.
- **Post-Approval Immutability**: Upon final Executive sign-off (`7_Archived`), `Flow 3` executes `Stop sharing an item or a file` followed by read-only `Grant access (Can view)` to lock completed records.
- **Concurrency Safety**: `Flow 3` enforces `Concurrency Control = On` (`Degree of Parallelism = 1`) combined with a Status Batch Gate to prevent race conditions and duplicate executive approvals.

---

## 2. Sanitization & Privacy Assurance
## 二、 脫殼清洗與零真實資料聲明

All content in this repository has been sanitized under a strict de-identification protocol:
- All organization names, internal form codes, tenant URLs, user identities, and sample payloads have been replaced with generic placeholders (`Enterprise Demo`, `Demo-Form`, `user@companydemo.com`, `https://demo-tenant.sharepoint.com`).
- **Zero production data, employee PII, tenant IDs, or API secrets** are contained in this repository or its commit history.

---

## 3. Disclaimer & Limitation of Liability
## 三、 法律免責與責任限制聲明

1. **Educational & Portfolio Purpose Only（僅供架構展示與技術參考）**: This repository is a Proof of Work illustrating M365 workflow governance patterns. It is provided **"AS IS"**, without warranty of any kind, express or implied, including merchantability, fitness for a particular purpose, or non-infringement.
2. **Not Legal or Compliance Advice（不構成法律或合規意見）**: Regulatory mappings (including references to Hong Kong PDPO, PRC PIPL/CAC, ISO standards, EU AI Act, and GDPR) reflect architectural scoping principles as of the date of publication and **do not constitute formal legal advice or compliance certification**. Organizations adopting these patterns must consult qualified legal counsel and conduct their own Data Protection / Personal Information Protection Impact Assessments (DPIA / PIPIA) tailored to their specific jurisdiction, labor policies, and M365 tenant configuration.
3. **Tenant Security Responsibility（租戶安全責任歸屬）**: The author accepts no liability for data loss, misconfigured SharePoint permissions, tenant-specific connector changes, or regulatory non-compliance arising from third-party deployment of these templates.

---

## 4. Reporting Security Concerns
## 四、 安全議題回報

If you identify any unintended placeholder leak or architectural vulnerability in these demo specifications, please open a GitHub Issue or contact the repository maintainer directly.
