From 697aec2821ab1f9ffff9b78d5e8fcd82f6eb3578 Mon Sep 17 00:00:00 2001 From: Alexandre Dulaunoy Date: Tue, 4 Jan 2022 15:45:01 +0100 Subject: [PATCH] fix: [stackpath] now a txt file is included on the stackpath --- tools/generate-stackpath.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tools/generate-stackpath.py b/tools/generate-stackpath.py index 2403ad9..cef6acf 100755 --- a/tools/generate-stackpath.py +++ b/tools/generate-stackpath.py @@ -92,15 +92,16 @@ def process(files, dst): if __name__ == '__main__': - sp_base_url = "https://support.stackpath.com/hc/en-us/articles/360001091666-Whitelist-CDN-WAF-IP-Blocks" + # Base url where a text file is attached https://support.stackpath.com/hc/en-us/articles/360001091666-Whitelist-CDN-WAF-IP-Blocks" + sp_base_url = "https://support.stackpath.com/hc/en-us/article_attachments/360096407372/ipblocks.txt" filename = 'ipblocks.txt' sp_dst = 'stackpath' to_process = list() - url = get_file_link(sp_base_url, filename) + #url = get_file_link(sp_base_url, filename) file = 'stackpath_{}'.format(filename) - download_to_file(url, file) + download_to_file(sp_base_url, file) to_process.append(file) process(to_process, sp_dst)