Skip to main content

設定受管理的自動化的自訂應用

CertCentral 受管理的自動化支援最熱門的特有網頁伺服器應用。

CertCentral 也允許透過「自訂應用程式」選項設定第三方 ACME 用戶端,為延伸原始未支援的其他應用程式的憑證管理提供了靈活性。

若要啟用自訂應用程式的受管理的自動化,請遵照這些步驟:

Custom automations require an active DigiCert agent on the server. The agent:

  • Coordinates each automation request sent through Trust Lifecycle Manager, including details about the requested certificate type and properties.

  • Invokes your custom shell script on the server to complete the request and install the certificate for your application.

For detailed instructions about how to install and activate DigiCert agents on your servers, see Deploy and manage agents.

Important

To add and assign custom scripts, each agent must be running software version 3.1.2 or above.

In addition to a DigiCert agent, the server must have the Certbot ACME client installed.

Your custom shell script invokes Certbot to complete each request and install the resulting certificate for your custom Linux or Windows application.

For detailed instructions about how to download and install the Certbot client, refer to the official Certbot instructions.

You need a shell script to help manage the certificates for your custom application.

The shell script contains the Certbot command to request and install certificates for your application via the Trust Lifecycle Manager ACME service. Below are example shell scripts for Linux and Windows.

Example scripts

Usage notes

Variable definitions at the top of these shell scripts set the required ACME request parameters:

  • These must match up with the ACME arguments you configure for the custom application in Trust Lifecycle Manager (see below).

  • During an automation event, values for these arguments are supplied to the shell script by the local DigiCert agent.

Commands used in the shell script:

  • Must include all mandatory parameters.

  • Must not exceed 512 characters.

  • Must not include special directives like rm -rf or rmdir

The shell script filename:

  • Must end with .sh or .bat.

  • Must not exceed 255 characters.

To add a custom automation script in Trust Lifecycle Manager:

  1. In the Trust Lifecycle Manager menu, go to Discovery & automation tools > Scripts > DigiCert agents.

  2. Open the Add script for dropdown on the top-right, and select DigiCert agents.

  3. Complete the Add new script sidebar:

    • Name: Enter a user-friendly name for referencing the script.

    • Operating system: Select the applicable operating system (Linux or Windows).

    • Script type: Select Custom automation.

    • Upload script: Drag and drop or browse to select the script to upload. Once uploaded, the name of the script appears below the widget.

    • Description: (Optional) Enter an optional description for the script to help identify it in Trust Lifecycle Manager.

    • Command-line arguments: Enter a space-separated list of general ACME parameters to use with your custom automation script.

      例如:

      {acmeDirectoryUrl} {hosts} {email} {key} {extActKid} {extActHmac}

      請注意:

      • 每個引數的輸入必須完全如此處所示。

      • 引數的順序必須和您的殼層指令集中的使用方式相符。

      • 在自動化事件期間,這些引數需要的值自動從選取的自動化設定檔中取得。

      CertCentral 受管理的自動化支援的 ACME 引數說明:

      • {acmeDirectoryUrl} – ACME directory URL 設定。

      • {hosts} – 憑證主機詳細資料。

      • {email} – 通知的電郵地址。

      • {key} – 金鑰演算法 (RSA 或 ECC)。

      • {extActKid} – URL 中使用的外部帳戶金鑰識別碼。

      • {extActHmac} – 用於簽署回應的 HMAC 金鑰。

  4. Select Add and verify script to verify the script in Trust Lifecycle Manager. Once verified, the script is available for assignment.

Note

For more information about how to add and manage agent scripts in Trust Lifecycle Manager, see Agent scripts.

To complete the custom automation configuration, assign the script to any DigiCert agents that will manage certificates for the custom application:

  1. From the Trust Lifecycle Manager menu, go to Discovery & automation tools > Agents.

  2. Select the agent by name to view the details for it.

  3. On the details page, select the pencil icon on the right to edit the agent configuration.

  4. In the IP/port targets section for the agent, locate any IP/port targets where the custom application is running and configure them as follows:

    • Application: Select Custom.

    • Custom automation script: Select the custom automation script by the name assigned to it in Trust Lifecycle Manager.

  5. Select the Update button at the bottom to save your changes.

What's next

After enabling managed automation for your custom application, you can manage certificate deployments for it as you would any other server application in Trust Lifecycle Manager.

When you need a new certificate for your custom application:

  1. You submit the request through the Trust Lifecycle Manager web console or REST API.

  2. The DigiCert agent on the local system processes the certificate request and invokes your custom shell script with the required parameters.

  3. Your custom shell script invokes the Certbot ACME client to complete the request and install the new certificate for your application.