Skip to content

如何查看某个域名使用的是哪个cdn

如何查看某个域名使用的是哪个cdn ?

回答

要查看某个域名使用的是哪个 CDN(内容分发网络),可以通过以下方法进行检测和分析:


1. 使用 nslookupdig 查询 DNS 记录

方法:检查 CNAME 记录

CDN 通常会为域名分配一个 CNAME 记录(如 xxx.cloudfront.netxxx.cdn20.com 等)。
操作步骤:

bash
nslookup 目标域名
# 或
dig 目标域名 CNAME

示例输出(如果使用 CDN):

目标域名.cdn.cloudflare.net
  • 如果返回的域名包含 cdncloudfrontakamai 等关键词,大概率是 CDN 提供商。

bash
[root@wiki ~]# nslookup onedayxyy.cn
Server:         10.23.255.1
Address:        10.23.255.1#53

Non-authoritative answer:
onedayxyy.cn    canonical name = onedayxyy.cn.s2-web.dogedns.com.
onedayxyy.cn.s2-web.dogedns.com canonical name = onedayxyy.cn.cdn.dnsv1.com.cn.
onedayxyy.cn.cdn.dnsv1.com.cn   canonical name = k25xhrip.sched.vodtylego.tdnsvod1.cn.
Name:   k25xhrip.sched.vodtylego.tdnsvod1.cn
Address: 116.207.185.29
Name:   k25xhrip.sched.vodtylego.tdnsvod1.cn
Address: 116.207.184.169
Name:   k25xhrip.sched.vodtylego.tdnsvod1.cn
Address: 116.207.184.226
Name:   k25xhrip.sched.vodtylego.tdnsvod1.cn
Address: 116.207.185.32
Name:   k25xhrip.sched.vodtylego.tdnsvod1.cn
Address: 116.207.184.230
Name:   k25xhrip.sched.vodtylego.tdnsvod1.cn
Address: 116.207.185.134

2. 查看 HTTP 响应头

CDN 通常会在 HTTP 响应头中添加 ServerX-CacheCDN 标识头
操作步骤:

bash
curl -I https://目标域名

关键字段:

  • Server: cloudflareECS(阿里云)、Apache(可能隐藏 CDN)。
  • X-Cache: HIT/MISS(表示内容是否从 CDN 缓存返回)。
  • X-CDN: 可能直接标明 CDN 提供商(如 X-CDN: Akamai)。

示例输出:

Server: cloudflare
CF-RAY: 58a01b12dac3d0e6-LAX

bash
[root@wiki ~]# curl -I https://onedayxyy.cn
HTTP/1.1 200 OK
Last-Modified: Mon, 09 Jun 2025 22:47:17 GMT
Etag: "68476475-eb2a"
Server: nginx/1.26.1
Date: Mon, 09 Jun 2025 23:10:09 GMT
Content-Type: text/html
Strict-Transport-Security: max-age=31536000
Content-Length: 60202
Accept-Ranges: bytes
X-NWS-LOG-UUID: 10778161133321592430
Connection: keep-alive
X-Cache-Lookup: Cache Hit

3. 使用在线 CDN 检测工具

以下工具可自动分析域名是否使用 CDN 及提供商:

使用方法:
输入域名,工具会显示 CDN 提供商(如 Cloudflare、Akamai、阿里云等)。


4. 检查 IP 归属

CDN 的 IP 通常属于知名云服务商或 CDN 公司。
操作步骤:

bash
ping 目标域名  # 获取域名解析的 IP
whois <IP地>  # 查询 IP 归属

常见 CDN IP 段:

  • Cloudflare: 104.16.0.0/12
  • Akamai: 23.32.0.0/11
  • 阿里云 CDN: 47.246.0.0/16
  • 腾讯云 CDN: 119.28.0.0/16

bash
[root@wiki ~]# ping onedayxyy.cn
PING k25xhrip.sched.vodtylego.tdnsvod1.cn (119.147.131.120) 56(84) bytes of data.
64 bytes from 119.147.131.120 (119.147.131.120): icmp_seq=1 ttl=45 time=29.3 ms
64 bytes from 119.147.131.120 (119.147.131.120): icmp_seq=2 ttl=45 time=29.2 ms
^C
--- k25xhrip.sched.vodtylego.tdnsvod1.cn ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 29.212/29.304/29.396/0.092 ms
[root@wiki ~]# whois 119.147.131.120
% [whois.apnic.net]
% Whois data copyright terms    http://www.apnic.net/db/dbcopyright.html

% Information related to '119.144.0.0 - 119.147.255.255'

% Abuse contact for '119.144.0.0 - 119.147.255.255' is 'anti-spam@chinatelecom.cn'

inetnum:        119.144.0.0 - 119.147.255.255
netname:        CHINANET-GD
descr:          CHINANET Guangdong province network
descr:          Data Communication Division
descr:          China Telecom
country:        CN
admin-c:        CH93-AP
tech-c:         IC83-AP
abuse-c:        AC1573-AP
status:         ALLOCATED PORTABLE
remarks:        service provider
remarks:        --------------------------------------------------------
remarks:        To report network abuse, please contact mnt-irt
remarks:        For troubleshooting, please contact tech-c and admin-c
remarks:        Report invalid contact via www.apnic.net/invalidcontact
remarks:        --------------------------------------------------------
mnt-by:         APNIC-HM
mnt-lower:      MAINT-CHINANET-GD
mnt-routes:     MAINT-CHINANET-GD
mnt-irt:        IRT-CHINANET-CN
last-modified:  2021-06-15T08:05:44Z
source:         APNIC

irt:            IRT-CHINANET-CN
address:        No.31 ,jingrong street,beijing
address:        100032
e-mail:         anti-spam@chinatelecom.cn
abuse-mailbox:  anti-spam@chinatelecom.cn
admin-c:        CH93-AP
tech-c:         CH93-AP
auth:           # Filtered
remarks:        anti-spam@chinatelecom.cn was validated on 2025-04-24
mnt-by:         MAINT-CHINANET
last-modified:  2025-04-24T03:21:26Z
source:         APNIC

role:           ABUSE CHINANETCN
country:        ZZ
address:        No.31 ,jingrong street,beijing
address:        100032
phone:          +000000000
e-mail:         anti-spam@chinatelecom.cn
admin-c:        CH93-AP
tech-c:         CH93-AP
nic-hdl:        AC1573-AP
remarks:        Generated from irt object IRT-CHINANET-CN
remarks:        anti-spam@chinatelecom.cn was validated on 2025-04-24
abuse-mailbox:  anti-spam@chinatelecom.cn
mnt-by:         APNIC-ABUSE
last-modified:  2025-04-24T03:21:54Z
source:         APNIC

person:         Chinanet Hostmaster
nic-hdl:        CH93-AP
e-mail:         anti-spam@chinatelecom.cn
address:        No.31 ,jingrong street,beijing
address:        100032
phone:          +86-10-58501724
fax-no:         +86-10-58501724
country:        CN
mnt-by:         MAINT-CHINANET
last-modified:  2022-02-28T06:53:44Z
source:         APNIC

person:         IPMASTER CHINANET-GD
nic-hdl:        IC83-AP
e-mail:         abuse_gdicnoc@163.com
address:        NO.18,RO. ZHONGSHANER,YUEXIU DISTRIC,GUANGZHOU
phone:          +86-20-87189274
fax-no:         +86-20-87189274
country:        CN
mnt-by:         MAINT-CHINANET-GD
remarks:        IPMASTER is not for spam complaint,please send spam complaint to abuse_gdicnoc@163.com
abuse-mailbox:  abuse_gdicnoc@163.com
last-modified:  2021-05-12T09:06:58Z
source:         APNIC

% This query was served by the APNIC Whois Service version 1.88.34 (WHOIS-AU4)


[root@wiki ~]#

5. 查看 SSL/TLS 证书

部分 CDN 会使用共享证书,证书的颁发者可能包含 CDN 信息。
操作步骤:

bash
openssl s_client -connect 目标域名:443 -servername 目标域名 | openssl x509 -noout -issuer

示例输出:

issuer= /C=US/O=Cloudflare, Inc./CN=Cloudflare Inc ECC CA-3

bash
[root@wiki ~]# openssl s_client -connect onedayxyy.cn:443 -servername onedayxyy.cn | openssl x509 -noout -issuer
depth=2 C = US, O = Internet Security Research Group, CN = ISRG Root X1
verify return:1
depth=1 C = US, O = Let's Encrypt, CN = E5
verify return:1
depth=0 CN = onedayxyy.cn
verify return:1
issuer= /C=US/O=Let's Encrypt/CN=E5
read:errno=0
[root@wiki ~]#

6. 分析网络路径(Traceroute)

通过追踪路由,观察中间节点是否属于 CDN 提供商。
操作步骤:

bash
traceroute 目标域名  # Linux
tracert 目标域名    # Windows
  • 如果中间跳转节点包含 akamai.comcloudflare.com 等,则说明使用了对应 CDN。
bash
[root@wiki ~]# traceroute onedayxyy.cn
traceroute to onedayxyy.cn (119.147.131.120), 30 hops max, 60 byte packets
 1  * * *
 2  10.80.16.19 (10.80.16.19)  0.490 ms  0.449 ms  0.465 ms
 3  * * *
 4  10.80.16.19 (10.80.16.19)  1.509 ms  1.495 ms  1.482 ms
 5  10.80.16.3 (10.80.16.3)  2.567 ms  2.554 ms  2.542 ms
 6  * 10.80.8.160 (10.80.8.160)  3.542 ms *
 7  * * *
 8  10.80.73.65 (10.80.73.65)  2.933 ms  3.158 ms 10.80.9.17 (10.80.9.17)  3.039 ms
 9  10.78.38.6 (10.78.38.6)  4.810 ms 10.78.38.16 (10.78.38.16)  4.749 ms 10.78.38.14 (10.78.38.14)  4.486 ms
10  * * *
11  101.95.247.53 (101.95.247.53)  5.670 ms 101.95.247.61 (101.95.247.61)  5.674 ms 101.95.247.49 (101.95.247.49)  6.837 ms
12  * 101.95.224.45 (101.95.224.45)  6.164 ms 101.95.224.41 (101.95.224.41)  5.245 ms
13  202.97.19.130 (202.97.19.130)  24.910 ms 202.97.29.150 (202.97.29.150)  30.089 ms *
14  113.96.254.114 (113.96.254.114)  33.240 ms 94.210.128.219.broad.st.gd.dynamic.163data.com.cn (219.128.210.94)  32.329 ms 113.96.254.42 (113.96.254.42)  30.310 ms
15  14.152.84.174 (14.152.84.174)  30.328 ms  27.922 ms  30.297 ms
16  183.6.231.222 (183.6.231.222)  28.431 ms  28.225 ms  29.693 ms
17  * * *
18  * * *
19  * * *
20  * * *
21  * * *
22  * * *
23  * * *
24  * * *
25  * * *
26  * * *
27  * * *
28  * * *
29  * * *
30  * * *
[root@wiki ~]#

常见 CDN 提供商标识

CDN 名称关键标识
Cloudflarecloudflare.comCF-RAY
Akamaiakamai.netX-Akamai-*
阿里云 CDNaliyuncs.comX-Cache: TCP_HIT
腾讯云 CDNcdntip.comX-Cache-Lookup

总结

  1. 优先检查 DNS CNAME 记录(如 dig)。
  2. 查看 HTTP 头(如 curl -I)。
  3. 使用在线工具快速识别(如 WhatCDN)。
  4. 综合 IP、证书、路由信息进一步验证。

如果域名隐藏了 CDN(如自建 CDN 或反向代理),可能需要结合多种方法分析。

结论

好像没查出个所以然来着……。。。

2025年6月10日

从当前效果看,是配置多吉云 cdn成功了:

image-20250610072522113

image-20250610072533905

最近更新