MD-102 Giai đoạn 2 – Quản lý ứng dụng Module 08
08

Mobile Application Management (MAM)

App Protection Policies • MAM-WE • Selective Wipe • Conditional Access

Microsoft Intune Entra ID MD-102 GĐ2

01 · Lý thuyết

MAM là gì và tại sao quan trọng?

Mobile Application Management (MAM) trong Microsoft Intune cho phép bảo vệ dữ liệu doanh nghiệp ở cấp ứng dụng — không cần thiết bị phải được enroll vào MDM. Điều này cực kỳ quan trọng trong mô hình BYOD (Bring Your Own Device) nơi nhân viên dùng thiết bị cá nhân để làm việc.

Intune MAM hoạt động thông qua App Protection Policies (APP) — các chính sách áp dụng cho ứng dụng được tích hợp Intune SDK (như Outlook, Teams, Edge, Word). Dữ liệu công ty được bảo vệ riêng biệt khỏi dữ liệu cá nhân ngay trong cùng một thiết bị.

MDM vs MAM – So sánh chi tiết

Tiêu chí MDM (Mobile Device Management) MAM (Mobile App Management) MDM + MAM
Phạm vi kiểm soátToàn bộ thiết bịChỉ ứng dụng được quản lýCả thiết bị lẫn ứng dụng
Enrollment thiết bịBắt buộcKhông cầnBắt buộc
Phù hợp vớiCorporate-owned devicesBYOD / Personal devicesCorporate BYOD kết hợp
Wipe dữ liệuFull wipe (xóa toàn thiết bị)Selective wipe (chỉ data công ty)Cả hai
Policy áp dụngDevice Compliance, Config ProfilesApp Protection PoliciesCả hai
Quyền riêng tưThấp (IT thấy thiết bị)Cao (IT chỉ quản lý app)Trung bình
Ví dụ platformiOS, Android, Windows enrollediOS, Android chưa enrollediOS enrolled + APP

App Protection Policies – Cấu trúc 3 tầng

Tầng Tên Mức bảo vệ Ví dụ cài đặt
Level 1Basic EnterpriseTối thiểuPIN khi mở app, encrypt data, disable backup
Level 2Enhanced EnterpriseTiêu chuẩnMin OS version, jailbreak detection, block screenshot
Level 3High EnterpriseCao nhấtAdvanced PIN complexity, disable Copy/Paste, require MTD

MAM-WE (MAM Without Enrollment)

MAM-WE là tình huống khi App Protection Policy được áp dụng cho thiết bị chưa enrolled vào Intune. Đây là kịch bản BYOD phổ biến nhất:

  • Nhân viên đăng nhập Outlook/Teams bằng tài khoản công ty trên điện thoại cá nhân
  • APP tự động áp dụng: yêu cầu PIN, cấm copy data ra app cá nhân, encrypt
  • Nếu nhân viên nghỉ việc: Selective Wipe — chỉ xóa dữ liệu công ty, giữ nguyên cá nhân

Các cài đặt quan trọng trong App Protection Policy

Nhóm cài đặtTùy chọn tiêu biểuMục đích
Data TransferBlock "Save As" to personal, Restrict Cut/Copy/PasteNgăn data rò rỉ ra app cá nhân
Access RequirementsRequire PIN / Biometric, Min Android/iOS versionXác thực trước khi mở app
Conditional LaunchMax PIN attempts, Offline grace period, Jailbreak detectionPhát hiện và phản ứng với nguy cơ
EncryptionEncrypt org dataBảo vệ data khi lưu trữ
NotificationsBlock Org data in notificationsẨn nội dung email/Teams trong notification bar
Lưu ý: App Protection Policy chỉ áp dụng được cho ứng dụng đã tích hợp Intune SDK hoặc được wrap bằng Intune App Wrapping Tool. Các app của Microsoft (Outlook, Teams, Edge, Word, Excel…) đều hỗ trợ sẵn. App bên thứ ba cần kiểm tra danh sách tại Intune Partner Center.

02 · Thực hành

Lab A: Tạo App Protection Policy cho iOS – Intune Portal

Thực hành tại: Intune admin center → Apps → App protection policies

  1. Vào intune.microsoft.comAppsApp protection policies
  2. Nhấn Create policy → chọn iOS/iPadOS
  3. Name: APP-iOS-BYOD-Level2, Description: Enterprise enhanced protection for BYOD
  4. Tab Apps: chọn Target policy to = "All Microsoft apps" (bao gồm Outlook, Teams, Edge, Word)
  5. Tab Data protection:
    • Backup org data to iTunes/iCloud backup: Block
    • Send org data to other apps: Policy managed apps only
    • Receive data from other apps: Policy managed apps only
    • Restrict cut, copy, paste: Policy managed apps with paste in
    • Screen capture and Google Assistant: Block
  6. Tab Access requirements:
    • PIN for access: Require → PIN type: Passcode
    • Simple PIN: Block
    • Select minimum PIN length: 6
  7. Tab Conditional launch:
    • Max PIN attempts: 5 → Action: Reset PIN
    • Offline grace period: 720 minutes
    • Jailbroken/rooted devices: Block access
    • Min OS version: 16.0 → Action: Block access
  8. Tab Assignments: Assign to group GRP-BYOD-Users
  9. Review + Create → Create

Lab B: Tạo App Protection Policy bằng Graph PowerShell

