D3 · 20% · CGRC

C03 — Tuân thủ bảo mật thông tin

Information Security & Compliance — Domain có trọng số cao nhất (20%): NIST CSF v2.0, ISO 27001:2022, kiểm soát PCI DSS 4.0, HIPAA audit management, control testing, evidence collection và internal audit lifecycle.

Tools
NIST CSF · ISO 27001
Platform
PowerShell · Bash
Quarter
Q2/2026
Updated
24/05/2026
Author
Trần Văn Hòa (MCT)
Version
v1.0

Mục tiêu bài học — Learning Objectives

  • Áp dụng NIST CSF v2.0 (6 Functions: Govern, Identify, Protect, Detect, Respond, Recover) vào gap analysis
  • Mapping ISO 27001:2022 Annex A controls (93 controls, 4 themes) với regulatory requirements
  • Thực hiện internal audit lifecycle: plan → fieldwork → reporting → follow-up
  • Thu thập và quản lý audit evidence theo chuẩn ISACA/IIA
  • Tự động hóa NIST CSF self-assessment với PowerShell và ISO 27001 gap analysis với Bash

Lý thuyết — Theory

1. NIST Cybersecurity Framework v2.0 — 6 Functions

CSF v2.0 (2024) bổ sung Function thứ 6 — Govern — phản ánh tầm quan trọng của governance trong cybersecurity. Không còn chỉ là kỹ thuật, mà là quản lý tổ chức.

GV — Govern (MỚI)

Cybersecurity risk strategy, expectations, policy. Là nền tảng cho 5 functions còn lại.

ID — Identify

Asset management, risk assessment, supply chain risk. Biết bạn đang bảo vệ cái gì.

PR — Protect

Access control, awareness training, data security, platform security, resilience.

DE — Detect

Continuous monitoring, adverse event analysis. Phát hiện bất thường kịp thời.

RS — Respond

Incident management, analysis, mitigation, reporting, communication.

RC — Recover

Restoration of assets, services, capabilities sau sự cố. Communications plan.

Maturity Tiers (1-4): Tier 1 (Partial) → Tier 2 (Risk Informed) → Tier 3 (Repeatable) → Tier 4 (Adaptive). Tier không phải "higher = better" mà là "phù hợp với risk tolerance của tổ chức."

2. ISO 27001:2022 — 93 Controls trong 4 Themes

ISO 27001:2022 cập nhật từ 114 controls (2013) xuống 93 controls, tổ chức lại thành 4 themes thay vì 14 domains. Bổ sung 11 new controls tập trung vào cloud, threat intelligence và ICT security.

4 Themes trong Annex A:
  • 5. Organizational (37 controls): Policies, roles, supplier security, IR
  • 6. People (8 controls): Screening, terms, awareness, remote work
  • 7. Physical (14 controls): Physical boundaries, equipment security
  • 8. Technological (34 controls): Access, cryptography, logging, dev security
11 New Controls (2022):
  • • 5.7 Threat intelligence
  • • 5.23 Information security for cloud use
  • • 5.30 ICT readiness for business continuity
  • • 7.4 Physical security monitoring
  • • 8.9 Configuration management
  • • 8.10 Information deletion
  • • 8.11 Data masking
  • • 8.12 Data leakage prevention (DLP)
  • • 8.16 Monitoring activities
  • • 8.23 Web filtering
  • • 8.28 Secure coding
Statement of Applicability (SoA): Tài liệu bắt buộc trong ISO 27001 listing tất cả 93 controls, trạng thái (applicable/not applicable), lý do loại trừ nếu có, và implementation status. Đây là "backbone" của ISMS certification.

3. Internal Audit Lifecycle

Audit nội bộ là cơ chế đảm bảo controls hoạt động hiệu quả như thiết kế. Theo IIA Standards, audit phải độc lập và objective — không phải là "compliance police" mà là business advisor.

