Jump to content
×
×
  • Create New...
  • Welcome to Pages!

    To get started, make sure you are logged in and click the arrow on the left hand side Block Manager to expand the block manager.
    You can move, add and edit blocks without the need for complex coding!

  • How to stop IPv6 in cloudflare?


    To stop IPv6 on your site, you must have ssh access on your server to run the command.

    Step 1: Create an API Key

     

    Before you can use the Cloudflare API, you need to grant yourself an API Key. This can be done on your API Tokens User Profile page. https://dash.cloudflare.com/profile/api-tokens

     

    Press the ‘Create Token’ button, and select ‘Create Custom Token’.

     

    Create a new token with ‘Edit’ access to ‘Zone Settings’. You can also restrict this key to a specific zone.

     

    tokenvar3.png

     

    When you have done this, click Continue to summary. Then test your key with this command in ssh. You will see this;

     

    ?thumbnail=small

     

    Code
    1. curl -X GET "https://api.cloudflare.com/client/v4/user/tokens/verify" \
    2. -H "Authorization: Bearer ikAYMHm-OPrOeVjQcAjNbv6co9eqsD9dWvJYnLm7" \
    3. -H "Content-Type:application/json"

     

    You will then see this result in your ssh terminal, which means that your key is working correctly.

     

    ?thumbnail=small

     

    Then go to your API key page again ( https://dash.cloudflare.com/profile/api-tokens ) and found this;

     

    ?thumbnail=small

     

    Click on "View" to see your global API key.

     

    After clicking, you will see your global key, which you should use in the next last step.

     

    Then go to cloudflare, select your domain and = > Network = > IPv6 Compatibility = > click on API

     

    ?thumbnail=small

     

    You need to run this last command on your ssh to disable IPv6.

     

    Code
    1. curl -X PATCH "https://api.cloudflare.com/client/v4/zones/your-key-in-network/settings/ipv6" \
    2. -H "X-Auth-Email: [email protected]" \
    3. -H "X-Auth-Key: 6543a6c02449958f1d557231cc037bef2f382" \
    4. -H "Content-Type: application/json" \
    5. --data '{"value":"off"}'

     

    Explain;

     

    1.

    replace with your previous picture from Network link.

     

    2. [email protected] - replace with your login email, of course.

    3. replace 6543a6c02449958f1d557231cc037bef2f382 with your key in API in (look first image), then you need to run this command;

     

    If you have done everything correctly and follow the instructions, your IPv6 will be stopped.


    User Feedback

    Recommended Comments

    There are no comments to display.


Important Information

Terms of Use