# Cài module nếu chưa có Install-Module Microsoft.Graph -Scope CurrentUser # Kết nối với quyền DeviceManagementApps Connect-MgGraph -Scopes "DeviceManagementApps.ReadWrite.All" # Tạo App Protection Policy cho Android $body = @{ "@odata.type" = "#microsoft.graph.androidManagedAppProtection" displayName = "APP-Android-BYOD-Level2" description = "Enterprise enhanced protection for Android BYOD" periodOfflineBeforeWipeIsEnforced = "P90D" periodOfflineBeforeAccessCheck = "PT12H" pinRequired = $true maximumPinRetries = 5 simplePinBlocked = $true minimumPinLength = 6 pinCharacterSet = "numeric" periodBeforePinReset = "PT0S" allowedDataStorageLocations = @() contactSyncBlocked = $false printBlocked = $true fingerprintBlocked = $false disableAppPinIfDevicePinIsSet = $false apps = @( @{ "@odata.type" = "#microsoft.graph.managedMobileApp" mobileAppIdentifier = @{ "@odata.type" = "#microsoft.graph.androidMobileAppIdentifier" packageId = "com.microsoft.launcher.enterprise" } } ) } | ConvertTo-Json -Depth 10 Invoke-MgGraphRequest -Method POST ` -Uri "https://graph.microsoft.com/v1.0/deviceAppManagement/androidManagedAppProtections" ` -Body $body ` -ContentType "application/json"

Lab C: Kiểm tra trạng thái App Protection – Monitoring

# Xem danh sách tất cả App Protection Policies $policies = Invoke-MgGraphRequest -Method GET ` -Uri "https://graph.microsoft.com/v1.0/deviceAppManagement/iosManagedAppProtections" $policies.value | Select-Object displayName, createdDateTime, lastModifiedDateTime # Xem user checkin status với APP $userId = (Get-MgUser -UserId "[email protected]").Id Invoke-MgGraphRequest -Method GET ` -Uri "https://graph.microsoft.com/v1.0/users/$userId/managedAppRegistrations"
displayName createdDateTime lastModifiedDateTime ------------------------------ ---------------------- ---------------------- APP-iOS-BYOD-Level2 2024-01-15T08:00:00Z 2024-03-10T14:22:31Z APP-iOS-Corporate-Level3 2024-02-01T09:00:00Z 2024-03-10T14:22:31Z # managedAppRegistrations: id : abc123-def456-... appIdentifier : com.microsoft.office.outlook platformVersion : 17.2.1 registrationDateTime : 2024-03-15T07:45:00Z lastSyncDateTime : 2024-03-15T14:30:00Z isEncrypted : True deviceModel : iPhone 14 Pro deviceOperatingSystem : iOS

Lab D: Thực hiện Selective Wipe

Thực hành tại: Intune admin center → Apps → App protection policies → Wipe requests

# Selective Wipe qua PowerShell – xóa data công ty khỏi app trên thiết bị người dùng $userId = (Get-MgUser -UserId "[email protected]").Id # Lấy danh sách thiết bị registered của user $registrations = Invoke-MgGraphRequest -Method GET ` -Uri "https://graph.microsoft.com/v1.0/users/$userId/managedAppRegistrations" # Gửi wipe request cho từng registration foreach ($reg in $registrations.value) { $body = @{ "@odata.type" = "#microsoft.graph.managedAppRegistration" } | ConvertTo-Json Invoke-MgGraphRequest -Method POST ` -Uri "https://graph.microsoft.com/v1.0/users/$userId/wipeManagedAppRegistrationsByDeviceTag" ` -Body (@{ deviceTag = $reg.deviceTag } | ConvertTo-Json) ` -ContentType "application/json" Write-Host "Wipe sent for device: $($reg.deviceModel)" -ForegroundColor Yellow }
Wipe sent for device: iPhone 14 Pro Wipe sent for device: iPad Air 5th # Kết quả sau khi wipe (trên thiết bị người dùng): # - Outlook: xóa toàn bộ email, calendar, contacts công ty # - Teams: xóa chat, files công ty # - OneDrive: xóa cache file công ty # - Ứng dụng cá nhân, photos, contacts cá nhân: KHÔNG bị ảnh hưởng

03 · Tình huống thực tế

Công ty TNHH SaiGon Logistics – BYOD cho đội sale 200 người

SaiGon Logistics có 200 nhân viên bán hàng sử dụng điện thoại cá nhân (iOS/Android) để đọc email, họp Teams và xem báo cáo Excel. Giám đốc IT lo ngại: khi nhân viên nghỉ việc hoặc mất điện thoại, dữ liệu hợp đồng khách hàng có thể bị lộ.

Giải pháp triển khai:

  • Tạo App Protection Policy Level 2 cho iOS và Android, áp dụng cho nhóm GRP-Sale-BYOD
  • Cấu hình: PIN 6 chữ số, block copy sang app cá nhân, block screenshot, encrypt data
  • Conditional Launch: block nếu jailbreak/root, offline >12h yêu cầu đăng nhập lại
  • Khi nhân viên nghỉ việc: HR thông báo IT → IT thực hiện Selective Wipe trong 30 phút
  • Không cần enroll thiết bị → không vi phạm quyền riêng tư của nhân viên

Kết quả:

  • • 0 sự cố rò rỉ data sau 1 năm triển khai
  • • 12 ca Selective Wipe thành công khi nhân viên nghỉ việc
  • • Nhân viên hài lòng vì điện thoại cá nhân không bị "quản lý"
  • • IT tiết kiệm chi phí: không cần mua thiết bị corporate cho đội sale