1
Planning: Xác định scope, objectives, criteria, timeline. Risk-based audit plan (focus vào high-risk areas). Notify auditees.
2
Fieldwork: Thu thập evidence: interview, observation, document review, re-performance, inspection. Làm việc với auditees để hiểu process thực tế.
3
Reporting: Draft report → management review → final report. Phân loại findings: Critical/High/Medium/Low. Mỗi finding phải có: observation, criteria, evidence, risk, recommendation.
4
Follow-up: Kiểm tra implementation của management action plans. Track remediation tiến độ trong GRC platform. Re-test critical findings sau 30-90 ngày.

4. Evidence Collection & Control Testing

Quality of evidence quyết định chất lượng audit. Evidence phải đủ (sufficient), thích hợp (appropriate/reliable), và liên quan (relevant) để hỗ trợ conclusions.

Loại Evidence:
  • Physical: Screenshots, photos, printouts
  • Documentary: Policies, logs, configurations, reports
  • Testimonial: Interview notes, management representations
  • Analytical: Data analysis results, trend charts
  • Re-performance: Auditor reproduces the control
Control Testing Methods:
  • Inquiry: Hỏi auditees — lowest reliability
  • Observation: Xem control thực hiện trực tiếp
  • Inspection: Review documents/configurations
  • Re-performance: Thực hiện lại control — highest reliability
  • CAAT: Computer-assisted audit techniques (SQL, scripts)

5. PCI DSS 4.0 & HIPAA — Yêu cầu tuân thủ ngành

PCI DSS 4.0 — 12 Requirements:
R1Network Security Controls (thay Firewalls)
R2Secure Configurations — không dùng vendor defaults
R3Protect Stored Account Data — PAN masking, tokenization
R4Protect Cardholder Data in Transit — TLS 1.2+
R5Anti-malware — EDR bắt buộc
R6Secure Software Development — SAST/DAST, SCA
R7Restrict Access to System Components — least privilege
R8Identify Users & Authenticate — MFA bắt buộc
R9Restrict Physical Access to Cardholder Data
R10Log and Monitor Access — SIEM, 1 year retention
R11Test Security Regularly — pentest, vulnerability scan
R12Support Information Security — policies, ISMS
HIPAA Security Rule — Safeguards:
Administrative Safeguards (§164.308): Security management process, workforce training, access management, contingency plan, evaluation.
Physical Safeguards (§164.310): Facility access controls, workstation security, device/media controls.
Technical Safeguards (§164.312): Access control (unique user ID, MFA), audit controls, integrity controls, transmission security (TLS).
Breach Notification Rule: Báo cáo trong 60 ngày cho HHS; nếu >500 người trong 1 state → thông báo media ngay; hàng năm báo cáo breaches nhỏ hơn.

Bài thực hành — Hands-on Labs

LAB 01

NIST CSF Self-Assessment Tool — PowerShell CSV Report Generator

Platform
Windows / PowerShell 7
Tools
PowerShell, CSV/Excel
Output
CSF Gap Analysis Report
Thời gian
30 phút
Script: NIST CSF v2.0 self-assessment với scoring 1-5 theo từng subcategory
# NIST CSF v2.0 Self-Assessment Tool
# Score: 1=Initial, 2=Developing, 3=Defined, 4=Quantitatively Managed, 5=Optimizing

