• Resolved mezzomedia

    (@mezzomedia)


    Dear Wordfence team,

    Following up on the similar topic I started, which was closed without a reply:

    After the website updated to the latest version of Wordfence (7.11.4) last night, I am now getting WordPress cron errors mentioning the same PHP error:
    Call to undefined function WordfenceLS\fsockopen()

    Caused by /wp-content/plugins/wordfence/modules/login-security/classes/controller/time.php in WordfenceLS\Controller_Time::ntp_time at line 106.

    Line 106:
    $socket = @fsockopen('udp://' . $s, 123, $err_no, $err_str, 1);

    In my previous topic I addressed that fsockopen() is disabled but cURL functions are enabled for the website, and I asked if this could be a (lack of using) namespace issue.

    Could you please give this another look?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter mezzomedia

    (@mezzomedia)

    In addition, this same error is now created by Wordfence on the same website on the production server. This was not the case before updating to the latest Wordfence version.

    I have double checked to see that fsockopen() is also disabled on this server, and curl_version() does work.

    Plugin Support wfpeter

    (@wfpeter)

    Hi @mezzomedia,

    Topics are closed for replies automatically after a certain amount of time rather than by us, but it’s fine to reference an older topic in a new one to discuss it further. As topics don’t rise back to the top, an update after 5 months is unfortunately likely to be missed, which I apologize for, but I’m happy to help you out as much as I can now.

    I’ve re-checked and we use fsockopen() as the primary way to sync time using NTP, which can’t use cURL unfortunately. We’ve seen hosts block UDP but not often cases of fsockopen() being disabled.

    We haven’t changed anything around NTP in the latest version. I think that it can become disabled automatically if it fails often enough, so it’s likely deactivating/activating the plugin could cause it to be checked again until it fails a few times. I think that’s possibly what has happened in your case.

    You should be able to disable the NTP checks by clicking the “Disable” button on the Login Security > Settings page under “NTP”.

    Thanks,
    Peter.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Call to undefined function WordfenceLS\fsockopen() (Wordfence 7.11.4)’ is closed to new replies.