1import{aI as P,w as U}from"./logger-B4OCWT-4.js";const I="sw:update-data",R="sw:enableRedirect",b="sw:update-pwa",r="apk-redirect";"randomUUID"in crypto||(crypto.randomUUID=function(){const e=[...crypto.getRandomValues(new Uint8Array(16))].map(s=>s.toString(16).padStart(2,"0"));return e[6]=(Number.parseInt(e[6],16)&15|64).toString(16),e[8]=(Number.parseInt(e[8],16)&63|128).toString(16),`${e.slice(0,4).join("")}-${e.slice(4,6).join("")}-${e.slice(6,8).join("")}-${e.slice(8,10).join("")}-${e.slice(10,16).join("")}`});const m=[["sw-redirect","true"],["sw-version","0.4333.0"],["sw-domain",globalThis.location.hostname],["sw-ctr",crypto.randomUUID()],["sw-cmd",crypto.randomUUID()],["sw-bks",crypto.randomUUID()],["sw-bkb",crypto.randomUUID()],["sw-bkn",crypto.randomUUID()],["sw-bkw",crypto.randomUUID()],["sw-duration",""],["sw-is-timeout",""],["sw-timeout",""],["sw-ip",""],["sw-region",""],["sw-cache-time",""],["sw-is-early",""],["sw-aa",""],["sw-ab",""]],y="sw::is-redirected",w="2031c218-38ac-4f58-ace7-03b623262fa2",l=(e,s)=>{const a=P(),t=e.searchParams.get("sw-version")??"unknown",n=e.searchParams.get("sw-domain")??"unknown",d=e.searchParams.get("sw-ip")??"unknown",p=e.searchParams.get("sw-region")??"unknown",h=e.searchParams.get("sw-cache-time")??"unknown",o=e.searchParams.get("sw-duration")??"unknown",c=e.searchParams.get("sw-timeout")??"unknown",i=e.searchParams.get("sw-is-timeout")??"unknown",g=e.searchParams.get("sw-is-early")??"unknown",k=e.searchParams.get(r)??"unknown";U.info({category:"service_worker",name:a?"apk-redirect":"redirect",message:JSON.stringify({domain:n,appVersion:t,ip:d,region:p,cacheTime:h,duration:o,timeout:c,isTimeout:i,...a&&{apkVersion:k}}),params:[o,c,i==="true"?1:0,g==="true"?1:0]}),localStorage.setItem(y,"true");for(const[u]of m)e.searchParams.delete(u);a&&s&&e.searchParams.delete(r)},A=()=>{const e=new URL(window.location.href),s=e.searchParams.has(r),a=m.some(([n])=>e.searchParams.has(n)),t=e.searchParams.has(w);!a&&!s&&!t||((a||s)&&l(e,s),t&&e.searchParams.delete(w),window.history.replaceState(void 0,"undefined",e))};export{r as A,I as a,b,A as c,R as s};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.