$csfAssessment = @(
    # GOVERN Function
    [PSCustomObject]@{ Function="GV"; Category="GV.OC"; Subcategory="GV.OC-01"; Description="Organizational mission understood"; Score=3; Target=4; Evidence="Mission statement published, security strategy aligned" },
    [PSCustomObject]@{ Function="GV"; Category="GV.RM"; Subcategory="GV.RM-01"; Description="Risk management objectives established"; Score=2; Target=4; Evidence="Risk appetite statement: draft, not approved" },
    [PSCustomObject]@{ Function="GV"; Category="GV.PO"; Subcategory="GV.PO-01"; Description="Security policy established"; Score=3; Target=4; Evidence="ISP v2.1 approved 2025-01, annual review scheduled" },

    # IDENTIFY Function
    [PSCustomObject]@{ Function="ID"; Category="ID.AM"; Subcategory="ID.AM-01"; Description="Asset inventory maintained"; Score=2; Target=4; Evidence="Manual spreadsheet, not auto-discovered, 60% coverage" },
    [PSCustomObject]@{ Function="ID"; Category="ID.RA"; Subcategory="ID.RA-01"; Description="Vulnerabilities identified"; Score=3; Target=4; Evidence="Nessus scan monthly, critical patched in 15 days avg" },
    [PSCustomObject]@{ Function="ID"; Category="ID.SC"; Subcategory="ID.SC-01"; Description="Supply chain risk managed"; Score=1; Target=3; Evidence="No formal vendor risk assessment process" },

    # PROTECT Function
    [PSCustomObject]@{ Function="PR"; Category="PR.AA"; Subcategory="PR.AA-01"; Description="Identities authenticated"; Score=3; Target=5; Evidence="MFA enabled for 85% users; 100% target" },
    [PSCustomObject]@{ Function="PR"; Category="PR.DS"; Subcategory="PR.DS-01"; Description="Data-at-rest protected"; Score=4; Target=4; Evidence="AES-256 on all databases, KMS managed" },
    [PSCustomObject]@{ Function="PR"; Category="PR.AT"; Subcategory="PR.AT-01"; Description="Security awareness conducted"; Score=3; Target=4; Evidence="Annual training, phishing sim quarterly, 83% completion" },

    # DETECT Function
    [PSCustomObject]@{ Function="DE"; Category="DE.CM"; Subcategory="DE.CM-01"; Description="Networks monitored"; Score=3; Target=4; Evidence="SIEM deployed, 90% log sources connected" },
    [PSCustomObject]@{ Function="DE"; Category="DE.AE"; Subcategory="DE.AE-01"; Description="Anomalies detected"; Score=2; Target=4; Evidence="Basic SIEM rules, no ML-based detection" },

    # RESPOND Function
    [PSCustomObject]@{ Function="RS"; Category="RS.MA"; Subcategory="RS.MA-01"; Description="Incident response plan tested"; Score=3; Target=4; Evidence="IRP tested via tabletop Q4 2025, gaps documented" },

    # RECOVER Function
    [PSCustomObject]@{ Function="RC"; Category="RC.RP"; Subcategory="RC.RP-01"; Description="Recovery plan tested"; Score=2; Target=4; Evidence="BCP exists, last DR test 2024-02, RTO not validated" }
)

# Tính toán gaps và scores
$results = $csfAssessment | ForEach-Object {
    $_ | Add-Member -NotePropertyName Gap   -NotePropertyValue ($_.Target - $_.Score) -PassThru |
        Add-Member -NotePropertyName Status -NotePropertyValue (if ($_.Score -ge $_.Target) { "MET" } elseif ($_.Gap -le 1) { "MINOR GAP" } else { "GAP" }) -PassThru
}

$results | Export-Csv "C:\GRC\csf-assessment.csv" -NoTypeInformation -Encoding UTF8

# Summary by Function
$results | Group-Object Function | ForEach-Object {
    $avgScore  = ($_.Group | Measure-Object Score -Average).Average
    $avgTarget = ($_.Group | Measure-Object Target -Average).Average
    [PSCustomObject]@{ Function=$_.Name; AvgScore=[math]::Round($avgScore,1); AvgTarget=[math]::Round($avgTarget,1); Gaps=($_.Group | Where-Object Status -ne "MET").Count }
} | Format-Table -AutoSize
KẾT QUẢ ĐẦU RA (Expected Output)
Function  AvgScore  AvgTarget  Gaps
--------  --------  ---------  ----
DE        2.5       4.0        2
GV        2.7       4.0        2
ID        2.0       3.7        3
PR        3.3       4.3        2
RC        2.0       4.0        1
RS        3.0       4.0        1

