Tutorial Tutorial Application Services Application Services ~45 phút ~45 min Đồng bộ 2026-06-10 Synced 2026-06-10

Azure Managed HSM Azure Managed HSM

Hướng dẫn chi tiết đồng bộ từ docs Cloudflare — mỗi section có backlink tới đúng vị trí trên trang gốc. Detailed guide synced from Cloudflare docs — each section links to the matching anchor on the official page.

← Danh mục ← Catalog

Giải thích nhanh Quick context

Thuộc nhóm Application Services — tập trung bảo vệ, tăng tốc và vận hành ứng dụng/web phía trước origin. Tutorial «Azure Managed HSM» giúp bạn làm quen luồng triển khai thật — phù hợp đọc trước khi mở tài liệu gốc tiếng Anh. Docs gốc chia khoảng 5 bước chính; bản tóm tắt dưới đây giúp bạn nắm khung trước khi làm theo từng lệnh.

This tutorial uses Microsoft Azure's Managed HSM to deploy a VM with the Keyless SSL daemon. Follow these instructions to deploy your keyless server.

Lưu ý trước khi làm Notes before you start

  • Đây là bản tóm tắt trên Orange Cloud Learning Hub — không thay thế tài liệu chính thức.
  • Luôn mở liên kết «Tài liệu gốc» bên dưới khi cần lệnh CLI, snippet code và ảnh minh họa đầy đủ.
  • Yêu cầu trước (từ docs): Followed Microsoft's tutorial ↗ for provisioning and activating the managed HSM · Set up a VM for your key server
  • Docs Cloudflare cập nhật thường xuyên — đối chiếu ngày «Rà soát lần cuối» trên trang gốc khi triển khai production.

Tổng quan Overview

Phần «Tổng quan» — đọc hướng dẫn bên dưới, dùng liên kết docs gốc để xem ảnh minh họa và tab cấu hình đầy đủ.

Mở section docs gốc ↗ Open source section ↗

This tutorial uses Microsoft Azure’s Managed HSM ↗ — a FIPS 140-2 Level 3 certified implementation — to deploy a VM with the Keyless SSL daemon.

---

Trước khi bắt đầu Before you start

Phần «Trước khi bắt đầu» — đọc hướng dẫn bên dưới, dùng liên kết docs gốc để xem ảnh minh họa và tab cấu hình đầy đủ.

Mở section docs gốc ↗ Open source section ↗

Make sure you have:

  • Followed Microsoft's tutorial ↗ for provisioning and activating the managed HSM
  • Set up a VM for your key server

---

1. Tạo VM 1. Create a VM

Tạo VM where you will deploy the keyless daemon.

Mở section docs gốc ↗ Open source section ↗

Create a VM where you will deploy the keyless daemon.

---

2. Triển khai keyless server 2. Deploy the keyless server

Phần «Triển khai keyless server» — đọc hướng dẫn bên dưới, dùng liên kết docs gốc để xem ảnh minh họa và tab cấu hình đầy đủ.

Mở section docs gốc ↗ Open source section ↗

Follow these instructions to deploy your keyless server.

---

Liên kết liên quan (docs Cloudflare) Related links (Cloudflare docs)

3. Thiết lập Azure CLI 3. Set up the Azure CLI

Phần «Thiết lập Azure CLI» — đọc hướng dẫn bên dưới, dùng liên kết docs gốc để xem ảnh minh họa và tab cấu hình đầy đủ.

Mở section docs gốc ↗ Open source section ↗

Set up the Azure CLI (used to access the private key).

For example, if you were using macOS:

Terminal window

text
brew install azure-cli

---

4. Thiết lập Managed HSM 4. Set up the Managed HSM

Phần «Thiết lập Managed HSM» — đọc hướng dẫn bên dưới, dùng liên kết docs gốc để xem ảnh minh họa và tab cấu hình đầy đủ.

Mở section docs gốc ↗ Open source section ↗
  1. Log in through the Azure CLI and create a resource group for the Managed HSM in one of the supported regions:

Terminal window

text
az login  
az group create --name HSMgroup --location southcentralus

Note For a list of supported regions, see the Microsoft documentation ↗.

  1. Create, provision, and activate ↗ the HSM.
  2. Add your private key to the keyvault, which returns the URI you need for Step 4:
text
az keyvault key import --hsm-name "KeylessHSM" --name "hsm-pub-keyless" --pem-file server.key
  1. If the key server is running in an Azure VM in the same account, use Managed services for authorization:

1. Enable managed services on the VM in the UI. 2. Give your service user (associated with your VM) HSM sign permissions `` az keyvault role assignment create --hsm-name KeylessHSM --assignee $(az vm identity show --name "hsmtestvm" --resource-group "HSMgroup" --query principalId -o tsv) --scope / --role "Managed HSM Crypto User" ``

  1. In the gokeyless YAML file, add the URI from Step 2 under privatekeystores. See our README ↗ for an example.

5. Restart gokeyless 5. Restart gokeyless

Phần «Restart gokeyless» — đọc hướng dẫn bên dưới, dùng liên kết docs gốc để xem ảnh minh họa và tab cấu hình đầy đủ.

Mở section docs gốc ↗ Open source section ↗

Once you save the config file, restart gokeyless and verify that it started successfully:

Terminal window

text
sudo systemctl restart gokeyless.service

sudo systemctl status gokeyless.service -l
json
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"item":{"@id":"/directory/","name":"Directory"}},{"@type":"ListItem","position":2,"item":{"@id":"/ssl/","name":"SSL/TLS"}},{"@type":"ListItem","position":3,"item":{"@id":"/ssl/keyless-ssl/","name":"Keyless SSL"}},{"@type":"ListItem","position":4,"item":{"@id":"/ssl/keyless-ssl/hardware-security-modules/","name":"Hardware security modules"}},{"@type":"ListItem","position":5,"item":{"@id":"/ssl/keyless-ssl/hardware-security-modules/azure-managed-hsm/","name":"Azure Managed HSM"}}]}

Xem bản đầy đủ trên developers.cloudflare.com (ảnh, tab cấu hình). View the full guide on developers.cloudflare.com (images, config tabs).

Tài liệu gốc ↗ Official docs ↗