Hi there,
I'm struggling with my local installation of DokuWiki because it sticks in my craw that I can't use Extension Manager.
Yes, I know I've already talked about this issue but today I've got some good news and I want to share them with you.
There is still some little problem that I can't solve by myself because I haven't got enough competence.
1) My scenario.
XAMPP for Linux 64bit which includes:
- Use PHP version for the XAMPP version
- Updated PHP to 5.6.3
- Updated MySQL to 5.6.21
- Updated phpMyAdmin 4.2.11
- Update OpenSSL to 1.0.1j
Linux packages already installed:
-
libcurl3 7.35.0-1ubuntu2.3
-
libssl1.0.0 1.0.1f-1ubuntu2.8
-
php5-curl 5.5.9+dfsg-1ubuntu4.6
-
php5-cli 5.5.9+dfsg-1ubuntu4.6
-
openssl 1.0.1f-1ubuntu2.8
-
ssl-cert 1.0.33
2) Which is my problem in this configuration?
I can't download any plug-ins from the tab "Search and Install" in the Extension Manager. Every time I recive the error:
*
"The plugin repository could not be contacted. make sure your server is allowed to contact www.dokuwiki.org and check your proxy settings".
3) Looking for the causes.
According to:
http://docs.php.net/manual/en/migration56.openssl.php#migration56.openssl.default-certificate-paths
executing a .php file with the code:
<?php
var_dump(openssl_get_cert_locations());
?>
I get the following output:
array(8) {
["default_cert_file"]=> string(33) "/opt/lampp/share/openssl/cert.pem"
["default_cert_file_env"]=> string(13) "SSL_CERT_FILE"
["default_cert_dir"]=> string(30) "/opt/lampp/share/openssl/certs"
["default_cert_dir_env"]=> string(12) "SSL_CERT_DIR"
["default_private_dir"]=> string(32) "/opt/lampp/share/openssl/private"
["default_default_cert_area"]=> string(24) "/opt/lampp/share/openssl"
["ini_cafile"]=> string(0) ""
["ini_capath"]=> string(14) ""
}
But:
* in
/opt/lampp/share/openssl[/m] there isn't any file called [m]cert.pem
* in
/opt/lampp/share/openssl/certs[/m] there is only an empty file called [m]NOTEMPTY
* in
/opt/lampp/share/openssl/private[/m] there is only an empty file called [m]NOTEMPTY
So PHP is looking for CA bundles in empty locations.
4) Trying to solve the causes.
From:
http://curl.haxx.se/docs/caextract.html
I downloaded the file:
cacert.pem
To find where to put this certificate I used the command (see
man openssl[/m] and [m]man version):
openssl version -d
In my case it returned:
/usr/lib/ssl/
which is a symlink to:
/etc/ssl/
So I put
cacert.pem[/m] in [m]/etc/ssl/certs.
Then, in my
/opt/lampp/etc/php.ini I added the two lines (see
http://docs.php.net/manual/en/context.ssl.php#context.ssl.cafile):
openssl.cafile=/etc/ssl/certs/cacert.pem
openssl.capath=/etc/ssl/certs
Saved the file. Restarted Apche.
Now I can instal plugin from Extension Manager!
5) There is still some bother.
Unfortunately, sometimes, DokuWiki gives me the messages (at the same time):
*
"Plugin XYZ installed successfully"
*
"The plugin repository could not be contacted. Make sure your server is allowed to contact www.dokuwiki.org and check your proxy settings"
although it has been actually installed.
Is it a really problem? If so, whose problem is it? Is it a DokuWiki's bug or I forget some set up?
Thank you!