- 积分
- 330
- 明经币
- 个
- 注册时间
- 2022-11-6
- 在线时间
- 小时
- 威望
-
- 金钱
- 个
- 贡献
-
- 激情
-
|
发表于 2024-3-10 19:23:49
|
显示全部楼层
- import requests
- def test_links(start_url, end_url):
- valid_links = []
- for i in range(int(start_url, 16), int(end_url, 16) + 1):
- hex_value = f"{i:032X}"
- url = f"https://up.autodesk.com/2019/ACD/{hex_value[:8]}-{hex_value[8:12]}-{hex_value[12:16]}-{hex_value[16:20]}-{hex_value[20:]}/AutoCAD_2019.1.4_Update_32bit.exe"
- response = requests.head(url)
- print(f"Testing {url}: {response.status_code}")
- if response.status_code != 404:
- valid_links.append(url)
- break # Stop after finding the first valid link
- return valid_links
- start_hex_value = "00000000000000000000000000000000"
- end_hex_value = "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF"
- valid_links = test_links(start_hex_value, end_hex_value)
- # Write the first valid link to result.txt
- if valid_links:
- with open("result.txt", "w") as result_file:
- result_file.write(valid_links[0])
- print(
- f"First valid link written to result.txt: {valid_links[0] if valid_links else 'No valid links found'}"
- )
复制代码
有没有人来跑一跑,暴力穷举找到链接 |
|