Skip to content

Commit

Permalink
Periodically Loading Config; Improved Javascript
Browse files Browse the repository at this point in the history
  • Loading branch information
41Baloo committed Mar 6, 2023
1 parent 26e53f4 commit f5e9b83
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion core/server/middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ func Middleware(writer http.ResponseWriter, request *http.Request) {
return
case 2:
writer.Header().Set("Content-Type", "text/html")
fmt.Fprintf(writer, `<script>document.cookie = '_2__bProxy_v=%s; SameSite=Lax; path=/; Secure';window.location.reload();</script>`, encryptedIP)
fmt.Fprintf(writer, `<script>let hasMemApi=!1,useMem=!1,hasKnownMem=!1,startMem=null,plugCh=!1,mimeCh=!1;function calcSolution(e){let i=0;for(var t=Math.pow(e,7);t>=0;t--)i+=Math.atan(t)*Math.tan(t);return!0}if(void 0!=performance.memory){if(hasMemApi=!0,startMem=performance.memory,161e5==performance.memory.totalJSHeapSize||127e5==performance.memory.usedJSHeapSize||1e7==performance.memory.usedJSHeapSize||219e4==performance.memory.jsHeapSizeLimit)for(hasKnownMem=!0;calcSolution(performance.memory.usedJSHeapSize);)0>performance.now()&&(hasKnownMem=!1);else calcSolution(8)}if(hasMemApi){let e=performance.memory;if(startMem.usedJSHeapSize==e.usedJSHeapSize&&startMem.jsHeapSizeLimit==e.jsHeapSizeLimit&&startMem.totalJSHeapSize==e.totalJSHeapSize)for(useMem=!0;calcSolution(performance.memory.usedJSHeapSize);)0>performance.now()&&(hasKnownMem=!1)}let pluginString=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(navigator),"plugins").get.toString();"function get plugins() { [native code] }"!=pluginString&&"function plugins() {\n [native code]\n }"!=pluginString&&"function plugins() {\n [native code]\n}"!=pluginString&&(plugCh=!0);let mimeString=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(navigator),"plugins").get.toString();"function get plugins() { [native code] }"!=mimeString&&"function plugins() {\n [native code]\n }"!=mimeString&&"function plugins() {\n [native code]\n}"!=mimeString&&(mimeCh=!0),mimeCh||plugCh||useMem||hasKnownMem||(document.cookie="_2__bProxy_v=%s; SameSite=Lax; path=/; Secure",window.location.reload());</script>`, encryptedIP)
return
case 3:
secretPart := encryptedIP[:6]
Expand Down
1 change: 1 addition & 0 deletions core/server/monitor.go
Original file line number Diff line number Diff line change
Expand Up @@ -507,6 +507,7 @@ func clearOutdatedCache() {
}
return true
})
reloadConfig()
time.Sleep(5 * time.Hour)
}
}
Expand Down

0 comments on commit f5e9b83

Please sign in to comment.