# ddgth/cf2dns

筛选出优质的Cloudflare IP，并使用域名服务商提供的API解析到不同线路以达到网站加速的效果,新增假墙防御方式

Repository: https://github.com/ddgth/cf2dns
Canonical: https://ross.abutalabs.com/products/cf2dns
Language: Python
License Family: other
Last push: 2025-01-06T06:16:13+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 2195, "days_push": 604, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 5201, forks 1915 (observed 2026-08-28T04:09:12.127523+00:00)

## What it is
A Python tool that selects high-quality Cloudflare IPs and updates DNS records via DNS provider APIs (DNSPod, Aliyun DNS, Huawei Cloud DNS) to route different lines for website acceleration. It supports IPv4/IPv6, Docker and GitHub Actions deployment, and includes protection against fake GFW wall attacks.

## Use cases
- optimize Cloudflare CDN IPs for my website
- automatically update DNS A records with best Cloudflare IPs
- speed up a site hosted behind Cloudflare in China
- set up scheduled Cloudflare IP selection with cron
- protect my site from fake wall (假墙) attacks
- run Cloudflare IP optimization via GitHub Actions or Docker

## When to choose
- you use Cloudflare as CDN with DNSPod or Aliyun DNS and want automatic line-based IP optimization
- you need scheduled updates of优选 Cloudflare IPs for IPv4 or IPv6
- you want a small self-hosted script deployable via cron, Docker, or GitHub Actions

## When to avoid
- you don't use Cloudflare or a supported DNS provider (DNSPod, Aliyun, Huawei Cloud)
- you need a fully open-source IP selection algorithm - the IP filtering itself is a closed API
- you are uncomfortable with the risk of Cloudflare account bans for IP selection usage

## Facets
- artifact type: cli-tool
- maturity: active
- function: networking, workflow-automation, scheduling
- domain: networking, web-development, self-hosted, censorship-circumvention
- platform: python, cli
- tags: cloudflare, dns-management, cdn-optimization, ip-selection, dnspod, aliyun-dns, github-actions, ipv6, linux, docker

## Member repositories
- ddgth/cf2dns (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:09:12.127523+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:00:15.094518+00:00, confidence not recorded.
  - readme: https://github.com/ddgth/cf2dns (fetched 2026-08-28T04:09:12.127523+00:00, sha c658eefad9dd)
- Data as of 2026-08-30T08:39:29.467469+00:00.
