Skip to main content

Manage Service SSL Certificates via Command Line

Comments

7 comments

  • cPanelMichael
    Hello :) Yes, you can utilize WHM API 1 to install a service SSL certificate via the command line: WHM API 1 Functions - install_service_ssl_certificate - Software Development Kit - cPanel Documentation Thank you.
    0
  • Loth
    Hello :) Yes, you can utilize WHM API 1 to install a service SSL certificate via the command line:
    0
  • cPanelMichael
    root@localhost [~]# whmapi1 accountsummary user=root Undefined subroutine &Encode::define_alias called at /usr/local/cpanel/3rdparty/perl/514/lib64/perl5/cpanel_lib/XML/SAX/PurePerl/UnicodeExt.pm line 15.

    Which version of cPanel is installed on this system? Also, are you able to reproduce the issue with a valid username (root is not a cPanel account). Thank you.
    0
  • Loth
    Which version of cPanel is installed on this system? Also, are you able to reproduce the issue with a valid username (root is not a cPanel account). Thank you.

    Hello, It seems it works with root after its updated and running, however I am getting an error with my certificate. What format does it need to be input as? root@cpanel-test [~]# whmapi1 install_service_ssl_certificate service=ftp crt="-----BEGIN CERTIFICATE-----\n MIIFZzCCBE+g...." metadata: command: install_service_ssl_certificate reason: "Invalid certificate passed to verifysslcert (missing BEGIN CERTIFICATE)\n" result: 0 version: 1 Secondly, can multiple services be input or only one at a time?
    0
  • cPanelMichael
    Please install the certificate on one service at a time. There's actually a script on the following thread you can utilize: [How-To] Installing SSL from Let's Encrypt Note that it's for a different purpose, but the installation script should work after you modify it for a service SSL installation. Thank you.
    0
  • azadhussnain
    hello i want to install ssl on a domain via command file how can i do
    0
  • Fabricio Galdino
    Hello! Maybe this can help you: --help Example of use:
    /usr/local/cpanel/bin/autossl_check --all
    This will create SSL to your domains.
    0

Please sign in to leave a comment.