Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Situation Awareness
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ Web Application Firewall/ User Guide/ Website Settings/ Managing Websites/ Updating the Certificate Used for a Website

Updating the Certificate Used for a Website

Updated on 2025-01-17 GMT+08:00

If you select Cloud Mode - CNAME or Dedicated Mode as the access mode and set Client Protocol to HTTPS, a certificate is required for your website.

  • If your website certificate is about to expire, purchase a new certificate before the expiration date and update the certificate associated with the website in WAF.

    WAF can send notifications if a certificate expires. You can configure such notifications on the Notifications page. For details, see Enabling Alarm Notifications.

  • If you plan to update the certificate associated with the website, associate a new certificate with your website on the WAF console.
NOTE:

If you have enabled enterprise projects, ensure that you have all operation permissions for the project where your WAF instance locates. Then, you can select the enterprise project from the Enterprise Project drop-down list and update certificates.

Prerequisites

You have added the website to WAF and selected HTTPS for Client Protocol.

Constraints

  • Each domain name must have a certificate associated. A wildcard domain name can only use a wildcard domain certificate. If you only have single-domain certificates, add domain names one by one in WAF.
  • Only .pem certificates can be used in WAF. If the certificate is not in .pem, before uploading it, convert it to .pem by referring to 6.
  • Only accounts with the SCM Administrator and SCM FullAccess permissions can select SCM certificates.
  • Before updating the certificate, ensure that your WAF instance and the certificate you want to upload belong to the same account.

Impact on the System

  • It is recommended that you update the certificate before it expires. Otherwise, all WAF protection rules will fail to take effect, and there can be massive impacts on the origin server, even more severe than a crashed host or website access failures.
  • Updating certificates does not affect services. The old certificate still works during the certificate replacement. The new certificate will take over the job once it has been uploaded and successfully associated with the domain name.
  • Access to your website may be affected when you update the configurations of certificates used for backend servers or for domain names of your websites protected by WAF. To minimize these impacts, update the certificates during off-peak hours.

Updating the Certificate Used for a Website

  1. Log in to the management console.
  2. Click in the upper left corner of the management console and select a region or project.
  3. Click in the upper left corner and choose Web Application Firewall under Security & Compliance.
  4. In the navigation pane on the left, choose Website Settings.
  5. In the Domain Name column, click the domain name of the website to go to the basic information page.
  6. Click Modify next to the certificate name. In the Update Certificate dialog box, import a new certificate or select an existing certificate.

    • If you select Import new certificate for Update Method, enter a certificate name, and copy and paste the certificate file and private key into the corresponding text boxes.

      The newly imported certificates will be listed on the Certificates page. For more details, see Uploading a Certificate to WAF.

      NOTE:

      WAF encrypts and saves the private key to keep it safe.

      Only .pem certificates can be used in WAF. If the certificate is not in .pem format, convert it into .pem locally by referring to Table 1 before uploading it.
      Table 1 Certificate conversion commands

      Format

      Conversion Method

      CER/CRT

      Rename the cert.crt certificate file to cert.pem.

      PFX

      • Obtain a private key. For example, run the following command to convert cert.pfx into key.pem:

        openssl pkcs12 -in cert.pfx -nocerts -out key.pem -nodes

      • Obtain a certificate. For example, run the following command to convert cert.pfx into cert.pem:

        openssl pkcs12 -in cert.pfx -nokeys -out cert.pem

      P7B

      1. Convert a certificate. For example, run the following command to convert cert.p7b into cert.cer:

        openssl pkcs7 -print_certs -in cert.p7b -out cert.cer

      2. Rename certificate file cert.cer to cert.pem.

      DER

      • Obtain a private key. For example, run the following command to convert privatekey.der into privatekey.pem:

        openssl rsa -inform DER -outform PEM -in privatekey.der -out privatekey.pem

      • Obtain a certificate. For example, run the following command to convert cert.cer into cert.pem:

        openssl x509 -inform der -in cert.cer -out cert.pem

      NOTE:
      • Before running an OpenSSL command, ensure that the OpenSSL tool has been installed on the local host.
      • If your local PC runs a Windows operating system, go to the command line interface (CLI) and then run the certificate conversion command.
    • If you select Select existing certificate for Update Method, select an existing certificate from the Certificate drop-down list.
      NOTE:

      If there are no certificates available, click Purchase Certificate and purchase a certificate and push it to WAF.

    • If you select SCM certificate for Update Method, select a certificate managed in CCM. It can be a certificate you purchased through CCM or an external certificate you uploaded to CCM.
      CAUTION:

      The SCM certificate domain name must be the same as the one you added to WAF.

  7. Click OK.

Related Operations

Uploading a Certificate to WAF

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback