OwO-Network / DeepLX

Powerful Free DeepL API, No Token Required
https://ssa.sx/deeplx
MIT License
6.64k stars 532 forks source link

同时使用ipv4和ipv6 #131

Closed zhengqwe closed 3 months ago

zhengqwe commented 3 months ago

如果系统有ipv6地址的话(一般有两个),就同时用v4和v6一共3个地址,防止429

missuo commented 3 months ago

The official API of DeepL does not support IPv6.

zhengqwe commented 3 months ago

虽然DeepL的API地址的dns解析没有v6地址,但是如果用Hosts文件指定一个v6地址也能正常使用(api用的是cloudflare cdn,在绝大多数情况下它的ip是能任意互换的,随便找个有v6地址、且用cloudflare cdn的网站的v6地址就行)

missuo commented 3 months ago

Have you tested this? Are you sure you are testing in an environment that has no IPv4 network at all?

zhengqwe commented 3 months ago

Have you tested this?

可用,这段时间一直这样用的

Are you sure you are testing in an environment that has no IPv4 network at all?

我那里同时有v4和v6地址,抓包发现软件只用v6地址,根本不用v4地址,我的想法是把v4和v6都用上来均衡负载

missuo commented 2 months ago

After my test, I cannot access the DeepL API using IPv6.

zhengqwe commented 2 months ago

After my test, I cannot access the DeepL API using IPv6.

Is it using an ip like 2606:4700:22::6815:19d? This is a project about Cloudflare ip preference, and the author's side of this project is that v4 ip is almost unavailable, only v6 can be used. Reference this