WordPress.org

Ready to get started?Download WordPress

Forums

WP-Piwik
[resolved] Problems reaching an SSL installation of Piwiki (12 posts)

  1. Olivier
    Member
    Posted 3 years ago #

    I typed in the secure URL version of my Piwik installation and here is what I found in the logs.
    PHP Warning: file_get_contents() [function.file-get-contents]: SSL: connection timeout in /public_html/wp-content/plugins/wp-piwik/wp-piwik.php on line 213
    PHP Warning: file_get_contents() [function.file-get-contents]: Failed to enable crypto in /public_html/wp-content/plugins/wp-piwik/wp-piwik.php on line 213

    http://wordpress.org/extend/plugins/wp-piwik/

  2. braekling
    Member
    Plugin Author

    Posted 3 years ago #

    This seems to be a problem with your OpenSSL and/or PHP module. Are any other PHP applications able to connect to a secured server?

  3. Olivier
    Member
    Posted 3 years ago #

    You're right, I tried with a custom script and I couldn't connect. I'll let you know if I find something relevant to this case.

  4. Olivier
    Member
    Posted 3 years ago #

    Seems like it's a PHP/OpenSSL bug
    http://bugs.php.net/bug.php?id=52106

  5. braekling
    Member
    Plugin Author

    Posted 3 years ago #

    Thank you! I'm sorry I can't help you, but I will add this to the plugins documentation. Hopefully this would be fixed soon.

  6. Olivier
    Member
    Posted 3 years ago #

    :)
    The alternative would be to use fsockopen or curl.

  7. Olivier
    Member
    Posted 3 years ago #

    Hmmmm...Only curl would work...

  8. braekling
    Member
    Plugin Author

    Posted 3 years ago #

    Oh, that's fine. Because curl is already implemented, but just used if 'allow_url_fopen' is disabled. So I can set curl to default and use fopen only if curl isn't available.

    Quickhack:

    search:
    function get_remote_file($strURL)

    remove:
    if (ini_get('allow_url_fopen'))
    $strResult = file_get_contents($strURL);
    else

    it will look like this:
    function get_remote_file($strURL) {
    if (function_exists('curl_init')) {
    $c = curl_init($strURL);
    [...]

    There will be a patch soon.

  9. Olivier
    Member
    Posted 3 years ago #

    Thank you!

  10. nv1962
    Member
    Posted 3 years ago #

    Yep, resolved for me too: I have WP3.0.4 running its wp-admin backend over SSL and WP-Piwik works like a charm! (In some cases, also having WordPress HTTPS installed helps to resolve the last odd mixed content bits)

  11. gormer
    Member
    Posted 3 years ago #

    I got this problem today. After upgrading to latest version it stopped working on two sites. I changed the key to a user key on one site and it started to work again, but a SSL site I can't get it to work at all. I only get an error when I try to enter the user/pass.

    I see that the above patch is still installed. I don't have time to look into this before next week, but I just post a note here in case someone else are experiencing problems.

  12. Olivier
    Member
    Posted 3 years ago #

    I've just checked and it's still working for me

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags