Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

PHP cURL IP - V4 vs V6 per account

Discussion in 'General Discussion' started by rinkleton, Mar 29, 2018.

Tags:
  1. rinkleton

    rinkleton Well-Known Member

    Joined:
    Jul 16, 2015
    Messages:
    93
    Likes Received:
    3
    Trophy Points:
    8
    Location:
    Cleveland
    cPanel Access Level:
    Root Administrator
    Is it possible to force each account to use it's specified IP and IP version for cURL requests?

    For example, I have an account which is not enabled for IPv6 and it is set to use the global IPv4 address. However if you do a curl to a google service, and that server supports IPv6, the request will be made through the server's global IPv6 address. This results in authentication errors.

    Using
    CURLOPT_IPRESOLVE => CURL_IPRESOLVE_V4
    is a good work around, but it seems like each account should use it's set IP. In the future, if I want to enable IPv6 for that account, I will have to go through the code to update it, rather than just changing a setting in WHM.
     
  2. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,803
    Likes Received:
    1,898
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice