Securing the connection between Enterprise Server and WordPress can be achieved by running WordPress on HTTPS.
Step 1. This step is optional, only perform it when the following is not true:
- Enterprise Server and WordPress run on the same machine and SSL is set up for Enterprise Server
- You are happy to reuse the same certificate for WordPress
Repeat the steps from Using SSL in Enterprise Server but now for the WordPress server.
Note: You can choose whether or not to generate the cacert.pem file but if you do, and there is already one installed or used on <web_root>/Enterprise/config/encryptkeys/cacert.pem, you should not overwrite this file. Instead, create another file (for instance cacert_wordpress.pem).
Tip: You can configure WordPress on the same machine but on a different port (such as '1234'), thereby enabling you to specify a different certificate than used for Enterprise Server.
Step 2. Configure the Enterprise Server plug-in as follows:
Step 2a. Open the following file:
- <your Enterprise Server installation>/config/plugins/WordPress/config.php
Tip: Easily manage and configure settings of all configuration files by adding them to a single configuration file.
Step 2b. Locate the 'WordPress_SITES' section:
define( 'WordPress_SITES', serialize( array(
'label_of_the_first_instance' => array( // site label, as shown on the "Publication Channel Maintenance" page
'url' => '', // specify the full URL to your WordPress instance, including a trailing slash
'username' => '', // enter a valid WordPress user for the instance here
'password'=> '', // enter the password belonging to the specified username
'certificate' => '{Wordpress_certificate}', // Optional, required for HTTPS (SSL) connections only. The full file path of the local CA certificate file (in PEM format).
)
)));
Step 2c. Configure the WordPress site to publish to by entering the following details:
- Label. A representative name for the WordPress site.
Note: This name will appear on the Publication Channel Maintenance page as an option in the 'Web Site' list.
- url. The HTTPS location of the WordPress site.
Note: This needs to end with a forward slash '/'.
- username. The user name of the user who is assigned as the administrator
- password. The password for the user.
- certificate. (Optional, required for HTTPS (SSL) connections only. Requires Enterprise Server 10.0.3 or higher, or Enterprise Server 10.1.1 or higher.) The full file path of the local CA certificate file (in PEM format).
Example. In this example, 2 sites are configured:
|
Step 2d. Save and close the file.
Step 3. Run the Publish to WordPress test on the Heath Check page. Fix any errors where necessary.
Troubleshooting: Publish error from WordPress
When the certificate does not match, the following type of error is shown:
WordPress - Publish error from WordPress: Error in cURL request: SSL certificate problem, verify that the CA cert is OK. Details: error:1407E086:SSL routines:SSL2_SET_CERTIFICATE:certificate verify failed.
Fix this by checking the path to the WordPress certificate file that is configured for the "Certificate" option on the Publication Channel Maintenance page.
Comment
Do you have corrections or additional information about this article? Leave a comment! Do you have a question about what is described in this article? Please contact Support.
0 comments
Please sign in to leave a comment.