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!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

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:
    81
    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 Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    42,734
    Likes Received:
    1,706
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page