You can obtain the initial password for logging in to a Windows ECS through the management console or APIs. For details, see this section.
You have obtained the private key file (.pem file) which was generated during the ECS creation.
in the upper left corner and select a region and project.Call the password obtaining APIs to obtain the ciphertext password of the public key encrypted using RSA.
The API URI is in the following format: GET /v1/{project_id}/cloudservers/{server_id}/os-server-password.
For details, see "Obtaining the Password for Logging In to an ECS" in the Elastic Cloud Server API Reference.
Use the private key file used when you created the ECS to decrypt the ciphertext password obtained in step 4.
openssl pkcs8 -topk8 -inform PEM -outform DER -in rsa_pem.key -out pkcs8_der.key -nocrypt