Critical gaps (Score vs Target ≥ 2):
  ID.SC-01: Supply chain risk — Score 1, Target 3 [GAP: 2]
  DE.AE-01: Anomaly detection — Score 2, Target 4 [GAP: 2]
  GV.RM-01: Risk management — Score 2, Target 4 [GAP: 2]

CSV: C:\GRC\csf-assessment.csv [13 subcategories assessed]
LAB 02

ISO 27001 Gap Analysis Script — Bash kiểm tra Linux system controls

Platform
Ubuntu 22.04 / RHEL 9
Tools
Bash, auditd, systemctl
Controls
ISO 27001 Annex A
Thời gian
25 phút
#!/bin/bash
# ISO 27001:2022 Gap Analysis — Linux System Controls

REPORT="/tmp/iso27001-gap-analysis.txt"
PASS=0; FAIL=0; WARN=0

check_control() {
    local control=$1 desc=$2 status=$3 finding=$4
    printf "%-10s %-45s [%s] %s\n" "$control" "$desc" "$status" "$finding" | tee -a $REPORT
    case $status in
        PASS) (( PASS++ )) ;;
        FAIL) (( FAIL++ )) ;;
        WARN) (( WARN++ )) ;;
    esac
}

echo "=== ISO 27001:2022 Gap Analysis — $(hostname) — $(date) ===" | tee $REPORT
echo "" | tee -a $REPORT

# 8.2 — Privileged access rights
SUDO_USERS=$(getent group sudo 2>/dev/null || getent group wheel 2>/dev/null | cut -d: -f4)
if [ -z "$SUDO_USERS" ]; then
    check_control "8.2" "Privileged access rights" "WARN" "Cannot enumerate sudo group"
else
    check_control "8.2" "Privileged access rights" "PASS" "Sudo users: $SUDO_USERS"
fi

# 8.5 — Secure authentication (SSH key auth, password auth disabled)
SSH_PWAUTH=$(grep -i "^PasswordAuthentication" /etc/ssh/sshd_config 2>/dev/null | awk '{print $2}')
if [ "$SSH_PWAUTH" = "no" ]; then
    check_control "8.5" "Secure authentication — SSH" "PASS" "PasswordAuthentication disabled"
else
    check_control "8.5" "Secure authentication — SSH" "FAIL" "PasswordAuthentication=$SSH_PWAUTH (should be no)"
fi

# 8.15 — Logging (auditd running)
if systemctl is-active --quiet auditd; then
    check_control "8.15" "Logging — auditd service" "PASS" "auditd is active"
else
    check_control "8.15" "Logging — auditd service" "FAIL" "auditd not running — install: apt install auditd"
fi

# 8.9 — Configuration management (unattended-upgrades)
if dpkg -l unattended-upgrades &>/dev/null; then
    check_control "8.9" "Configuration mgmt — auto updates" "PASS" "unattended-upgrades installed"
else
    check_control "8.9" "Configuration mgmt — auto updates" "FAIL" "unattended-upgrades not installed"
fi

# 8.20 — Network security (firewall)
if command -v ufw &>/dev/null && ufw status | grep -q "Status: active"; then
    check_control "8.20" "Network security — firewall" "PASS" "UFW active"
elif command -v firewall-cmd &>/dev/null && firewall-cmd --state 2>/dev/null | grep -q running; then
    check_control "8.20" "Network security — firewall" "PASS" "firewalld active"
else
    check_control "8.20" "Network security — firewall" "FAIL" "No active firewall detected"
fi

# 8.7 — Anti-malware (ClamAV or other)
if command -v clamscan &>/dev/null || command -v freshclam &>/dev/null; then
    check_control "8.7" "Malware protection — ClamAV" "PASS" "ClamAV installed"
else
    check_control "8.7" "Malware protection" "WARN" "ClamAV not found — verify EDR agent"
fi

echo "" | tee -a $REPORT
echo "=== SUMMARY: PASS=$PASS WARN=$WARN FAIL=$FAIL ===" | tee -a $REPORT
echo "Report: $REPORT"
KẾT QUẢ ĐẦU RA (Expected Output)
=== ISO 27001:2022 Gap Analysis — ubuntu-prod-01 — 2026-05-24 ===

8.2        Privileged access rights             [PASS] Sudo users: devops,deploy
8.5        Secure authentication — SSH          [FAIL] PasswordAuthentication=yes (should be no)
8.15       Logging — auditd service             [PASS] auditd is active
8.9        Configuration mgmt — auto updates    [PASS] unattended-upgrades installed
8.20       Network security — firewall          [PASS] UFW active
8.7        Malware protection — ClamAV          [WARN] ClamAV not found — verify EDR agent

=== SUMMARY: PASS=4 WARN=1 FAIL=1 ===
Report: /tmp/iso27001-gap-analysis.txt

Priority action: Fix 8.5 (SSH password auth) — High risk finding

Tình huống doanh nghiệp — Business Scenario

CASE STUDY — Saigon Payment Hub (PCI DSS Audit)

Saigon Payment Hub xử lý thanh toán cho 200 merchants. QSA (Qualified Security Assessor) phát hiện trong audit PCI DSS 4.0: R8 — MFA chỉ áp dụng cho remote access, không áp dụng cho console access vào CDE (Cardholder Data Environment). Critical finding — có thể bị fine hoặc mất PCI compliance certificate.

!
Finding: 3 administrators có thể console vào payment servers dùng password only (không MFA). Vi phạm PCI DSS 4.0 Requirement 8.4.2.
1
Compensating Control (immediate): Enable jump server với MFA (PAM solution — CyberArk) cho tất cả console access vào CDE. Completed trong 48 giờ.
2
Root Cause: Policy chỉ nói "MFA cho remote access" — không bao phủ console/physical access. Policy update ngay: "MFA required for ALL access vào CDE regardless of access method."
3
Evidence Package cho QSA: Screenshot CyberArk config, test log showing MFA prompt, updated policy signed by CISO. QSA closed finding trong lần review tiếp theo.

Tự kiểm tra — Self-Assessment (5 câu)

1. NIST CSF v2.0 bổ sung Function nào so với v1.1?

A. Govern (GV) ✓
B. Identify (ID)
C. Supply Chain (SC)
D. Manage (MG)

2. Tài liệu nào là BẮT BUỘC trong ISO 27001 và liệt kê tất cả 93 controls cùng trạng thái applicable/not applicable?

A. Risk Assessment Report
B. Information Security Policy
C. Statement of Applicability (SoA) ✓
D. Business Impact Analysis

3. Phương pháp test control nào có độ tin cậy cao nhất khi auditor muốn xác minh control hoạt động?

A. Inquiry (hỏi auditees)
B. Observation
C. Inspection
D. Re-performance ✓

Re-performance = auditor tự thực hiện lại control để verify — highest reliability vì không phụ thuộc vào auditee's statement.

4. PCI DSS 4.0 Requirement nào yêu cầu MFA cho tất cả access vào CDE?

A. R6 (Secure Development)
B. R7 (Restrict Access)
C. R8 (Identify Users & Authenticate) ✓
D. R10 (Log and Monitor)

5. HIPAA Breach Notification Rule yêu cầu thông báo cho media (báo chí địa phương) khi nào?

A. Bất kỳ breach nào ảnh hưởng đến ePHI
B. Breach ảnh hưởng hơn 100 người
C. Breach ảnh hưởng hơn 500 người trong cùng một bang (state) ✓
D. Breach ảnh hưởng hơn 1,000 người toàn quốc
C02: GRC Program Operations C04: Risk Management
Zalo