From c4acfdb8aba067599cf50941f861a213af186aef Mon Sep 17 00:00:00 2001 From: theajack <1506282385@qq.com> Date: Sat, 1 Oct 2022 01:40:16 +0800 Subject: [PATCH] feat: ignore bundle --- .gitignore | 4 +- scripts/dev/bundle.js | 812 -------------------------------------- scripts/dev/bundle.js.map | 7 - 3 files changed, 3 insertions(+), 820 deletions(-) delete mode 100644 scripts/dev/bundle.js delete mode 100644 scripts/dev/bundle.js.map diff --git a/.gitignore b/.gitignore index 3cb5443..3b29d10 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,6 @@ node_modules /dist .pnpm-debug.log /npm -/docs \ No newline at end of file +/docs +bundle.js +bundle.js.map \ No newline at end of file diff --git a/scripts/dev/bundle.js b/scripts/dev/bundle.js deleted file mode 100644 index a3d4d14..0000000 --- a/scripts/dev/bundle.js +++ /dev/null @@ -1,812 +0,0 @@ -// src/utils/open-state.ts -var isLastStateOpenedBool = false; -var OpenState = {}; -function markDevToolOpenState(type) { - OpenState[type] = true; -} -function clearDevToolOpenState(type) { - OpenState[type] = false; -} -function isDevToolOpened() { - for (const key in OpenState) { - if (OpenState[key]) { - isLastStateOpenedBool = true; - return true; - } - } - isLastStateOpenedBool = false; - return false; -} -function checkOnDevClose() { - if (typeof config.ondevtoolclose === "function") { - const isLastOpen = isLastStateOpenedBool; - if (!isDevToolOpened() && isLastOpen) { - config.ondevtoolclose(); - } - } -} - -// src/utils/util.ts -function now() { - return new Date().getTime(); -} -function calculateTime(func) { - const start = now(); - func(); - return now() - start; -} -function getUrlParam(name) { - let { search } = window.location; - const { hash } = window.location; - if (search === "" && hash !== "") { - search = `?${hash.split("?")[1]}`; - } - if (search !== "" && search !== void 0) { - const reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i"); - const r = search.substr(1).match(reg); - if (r != null) { - return unescape(r[2]); - } - } - return ""; -} -function formatName(name) { - if (name.indexOf("-") === -1) { - return name; - } - let flag = false; - return name.split("").map((c) => { - if (c === "-") { - flag = true; - return ""; - } - if (flag) { - flag = false; - return c.toUpperCase(); - } - return c; - }).join(""); -} -function onPageShowHide(onshow, onhide) { - const doc = document; - let hidden, state, visibilityChange; - if (typeof doc.hidden !== "undefined") { - hidden = "hidden"; - visibilityChange = "visibilitychange"; - state = "visibilityState"; - } else if (typeof doc.mozHidden !== "undefined") { - hidden = "mozHidden"; - visibilityChange = "mozvisibilitychange"; - state = "mozVisibilityState"; - } else if (typeof doc.msHidden !== "undefined") { - hidden = "msHidden"; - visibilityChange = "msvisibilitychange"; - state = "msVisibilityState"; - } else if (typeof doc.webkitHidden !== "undefined") { - hidden = "webkitHidden"; - visibilityChange = "webkitvisibilitychange"; - state = "webkitVisibilityState"; - } - const cb = function() { - if (doc[state] === hidden) { - onhide(); - } else { - onshow(); - } - }; - doc.removeEventListener(visibilityChange, cb, false); - doc.addEventListener(visibilityChange, cb, false); -} -function hackAlert(before, after) { - const _alert = window.alert; - const _confirm = window.confirm; - const _prompt = window.prompt; - const mod = (fn) => { - return (...args) => { - if (before) { - before(); - } - const result = fn(...args); - if (after) { - after(); - } - return result; - }; - }; - try { - window.alert = mod(_alert); - window.confirm = mod(_confirm); - window.prompt = mod(_prompt); - } catch (e) { - } -} -function hasUaName(name) { - return navigator.userAgent.toLocaleLowerCase().indexOf(name) !== -1; -} -var isInIframe = (() => { - try { - return window.self !== window.top; - } catch (e) { - return true; - } -})(); -var isPC = !/(iphone|ipad|ipod|ios|android)/i.test(navigator.userAgent.toLowerCase()); -var isQQBrowser = hasUaName("qqbrowser"); -var isFirefox = hasUaName("firefox"); -var isMacOs = hasUaName("macintosh"); -var isEdge = hasUaName("edge"); -var isOldEdge = isEdge && !hasUaName("chrome"); -var isIE = isOldEdge || hasUaName("trident") || hasUaName("msie"); -var isIOSChrome = hasUaName("crios"); -var isIOSEdge = hasUaName("edgios"); -var isChrome = hasUaName("chrome") || isIOSChrome; -function createLargeObject() { - const largeObject = {}; - for (let i = 0; i < 500; i++) { - largeObject[`${i}`] = `${i}`; - } - return largeObject; -} -function createLargeObjectArray() { - const largeObject = createLargeObject(); - const largeObjectArray = []; - for (let i = 0; i < 50; i++) { - largeObjectArray.push(largeObject); - } - return largeObjectArray; -} - -// src/utils/interval.ts -var interval = 0; -var timer = 0; -var calls = []; -var time = 0; -function initInterval() { - let _pause = false; - const pause = () => { - _pause = true; - }; - const goon = () => { - _pause = false; - }; - hackAlert(pause, goon); - onPageShowHide(goon, pause); - interval = window.setInterval(() => { - if (_pause) - return; - calls.forEach((detector) => { - clearDevToolOpenState(detector.type); - detector.detect(time++); - }); - clearLog(); - checkOnDevClose(); - }, config.interval); - timer = setTimeout(() => { - if (!isPC) { - clearDDInterval(); - } - }, config.stopIntervalTime); -} -function registInterval(detector) { - calls.push(detector); -} -function clearDDInterval() { - window.clearInterval(interval); -} -function clearDDTimeout() { - window.clearTimeout(timer); -} - -// src/utils/close-window.ts -function closeWindow() { - clearDDInterval(); - if (config.url) { - window.location.href = config.url; - } else { - try { - window.opener = null; - window.open("", "_self"); - window.close(); - window.history.back(); - } catch (e) { - console.log(e); - } - setTimeout(() => { - window.location.href = `https://tackchen.gitee.io/404.html?h=${encodeURIComponent(location.host)}`; - }, 500); - } -} - -// src/utils/config.ts -var config = { - md5: "", - ondevtoolopen: closeWindow, - ondevtoolclose: null, - url: "", - tkName: "ddtk", - interval: 200, - disableMenu: true, - stopIntervalTime: 5e3, - clearIntervalWhenDevOpenTrigger: false, - detectors: "all", - clearLog: true, - disableSelect: false, - disableCopy: false, - disableCut: false, - disablePaste: false -}; -var MultiTypeKeys = ["detectors", "ondevtoolclose"]; -function mergeConfig(opts = {}) { - for (const key in config) { - const k = key; - if (typeof opts[k] !== "undefined" && (typeof config[k] === typeof opts[k] || MultiTypeKeys.indexOf(k) !== -1)) { - config[k] = opts[k]; - } - } - checkConfig(); -} -function checkConfig() { - if (typeof config.ondevtoolclose === "function" && config.clearIntervalWhenDevOpenTrigger === true) { - config.clearIntervalWhenDevOpenTrigger = false; - console.warn("\u3010DISABLE-DEVTOOL\u3011clearIntervalWhenDevOpenTrigger \u5728\u4F7F\u7528 ondevtoolclose \u65F6\u65E0\u6548"); - } -} - -// src/utils/log.ts -var console2 = window.console || { - log: function() { - return; - }, - table: function() { - return; - }, - clear: function() { - return; - } -}; -var log = (() => { - return isIE ? (...args) => { - return console2.log(...args); - } : console2.log; -})(); -var table = (() => { - return isIE ? (...args) => { - return console2.table(...args); - } : console2.table; -})(); -var clearLogFunc = (() => { - return isIE ? () => { - return console2.clear(); - } : console2.clear; -})(); -function clearLog() { - if (config.clearLog) - clearLogFunc(); -} - -// src/utils/key-menu.ts -function disableKeyAndMenu() { - const KEY = { J: 74, I: 73, U: 85, S: 83, F12: 123 }; - const isOpenDevToolKey = isMacOs ? (e, code) => e.metaKey && e.altKey && (code === KEY.I || code === KEY.J) : (e, code) => e.ctrlKey && e.shiftKey && (code === KEY.I || code === KEY.J); - const isViewSourceCodeKey = isMacOs ? (e, code) => e.metaKey && e.altKey && code === KEY.U || e.metaKey && code === KEY.S : (e, code) => e.ctrlKey && (code === KEY.S || code === KEY.U); - window.addEventListener("keydown", (e) => { - e = e || window.event; - const keyCode = e.keyCode || e.which; - if (keyCode === KEY.F12 || isOpenDevToolKey(e, keyCode) || isViewSourceCodeKey(e, keyCode)) { - e.returnValue = false; - e.preventDefault(); - return false; - } - }, true); - disableMenu(); - disableSelect(); - disableCopy(); - disableCut(); - disablePaste(); -} -function disableMenu() { - if (config.disableMenu) { - preventEvent(window, "contextmenu"); - } -} -function disableSelect() { - if (config.disableSelect) { - preventEvent(window, "selectstart"); - } -} -function disableCopy() { - if (config.disableCopy) { - preventEvent(window, "copy"); - } -} -function disableCut() { - if (config.disableCut) { - preventEvent(window, "cut"); - } -} -function disablePaste() { - if (config.disablePaste) { - preventEvent(window, "paste"); - } -} -function preventEvent(target, name) { - target.addEventListener(name, (e) => { - e = e || window.event; - e.returnValue = false; - e.preventDefault(); - return false; - }); -} - -// src/utils/md5.ts -var hexcase = 0; -var chrsz = 8; -function hex_md5(s) { - return binl2hex(core_md5(str2binl(s), s.length * chrsz)); -} -function core_md5(x, len) { - x[len >> 5] |= 128 << len % 32; - x[(len + 64 >>> 9 << 4) + 14] = len; - let a = 1732584193; - let b = -271733879; - let c = -1732584194; - let d = 271733878; - for (let i = 0; i < x.length; i += 16) { - const olda = a; - const oldb = b; - const oldc = c; - const oldd = d; - a = md5_ff(a, b, c, d, x[i + 0], 7, -680876936); - d = md5_ff(d, a, b, c, x[i + 1], 12, -389564586); - c = md5_ff(c, d, a, b, x[i + 2], 17, 606105819); - b = md5_ff(b, c, d, a, x[i + 3], 22, -1044525330); - a = md5_ff(a, b, c, d, x[i + 4], 7, -176418897); - d = md5_ff(d, a, b, c, x[i + 5], 12, 1200080426); - c = md5_ff(c, d, a, b, x[i + 6], 17, -1473231341); - b = md5_ff(b, c, d, a, x[i + 7], 22, -45705983); - a = md5_ff(a, b, c, d, x[i + 8], 7, 1770035416); - d = md5_ff(d, a, b, c, x[i + 9], 12, -1958414417); - c = md5_ff(c, d, a, b, x[i + 10], 17, -42063); - b = md5_ff(b, c, d, a, x[i + 11], 22, -1990404162); - a = md5_ff(a, b, c, d, x[i + 12], 7, 1804603682); - d = md5_ff(d, a, b, c, x[i + 13], 12, -40341101); - c = md5_ff(c, d, a, b, x[i + 14], 17, -1502002290); - b = md5_ff(b, c, d, a, x[i + 15], 22, 1236535329); - a = md5_gg(a, b, c, d, x[i + 1], 5, -165796510); - d = md5_gg(d, a, b, c, x[i + 6], 9, -1069501632); - c = md5_gg(c, d, a, b, x[i + 11], 14, 643717713); - b = md5_gg(b, c, d, a, x[i + 0], 20, -373897302); - a = md5_gg(a, b, c, d, x[i + 5], 5, -701558691); - d = md5_gg(d, a, b, c, x[i + 10], 9, 38016083); - c = md5_gg(c, d, a, b, x[i + 15], 14, -660478335); - b = md5_gg(b, c, d, a, x[i + 4], 20, -405537848); - a = md5_gg(a, b, c, d, x[i + 9], 5, 568446438); - d = md5_gg(d, a, b, c, x[i + 14], 9, -1019803690); - c = md5_gg(c, d, a, b, x[i + 3], 14, -187363961); - b = md5_gg(b, c, d, a, x[i + 8], 20, 1163531501); - a = md5_gg(a, b, c, d, x[i + 13], 5, -1444681467); - d = md5_gg(d, a, b, c, x[i + 2], 9, -51403784); - c = md5_gg(c, d, a, b, x[i + 7], 14, 1735328473); - b = md5_gg(b, c, d, a, x[i + 12], 20, -1926607734); - a = md5_hh(a, b, c, d, x[i + 5], 4, -378558); - d = md5_hh(d, a, b, c, x[i + 8], 11, -2022574463); - c = md5_hh(c, d, a, b, x[i + 11], 16, 1839030562); - b = md5_hh(b, c, d, a, x[i + 14], 23, -35309556); - a = md5_hh(a, b, c, d, x[i + 1], 4, -1530992060); - d = md5_hh(d, a, b, c, x[i + 4], 11, 1272893353); - c = md5_hh(c, d, a, b, x[i + 7], 16, -155497632); - b = md5_hh(b, c, d, a, x[i + 10], 23, -1094730640); - a = md5_hh(a, b, c, d, x[i + 13], 4, 681279174); - d = md5_hh(d, a, b, c, x[i + 0], 11, -358537222); - c = md5_hh(c, d, a, b, x[i + 3], 16, -722521979); - b = md5_hh(b, c, d, a, x[i + 6], 23, 76029189); - a = md5_hh(a, b, c, d, x[i + 9], 4, -640364487); - d = md5_hh(d, a, b, c, x[i + 12], 11, -421815835); - c = md5_hh(c, d, a, b, x[i + 15], 16, 530742520); - b = md5_hh(b, c, d, a, x[i + 2], 23, -995338651); - a = md5_ii(a, b, c, d, x[i + 0], 6, -198630844); - d = md5_ii(d, a, b, c, x[i + 7], 10, 1126891415); - c = md5_ii(c, d, a, b, x[i + 14], 15, -1416354905); - b = md5_ii(b, c, d, a, x[i + 5], 21, -57434055); - a = md5_ii(a, b, c, d, x[i + 12], 6, 1700485571); - d = md5_ii(d, a, b, c, x[i + 3], 10, -1894986606); - c = md5_ii(c, d, a, b, x[i + 10], 15, -1051523); - b = md5_ii(b, c, d, a, x[i + 1], 21, -2054922799); - a = md5_ii(a, b, c, d, x[i + 8], 6, 1873313359); - d = md5_ii(d, a, b, c, x[i + 15], 10, -30611744); - c = md5_ii(c, d, a, b, x[i + 6], 15, -1560198380); - b = md5_ii(b, c, d, a, x[i + 13], 21, 1309151649); - a = md5_ii(a, b, c, d, x[i + 4], 6, -145523070); - d = md5_ii(d, a, b, c, x[i + 11], 10, -1120210379); - c = md5_ii(c, d, a, b, x[i + 2], 15, 718787259); - b = md5_ii(b, c, d, a, x[i + 9], 21, -343485551); - a = safe_add(a, olda); - b = safe_add(b, oldb); - c = safe_add(c, oldc); - d = safe_add(d, oldd); - } - return Array(a, b, c, d); -} -function md5_cmn(q, a, b, x, s, t) { - return safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b); -} -function md5_ff(a, b, c, d, x, s, t) { - return md5_cmn(b & c | ~b & d, a, b, x, s, t); -} -function md5_gg(a, b, c, d, x, s, t) { - return md5_cmn(b & d | c & ~d, a, b, x, s, t); -} -function md5_hh(a, b, c, d, x, s, t) { - return md5_cmn(b ^ c ^ d, a, b, x, s, t); -} -function md5_ii(a, b, c, d, x, s, t) { - return md5_cmn(c ^ (b | ~d), a, b, x, s, t); -} -function safe_add(x, y) { - const lsw = (x & 65535) + (y & 65535); - const msw = (x >> 16) + (y >> 16) + (lsw >> 16); - return msw << 16 | lsw & 65535; -} -function bit_rol(num, cnt) { - return num << cnt | num >>> 32 - cnt; -} -function str2binl(str) { - const bin = Array(); - const mask = (1 << chrsz) - 1; - for (let i = 0; i < str.length * chrsz; i += chrsz) - bin[i >> 5] |= (str.charCodeAt(i / chrsz) & mask) << i % 32; - return bin; -} -function binl2hex(binarray) { - const hex_tab = hexcase ? "0123456789ABCDEF" : "0123456789abcdef"; - let str = ""; - for (let i = 0; i < binarray.length * 4; i++) { - str += hex_tab.charAt(binarray[i >> 2] >> i % 4 * 8 + 4 & 15) + hex_tab.charAt(binarray[i >> 2] >> i % 4 * 8 & 15); - } - return str; -} -var md5_default = hex_md5; - -// src/version.js -var version_default = "0.2.5"; - -// src/utils/enum.ts -var DetectorType = /* @__PURE__ */ ((DetectorType2) => { - DetectorType2[DetectorType2["Unknown"] = -1] = "Unknown"; - DetectorType2[DetectorType2["RegToString"] = 0] = "RegToString"; - DetectorType2[DetectorType2["DefineId"] = 1] = "DefineId"; - DetectorType2[DetectorType2["Size"] = 2] = "Size"; - DetectorType2[DetectorType2["DateToString"] = 3] = "DateToString"; - DetectorType2[DetectorType2["FuncToString"] = 4] = "FuncToString"; - DetectorType2[DetectorType2["Debugger"] = 5] = "Debugger"; - DetectorType2[DetectorType2["Performance"] = 6] = "Performance"; - return DetectorType2; -})(DetectorType || {}); - -// src/detector/detector.ts -var Detector = class { - constructor({ - type, - enabled = true - }) { - this.type = -1 /* Unknown */; - this.enabled = true; - this.type = type; - this.enabled = enabled; - if (this.enabled) { - registInterval(this); - this.init(); - } - } - onDevToolOpen() { - console.warn(`You ar not allow to use DEVTOOL! \u3010type = ${this.type}\u3011`); - if (config.clearIntervalWhenDevOpenTrigger) { - clearDDInterval(); - } - clearDDTimeout(); - config.ondevtoolopen(this.type, closeWindow); - markDevToolOpenState(this.type); - } - init() { - } -}; - -// src/detector/sub-detector/reg-to-string.ts -var reg_to_string_default = class extends Detector { - constructor() { - super({ - type: 0 /* RegToString */, - enabled: isQQBrowser || isFirefox - }); - } - init() { - this.lastTime = 0; - this.reg = /./; - log(this.reg); - this.reg.toString = () => { - if (isQQBrowser) { - const time2 = new Date().getTime(); - if (this.lastTime && time2 - this.lastTime < 100) { - this.onDevToolOpen(); - } else { - this.lastTime = time2; - } - } else if (isFirefox) { - this.onDevToolOpen(); - } - return ""; - }; - } - detect() { - log(this.reg); - } -}; - -// src/detector/sub-detector/define-id.ts -var define_id_default = class extends Detector { - constructor() { - super({ - type: 1 /* DefineId */ - }); - } - init() { - this.div = document.createElement("div"); - this.div.__defineGetter__("id", () => { - this.onDevToolOpen(); - }); - Object.defineProperty(this.div, "id", { - get: () => { - this.onDevToolOpen(); - } - }); - } - detect() { - log(this.div); - } -}; - -// src/detector/sub-detector/size.ts -var size_default = class extends Detector { - constructor() { - super({ - type: 2 /* Size */, - enabled: !isInIframe && !isEdge - }); - } - init() { - this.checkWindowSizeUneven(); - window.addEventListener("resize", () => { - setTimeout(() => { - this.checkWindowSizeUneven(); - }, 100); - }, true); - } - detect() { - } - checkWindowSizeUneven() { - const screenRatio = countScreenZoomRatio(); - if (screenRatio === false) { - return true; - } - const widthUneven = window.outerWidth - window.innerWidth * screenRatio > 200; - const heightUneven = window.outerHeight - window.innerHeight * screenRatio > 300; - if (widthUneven || heightUneven) { - this.onDevToolOpen(); - return false; - } - clearDevToolOpenState(this.type); - return true; - } -}; -function countScreenZoomRatio() { - if (checkExist(window.devicePixelRatio)) { - return window.devicePixelRatio; - } - const screen = window.screen; - if (checkExist(screen)) { - return false; - } - if (screen.deviceXDPI && screen.logicalXDPI) { - return screen.deviceXDPI / screen.logicalXDPI; - } - return false; -} -function checkExist(v) { - return typeof v !== "undefined" && v !== null; -} - -// src/detector/sub-detector/date-to-string.ts -var date_to_string_default = class extends Detector { - constructor() { - super({ - type: 3 /* DateToString */ - }); - } - init() { - this.count = 0; - this.date = new Date(); - this.date.toString = () => { - this.count++; - return ""; - }; - } - detect() { - this.count = 0; - log(this.date); - clearLog(); - if (this.count >= 2) { - this.onDevToolOpen(); - } - } -}; - -// src/detector/sub-detector/func-to-string.ts -var func_to_string_default = class extends Detector { - constructor() { - super({ - type: 4 /* FuncToString */, - enabled: !isIOSChrome && !isIOSEdge - }); - } - init() { - this.count = 0; - this.func = () => { - }; - this.func.toString = () => { - this.count++; - return ""; - }; - } - detect() { - this.count = 0; - log(this.func); - clearLog(); - if (this.count >= 2) { - this.onDevToolOpen(); - } - } -}; - -// src/detector/sub-detector/debugger.ts -var debugger_default = class extends Detector { - constructor() { - super({ - type: 5 /* Debugger */, - enabled: isIOSChrome || isIOSEdge - }); - } - detect() { - const date = now(); - (() => { - debugger; - })(); - if (now() - date > 100) { - this.onDevToolOpen(); - } - } -}; - -// src/detector/sub-detector/performance.ts -var performance_default = class extends Detector { - constructor() { - super({ - type: 6 /* Performance */, - enabled: isChrome - }); - } - init() { - this.maxPrintTime = 0; - this.largeObjectArray = createLargeObjectArray(); - } - detect() { - const tablePrintTime = calculateTime(() => { - table(this.largeObjectArray); - }); - const logPrintTime = calculateTime(() => { - log(this.largeObjectArray); - }); - this.maxPrintTime = Math.max(this.maxPrintTime, logPrintTime); - clearLog(); - if (tablePrintTime === 0 || this.maxPrintTime === 0) - return false; - if (tablePrintTime > this.maxPrintTime * 10) { - this.onDevToolOpen(); - } - } -}; - -// src/detector/index.ts -var Detectors = { - [0 /* RegToString */]: reg_to_string_default, - [1 /* DefineId */]: define_id_default, - [2 /* Size */]: size_default, - [3 /* DateToString */]: date_to_string_default, - [4 /* FuncToString */]: func_to_string_default, - [5 /* Debugger */]: debugger_default, - [6 /* Performance */]: performance_default -}; -function initDetectors() { - const typeArray = config.detectors === "all" ? Object.keys(Detectors) : config.detectors; - typeArray.forEach((type) => { - const DetectorClass = Detectors[type]; - new DetectorClass(); - }); -} - -// src/main.ts -function disableDevtool(opts) { - mergeConfig(opts); - if (checkTk()) { - return; - } - initInterval(); - disableKeyAndMenu(); - initDetectors(); -} -disableDevtool.md5 = md5_default; -disableDevtool.version = version_default; -disableDevtool.DetectorType = DetectorType; -disableDevtool.isDevToolOpened = isDevToolOpened; -function checkTk() { - if (config.md5) { - const tk = getUrlParam(config.tkName); - if (md5_default(tk) === config.md5) { - return true; - } - } - return false; -} -function checkScriptUse() { - if (typeof document === "undefined") { - return; - } - const dom = document.querySelector("[disable-devtool-auto]"); - if (!dom) { - return; - } - const json = {}; - ["md5", "url", "tk-name", "interval", "disable-menu", "detectors"].forEach((name) => { - let value = dom.getAttribute(name); - if (value !== null) { - if (name === "interval") { - value = parseInt(value); - } else if (name === "disable-menu") { - value = value === "false" ? false : true; - } else if (name === "detector") { - if (value !== "all") { - value = value.split(" "); - } - } - json[formatName(name)] = value; - } - }); - disableDevtool(json); -} -checkScriptUse(); - -// src/index.ts -var src_default = disableDevtool; - -// scripts/dev/index.ts -src_default({ - md5: "0b9e05caf5000360ec1c263335bd83fe", - ondevtoolopen: (type) => { - document.body.innerHTML = "devtool opened!; type =" + type; - }, - ondevtoolclose: () => { - document.body.innerHTML = "devtool closed!;"; - }, - clearIntervalWhenDevOpenTrigger: true, - interval: 1e3, - disableMenu: false, - clearLog: false, - disableCopy: true, - disableSelect: true, - disablePaste: true -}); -document.addEventListener("click", () => { - const div = document.createElement("div"); - div.innerText = `isOpen = ${src_default.isDevToolOpened()}`; - document.body.appendChild(div); -}); -//# sourceMappingURL=bundle.js.map diff --git a/scripts/dev/bundle.js.map b/scripts/dev/bundle.js.map deleted file mode 100644 index fcc1356..0000000 --- a/scripts/dev/bundle.js.map +++ /dev/null @@ -1,7 +0,0 @@ -{ - "version": 3, - "sources": ["../../src/utils/open-state.ts", "../../src/utils/util.ts", "../../src/utils/interval.ts", "../../src/utils/close-window.ts", "../../src/utils/config.ts", "../../src/utils/log.ts", "../../src/utils/key-menu.ts", "../../src/utils/md5.ts", "../../src/version.js", "../../src/utils/enum.ts", "../../src/detector/detector.ts", "../../src/detector/sub-detector/reg-to-string.ts", "../../src/detector/sub-detector/define-id.ts", "../../src/detector/sub-detector/size.ts", "../../src/detector/sub-detector/date-to-string.ts", "../../src/detector/sub-detector/func-to-string.ts", "../../src/detector/sub-detector/debugger.ts", "../../src/detector/sub-detector/performance.ts", "../../src/detector/index.ts", "../../src/main.ts", "../../src/index.ts", "index.ts"], - "sourcesContent": ["/*\n * @Author: tackchen\n * @Date: 2022-01-05 22:27:40\n * @LastEditors: Please set LastEditors\n * @LastEditTime: 2022-09-28 00:24:14\n * @FilePath: /disable-devtool/src/utils/open-state.js\n * @Description: Coding something\n */\n\nimport {DetectorType} from 'src/utils/enum';\nimport {config} from './config';\n\nlet isLastStateOpenedBool = false;\n\nconst OpenState: {\n [prop in DetectorType]?: boolean;\n} = {};\n\nexport function markDevToolOpenState (type: DetectorType) {\n OpenState[type] = true;\n}\n\nexport function clearDevToolOpenState (type: DetectorType) {\n OpenState[type] = false;\n}\n\nexport function isDevToolOpened () {\n for (const key in OpenState) {\n if (OpenState[key as unknown as DetectorType]) {\n isLastStateOpenedBool = true;\n return true;\n }\n }\n isLastStateOpenedBool = false;\n return false;\n}\n\nexport function checkOnDevClose () {\n if (\n typeof config.ondevtoolclose === 'function'\n ) {\n const isLastOpen = isLastStateOpenedBool; // \u7F13\u5B58\u4E00\u4E0B\u4E0A\u4E00\u6B21\u7ED3\u679C\n if (!isDevToolOpened() && isLastOpen) {\n config.ondevtoolclose();\n }\n }\n}", "\n\nexport function now () {\n return new Date().getTime();\n}\n\nexport function calculateTime (func: Function) {\n const start = now();\n func();\n return now() - start;\n}\n\nexport function getUrlParam (name: string) {\n let {search} = window.location;\n const {hash} = window.location;\n // # \u5728 ? \u4E4B\u524D\uFF0C\u5373 http://localhost/#file?key=value\uFF0C\u4F1A\u5BFC\u81F4 search \u4E3A\u7A7A\u3002\n if (search === '' && hash !== '') {\n // \u4E3A search \u8865\u4E0A\u524D\u7F00'?'\uFF0C\u4EE5\u4FBF\u540E\u9762\u7684\u903B\u8F91\u5904\u7406\u4E0D\u53D8\u3002\n search = `?${hash.split('?')[1]}`;\n }\n if (search !== '' && search !== undefined) {\n const reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)', 'i');\n const r = search.substr(1).match(reg);\n if (r != null) {\n return unescape(r[2]);\n }\n }\n return '';\n}\n\nexport function formatName (name: string) {\n if (name.indexOf('-') === -1) {\n return name;\n }\n let flag = false;\n return name.split('').map(c => {\n if (c === '-') {\n flag = true;\n return '';\n }\n if (flag) {\n flag = false;\n return c.toUpperCase();\n }\n return c;\n }).join('');\n}\n\n\nexport function onPageShowHide (\n onshow: ()=>void,\n onhide: ()=>void,\n) {\n const doc = document as any;\n let hidden: string, state: string, visibilityChange;\n if (typeof doc.hidden !== 'undefined') {\n hidden = 'hidden';\n visibilityChange = 'visibilitychange';\n state = 'visibilityState';\n } else if (typeof doc.mozHidden !== 'undefined') {\n hidden = 'mozHidden';\n visibilityChange = 'mozvisibilitychange';\n state = 'mozVisibilityState';\n } else if (typeof doc.msHidden !== 'undefined') {\n hidden = 'msHidden';\n visibilityChange = 'msvisibilitychange';\n state = 'msVisibilityState';\n } else if (typeof doc.webkitHidden !== 'undefined') {\n hidden = 'webkitHidden';\n visibilityChange = 'webkitvisibilitychange';\n state = 'webkitVisibilityState';\n }\n const cb = function () {\n if (doc[state] === hidden) {\n onhide();\n } else {\n onshow();\n }\n };\n doc.removeEventListener(visibilityChange, cb, false);\n doc.addEventListener(visibilityChange, cb, false);\n}\n\nexport function hackAlert (before?: ()=>void, after?: ()=>void) {\n const _alert = window.alert;\n const _confirm = window.confirm;\n const _prompt = window.prompt;\n const mod = (fn: Function) => {\n return (...args: any[]) => {\n if (before) {before();}\n const result = fn(...args);\n if (after) {after();}\n return result;\n };\n };\n try {\n window.alert = mod(_alert);\n window.confirm = mod(_confirm);\n window.prompt = mod(_prompt);\n } catch (e) {\n \n }\n}\n\nfunction hasUaName (name: string): boolean {\n return navigator.userAgent.toLocaleLowerCase().indexOf(name) !== -1;\n}\n\nexport const isInIframe = (() => {\n try {\n return window.self !== window.top;\n } catch (e) {\n return true;\n }\n})();\n\nexport const isPC = !/(iphone|ipad|ipod|ios|android)/i.test(navigator.userAgent.toLowerCase());\n\nexport const isQQBrowser = hasUaName('qqbrowser');\n\nexport const isFirefox = hasUaName('firefox');\n\nexport const isMacOs = hasUaName('macintosh');\n\nexport const isEdge = hasUaName('edge');\n\nexport const isOldEdge = isEdge && !hasUaName('chrome');\n\nexport const isIE = isOldEdge || hasUaName('trident') || hasUaName('msie');\n\nexport const isIOSChrome = hasUaName('crios');\n\nexport const isIOSEdge = hasUaName('edgios');\n\nexport const isChrome = hasUaName('chrome') || isIOSChrome;\n\nfunction createLargeObject () {\n const largeObject: Record = {};\n for (let i = 0; i < 500; i++) {\n largeObject[`${i}`] = `${i}`;\n }\n return largeObject;\n}\n\nexport function createLargeObjectArray () {\n const largeObject = createLargeObject();\n const largeObjectArray = [];\n\n for (let i = 0; i < 50; i++) {\n largeObjectArray.push(largeObject);\n }\n\n return largeObjectArray;\n}\n", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 22:16:40\n * @Description: Coding something\n */\nimport {Detector} from '../detector/detector';\nimport {config} from './config';\nimport {clearLog} from './log';\nimport {clearDevToolOpenState, checkOnDevClose} from './open-state';\nimport {hackAlert, isPC, onPageShowHide} from './util';\n\nlet interval: any = 0, timer: any = 0;\nconst calls: Detector[] = [];\nlet time = 0;\n\nexport function initInterval () {\n let _pause = false;\n const pause = () => {_pause = true;};\n const goon = () => {_pause = false;};\n hackAlert(pause, goon); // \u9632\u6B62 alert\u7B49\u65B9\u6CD5\u89E6\u53D1\u4E86debug\u5EF6\u8FDF\u8BA1\u7B97\n onPageShowHide(goon, pause); // \u9632\u6B62\u5207\u540E\u53F0\u89E6\u53D1\u4E86debug\u5EF6\u8FDF\u8BA1\u7B97\n\n interval = window.setInterval(() => {\n if (_pause) return;\n calls.forEach((detector) => {\n clearDevToolOpenState(detector.type);\n detector.detect(time++);\n });\n clearLog();\n checkOnDevClose();\n }, config.interval);\n // stopIntervalTime \u4E4B\u540E\u5224\u65AD \u5982\u679C\u4E0D\u662Fpc\u53BB\u6389\u5B9A\u65F6\u5668interval\uFF0C\u4E3A\u4E86\u4F18\u5316\u79FB\u52A8\u7AEF\u7684\u6027\u80FD\n // \u5982\u679C\u63A7\u5236\u9762\u677F\u88AB\u6253\u5F00\u4E86\u8BE5\u5B9A\u65F6\u5668timer\u4F1A\u88AB\u6E05\u9664\n timer = setTimeout(() => {\n if (!isPC) {\n clearDDInterval();\n }\n }, config.stopIntervalTime);\n}\n\nexport function registInterval (detector: Detector) {\n calls.push(detector);\n}\n\nexport function clearDDInterval () {\n window.clearInterval(interval);\n}\n\nexport function clearDDTimeout () {\n window.clearTimeout(timer);\n}", "/*\n * @Author: tackchen\n * @Date: 2021-12-24 15:14:06\n * @LastEditors: Please set LastEditors\n * @LastEditTime: 2022-09-27 22:46:44\n * @FilePath: /disable-devtool/src/close-window.js\n * @Description: Coding something\n */\nimport {config} from './config';\nimport {clearDDInterval} from './interval';\n\nexport function closeWindow () {\n clearDDInterval();\n if (config.url) {\n window.location.href = config.url;\n } else {\n try {\n window.opener = null;\n window.open('', '_self');\n // \u9700\u8981\u662F\u7531js\u8DF3\u8F6C\u5230\u8FD9\u4E2A\u9875\u9762\u624D\u53EF\u4EE5\u5173\u95ED\u8FD9\u4E2A\u9875\u9762\n window.close();\n window.history.back();\n } catch (e) {\n console.log(e);\n }\n setTimeout(() => {\n // \u5426\u5219\u6267\u884C\u8DF3\u8F6C\u5230 url\n window.location.href = `https://tackchen.gitee.io/404.html?h=${encodeURIComponent(location.host)}`;\n }, 500);\n }\n}\n", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 22:16:40\n * @Description: Coding something\n */\nimport {closeWindow} from './close-window';\nimport {DetectorType} from './enum';\n\nexport interface IConfig {\n md5: string; // \u7ED5\u8FC7\u7981\u7528\u7684md5\u503C\uFF0C\u8BE6\u60C5\u89C13.2\uFF0C\u9ED8\u8BA4\u4E0D\u542F\u7528\u7ED5\u8FC7\u7981\u7528\n url: string; // \u5173\u95ED\u9875\u9762\u5931\u8D25\u65F6\u7684\u8DF3\u8F6C\u9875\u9762\uFF0C\u9ED8\u8BA4\u503C\u4E3Alocalhost\n tkName: string; // \u7ED5\u8FC7\u7981\u7528\u65F6\u7684url\u53C2\u6570\u540D\u79F0\uFF0C\u9ED8\u8BA4\u4E3A ddtk\n ondevtoolopen(type: DetectorType, next: Function): void; // \u5F00\u53D1\u8005\u9762\u677F\u6253\u5F00\u7684\u56DE\u8C03\uFF0C\u542F\u7528\u65F6url\u53C2\u6570\u65E0\u6548\n ondevtoolclose: Function | null;\n interval: number; // \u5B9A\u65F6\u5668\u7684\u65F6\u95F4\u95F4\u9694 \u9ED8\u8BA4200ms\n disableMenu: boolean; // \u662F\u5426\u7981\u7528\u53F3\u952E\u83DC\u5355 \u9ED8\u8BA4\u4E3Atrue\n stopIntervalTime: number; // \u5728\u79FB\u52A8\u7AEF\u65F6\u53D6\u6D88\u76D1\u89C6\u7684\u7B49\u5F85\u65F6\u957F\n clearIntervalWhenDevOpenTrigger: boolean; // \u662F\u5426\u5728\u89E6\u53D1\u4E4B\u540E\u505C\u6B62\u76D1\u63A7\n detectors: DetectorType[] | 'all'; // \u542F\u7528\u7684\u76D1\u6D4B\u5668 \u9ED8\u8BA4\u4E3A\u5168\u90E8\n clearLog: boolean; // \u662F\u5426\u6BCF\u6B21\u90FD\u6E05\u9664log\n disableSelect: boolean; // \u662F\u5426\u7981\u7528\u9009\u62E9\u6587\u672C \u9ED8\u8BA4\u4E3Afalse\n disableCopy: boolean; // \u662F\u5426\u7981\u7528\u590D\u5236 \u9ED8\u8BA4\u4E3Afalse\n disableCut: boolean; // \u662F\u5426\u7981\u7528\u526A\u5207 \u9ED8\u8BA4\u4E3Afalse\n disablePaste: boolean; // \u662F\u5426\u7981\u7528\u7C98\u8D34 \u9ED8\u8BA4\u4E3Afalse\n}\n\nexport const config: IConfig = {\n md5: '',\n ondevtoolopen: closeWindow, // ondevtoolopen \u4F18\u5148\u7EA7\u9AD8\u4E8E url\n ondevtoolclose: null, // ondevtoolclose \u76D1\u542C\n url: '',\n tkName: 'ddtk',\n interval: 200,\n disableMenu: true, // \u662F\u5426\u7981\u7528\u53F3\u952E\u83DC\u5355\n stopIntervalTime: 5000, // \u5728\u79FB\u52A8\u7AEF\u65F6\u53D6\u6D88\u76D1\u89C6\u7684\u7B49\u5F85\u65F6\u957F\n clearIntervalWhenDevOpenTrigger: false, // \u662F\u5426\u5728\u89E6\u53D1\u4E4B\u540E\u505C\u6B62\u76D1\u63A7\n detectors: 'all',\n clearLog: true,\n disableSelect: false,\n disableCopy: false,\n disableCut: false,\n disablePaste: false,\n};\n\nconst MultiTypeKeys = ['detectors', 'ondevtoolclose'];\n\nexport function mergeConfig (opts: Partial = {}) {\n \n for (const key in config) {\n const k = key as keyof IConfig;\n if (\n typeof opts[k] !== 'undefined' &&\n (typeof config[k] === typeof opts[k] || MultiTypeKeys.indexOf(k) !== -1)\n ) {\n (config as any)[k] = opts[k];\n }\n }\n checkConfig();\n}\n\nfunction checkConfig () {\n if (\n typeof config.ondevtoolclose === 'function' &&\n config.clearIntervalWhenDevOpenTrigger === true\n ) {\n config.clearIntervalWhenDevOpenTrigger = false;\n console.warn('\u3010DISABLE-DEVTOOL\u3011clearIntervalWhenDevOpenTrigger \u5728\u4F7F\u7528 ondevtoolclose \u65F6\u65E0\u6548');\n }\n}", "/*\n * @Author: tackchen\n * @Date: 2021-12-24 13:18:23\n * @Description: Coding something\n */\n\nimport {config} from './config';\nimport {isIE} from './util';\n\nconst console = window.console || {\n log: function () {\n return;\n },\n table: function () {\n return;\n },\n clear: function () {\n return;\n }\n};\n\nexport const log = (() => {\n // ie \u4E0D\u652F\u6301\u7F13\u5B58\u4F7F\u7528 log\u7B49\u65B9\u6CD5\n return isIE ? ((...args: any[]) => {return console.log(...args);}) : console.log;\n})();\n\nexport const table = (() => {\n // ie \u4E0D\u652F\u6301\u7F13\u5B58\u4F7F\u7528 log\u7B49\u65B9\u6CD5\n return isIE ? ((...args: any[]) => {return console.table(...args);}) : console.table;\n})();\n\nconst clearLogFunc = (() => {\n // ie \u4E0D\u652F\u6301\u7F13\u5B58\u4F7F\u7528 log\u7B49\u65B9\u6CD5\n return isIE ? (() => {return console.clear();}) : console.clear;\n})();\n\nexport function clearLog () {\n if (config.clearLog)\n clearLogFunc();\n}\n", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 22:16:40\n * @Description: Coding something\n */\nimport {config} from './config';\nimport {isMacOs} from './util';\n\nexport function disableKeyAndMenu () {\n // let key1 = 'shiftKey', key2 = 'ctrlKey';\n // 'metaKey'; // mac \u7684 commond\n // 'altKey'; // mac \u7684 option\n const KEY = {J: 74, I: 73, U: 85, S: 83, F12: 123};\n \n // \u7981\u7528 ctrl + shift + i/j\n const isOpenDevToolKey = isMacOs ?\n ((e: KeyboardEvent, code: number) => (e.metaKey && e.altKey && (code === KEY.I || code === KEY.J))) :\n ((e: KeyboardEvent, code: number) => (e.ctrlKey && e.shiftKey && (code === KEY.I || code === KEY.J)));\n \n const isViewSourceCodeKey = isMacOs ?\n ((e: KeyboardEvent, code: number) => (e.metaKey && e.altKey && code === KEY.U) || (e.metaKey && code === KEY.S)) :\n ((e: KeyboardEvent, code: number) => (e.ctrlKey && (code === KEY.S || code === KEY.U)));\n\n window.addEventListener('keydown', (e) => {\n e = e || window.event;\n const keyCode = e.keyCode || e.which;\n if (\n keyCode === KEY.F12 || // \u7981\u7528f12\n isOpenDevToolKey(e, keyCode) || // \u7981\u7528 ctrl + shift + i\n isViewSourceCodeKey(e, keyCode) // \u7981\u7528 ctrl + u \u548C ctrl + s \u67E5\u770B\u548C\u4FDD\u5B58\u6E90\u7801\n ) {\n e.returnValue = false;\n e.preventDefault();\n return false;\n }\n }, true);\n\n disableMenu();\n disableSelect();\n disableCopy();\n disableCut();\n disablePaste();\n}\n\nfunction disableMenu () {\n if (config.disableMenu) {\n preventEvent(window, 'contextmenu');\n }\n}\nfunction disableSelect () {\n if (config.disableSelect) {\n preventEvent(window, 'selectstart');\n }\n}\nfunction disableCopy () {\n if (config.disableCopy) {\n preventEvent(window, 'copy');\n }\n}\nfunction disableCut () {\n if (config.disableCut) {\n preventEvent(window, 'cut');\n }\n}\nfunction disablePaste () {\n if (config.disablePaste) {\n preventEvent(window, 'paste');\n }\n}\nfunction preventEvent (target: Window & typeof globalThis, name: string) {\n target.addEventListener(name, (e: Event) => {\n e = e || window.event;\n e.returnValue = false;\n e.preventDefault();\n return false;\n });\n}", "/*\n * Configurable variables. You may need to tweak these to be compatible with\n * the server-side, but the defaults work in most cases.\n */\nconst hexcase = 0; /* hex output format. 0 - lowercase; 1 - uppercase */\nconst chrsz = 8; /* bits per input character. 8 - ASCII; 16 - Unicode */\n \n \n/*\n * These are the functions you'll usually want to call\n * They take string arguments and return either hex or base-64 encoded strings\n */\nfunction hex_md5 (s: string) { return binl2hex(core_md5(str2binl(s), s.length * chrsz));}\n\n/*\n * Calculate the MD5 of an array of little-endian words, and a bit length\n */\nfunction core_md5 (x: any, len: number)\n{\n /* append padding */\n x[len >> 5] |= 0x80 << ((len) % 32);\n x[(((len + 64) >>> 9) << 4) + 14] = len;\n \n \n let a = 1732584193;\n let b = -271733879;\n let c = -1732584194;\n let d = 271733878;\n \n \n for (let i = 0; i < x.length; i += 16)\n {\n const olda = a;\n const oldb = b;\n const oldc = c;\n const oldd = d;\n \n \n a = md5_ff(a, b, c, d, x[i + 0], 7, -680876936);\n d = md5_ff(d, a, b, c, x[i + 1], 12, -389564586);\n c = md5_ff(c, d, a, b, x[i + 2], 17, 606105819);\n b = md5_ff(b, c, d, a, x[i + 3], 22, -1044525330);\n a = md5_ff(a, b, c, d, x[i + 4], 7, -176418897);\n d = md5_ff(d, a, b, c, x[i + 5], 12, 1200080426);\n c = md5_ff(c, d, a, b, x[i + 6], 17, -1473231341);\n b = md5_ff(b, c, d, a, x[i + 7], 22, -45705983);\n a = md5_ff(a, b, c, d, x[i + 8], 7, 1770035416);\n d = md5_ff(d, a, b, c, x[i + 9], 12, -1958414417);\n c = md5_ff(c, d, a, b, x[i + 10], 17, -42063);\n b = md5_ff(b, c, d, a, x[i + 11], 22, -1990404162);\n a = md5_ff(a, b, c, d, x[i + 12], 7, 1804603682);\n d = md5_ff(d, a, b, c, x[i + 13], 12, -40341101);\n c = md5_ff(c, d, a, b, x[i + 14], 17, -1502002290);\n b = md5_ff(b, c, d, a, x[i + 15], 22, 1236535329);\n \n \n a = md5_gg(a, b, c, d, x[i + 1], 5, -165796510);\n d = md5_gg(d, a, b, c, x[i + 6], 9, -1069501632);\n c = md5_gg(c, d, a, b, x[i + 11], 14, 643717713);\n b = md5_gg(b, c, d, a, x[i + 0], 20, -373897302);\n a = md5_gg(a, b, c, d, x[i + 5], 5, -701558691);\n d = md5_gg(d, a, b, c, x[i + 10], 9, 38016083);\n c = md5_gg(c, d, a, b, x[i + 15], 14, -660478335);\n b = md5_gg(b, c, d, a, x[i + 4], 20, -405537848);\n a = md5_gg(a, b, c, d, x[i + 9], 5, 568446438);\n d = md5_gg(d, a, b, c, x[i + 14], 9, -1019803690);\n c = md5_gg(c, d, a, b, x[i + 3], 14, -187363961);\n b = md5_gg(b, c, d, a, x[i + 8], 20, 1163531501);\n a = md5_gg(a, b, c, d, x[i + 13], 5, -1444681467);\n d = md5_gg(d, a, b, c, x[i + 2], 9, -51403784);\n c = md5_gg(c, d, a, b, x[i + 7], 14, 1735328473);\n b = md5_gg(b, c, d, a, x[i + 12], 20, -1926607734);\n \n \n a = md5_hh(a, b, c, d, x[i + 5], 4, -378558);\n d = md5_hh(d, a, b, c, x[i + 8], 11, -2022574463);\n c = md5_hh(c, d, a, b, x[i + 11], 16, 1839030562);\n b = md5_hh(b, c, d, a, x[i + 14], 23, -35309556);\n a = md5_hh(a, b, c, d, x[i + 1], 4, -1530992060);\n d = md5_hh(d, a, b, c, x[i + 4], 11, 1272893353);\n c = md5_hh(c, d, a, b, x[i + 7], 16, -155497632);\n b = md5_hh(b, c, d, a, x[i + 10], 23, -1094730640);\n a = md5_hh(a, b, c, d, x[i + 13], 4, 681279174);\n d = md5_hh(d, a, b, c, x[i + 0], 11, -358537222);\n c = md5_hh(c, d, a, b, x[i + 3], 16, -722521979);\n b = md5_hh(b, c, d, a, x[i + 6], 23, 76029189);\n a = md5_hh(a, b, c, d, x[i + 9], 4, -640364487);\n d = md5_hh(d, a, b, c, x[i + 12], 11, -421815835);\n c = md5_hh(c, d, a, b, x[i + 15], 16, 530742520);\n b = md5_hh(b, c, d, a, x[i + 2], 23, -995338651);\n \n \n a = md5_ii(a, b, c, d, x[i + 0], 6, -198630844);\n d = md5_ii(d, a, b, c, x[i + 7], 10, 1126891415);\n c = md5_ii(c, d, a, b, x[i + 14], 15, -1416354905);\n b = md5_ii(b, c, d, a, x[i + 5], 21, -57434055);\n a = md5_ii(a, b, c, d, x[i + 12], 6, 1700485571);\n d = md5_ii(d, a, b, c, x[i + 3], 10, -1894986606);\n c = md5_ii(c, d, a, b, x[i + 10], 15, -1051523);\n b = md5_ii(b, c, d, a, x[i + 1], 21, -2054922799);\n a = md5_ii(a, b, c, d, x[i + 8], 6, 1873313359);\n d = md5_ii(d, a, b, c, x[i + 15], 10, -30611744);\n c = md5_ii(c, d, a, b, x[i + 6], 15, -1560198380);\n b = md5_ii(b, c, d, a, x[i + 13], 21, 1309151649);\n a = md5_ii(a, b, c, d, x[i + 4], 6, -145523070);\n d = md5_ii(d, a, b, c, x[i + 11], 10, -1120210379);\n c = md5_ii(c, d, a, b, x[i + 2], 15, 718787259);\n b = md5_ii(b, c, d, a, x[i + 9], 21, -343485551);\n \n \n a = safe_add(a, olda);\n b = safe_add(b, oldb);\n c = safe_add(c, oldc);\n d = safe_add(d, oldd);\n }\n return Array(a, b, c, d);\n \n \n}\n \n \n/*\n * These functions implement the four basic operations the algorithm uses.\n */\nfunction md5_cmn (q: number, a: any, b: any, x: any, s: any, t: any)\n{\n return safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b);\n}\nfunction md5_ff (a: number, b: number, c: number, d: number, x: any, s: number, t: number)\n{\n return md5_cmn((b & c) | ((~b) & d), a, b, x, s, t);\n}\nfunction md5_gg (a: number, b: number, c: number, d: number, x: any, s: number, t: number)\n{\n return md5_cmn((b & d) | (c & (~d)), a, b, x, s, t);\n}\nfunction md5_hh (a: number, b: number, c: number, d: number, x: any, s: number, t: number)\n{\n return md5_cmn(b ^ c ^ d, a, b, x, s, t);\n}\nfunction md5_ii (a: number, b: number, c: number, d: number, x: any, s: number, t: number)\n{\n return md5_cmn(c ^ (b | (~d)), a, b, x, s, t);\n}\n \n \n/*\n * Add integers, wrapping at 2^32. This uses 16-bit operations internally\n * to work around bugs in some JS interpreters.\n */\nfunction safe_add (x: number, y: number)\n{\n const lsw = (x & 0xFFFF) + (y & 0xFFFF);\n const msw = (x >> 16) + (y >> 16) + (lsw >> 16);\n return (msw << 16) | (lsw & 0xFFFF);\n}\n \n \n/*\n * Bitwise rotate a 32-bit number to the left.\n */\nfunction bit_rol (num: number, cnt: number)\n{\n return (num << cnt) | (num >>> (32 - cnt));\n}\n \n \n/*\n * Convert a string to an array of little-endian words\n * If chrsz is ASCII, characters >255 have their hi-byte silently ignored.\n */\nfunction str2binl (str: string)\n{\n const bin = Array();\n const mask = (1 << chrsz) - 1;\n for (let i = 0; i < str.length * chrsz; i += chrsz)\n bin[i >> 5] |= (str.charCodeAt(i / chrsz) & mask) << (i % 32);\n return bin;\n}\n \n \n/*\n * Convert an array of little-endian words to a hex string.\n */\nfunction binl2hex (binarray: string | any[])\n{\n const hex_tab = hexcase ? '0123456789ABCDEF' : '0123456789abcdef';\n let str = '';\n for (let i = 0; i < binarray.length * 4; i++)\n {\n str += hex_tab.charAt((binarray[i >> 2] >> ((i % 4) * 8 + 4)) & 0xF) +\n hex_tab.charAt((binarray[i >> 2] >> ((i % 4) * 8 )) & 0xF);\n }\n return str;\n}\n \n\nexport default hex_md5;", "export default '0.2.5';", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 22:10:55\n * @Description: Coding something\n */\n\nexport enum DetectorType {\n Unknown = -1,\n RegToString = 0,\n DefineId,\n Size,\n DateToString,\n FuncToString,\n Debugger,\n Performance,\n};", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 22:10:25\n * @Description: Coding something\n */\nimport {closeWindow} from 'src/utils/close-window';\nimport {config} from 'src/utils/config';\nimport {DetectorType} from 'src/utils/enum';\nimport {clearDDInterval, clearDDTimeout, registInterval} from 'src/utils/interval';\nimport {markDevToolOpenState} from 'src/utils/open-state';\n\nexport interface IDetectorConfig {\n type: DetectorType;\n enabled?: boolean;\n}\n\nexport abstract class Detector {\n type: DetectorType = DetectorType.Unknown;\n enabled: boolean = true;\n\n constructor ({\n type, enabled = true\n }: IDetectorConfig) {\n this.type = type;\n this.enabled = enabled;\n if (this.enabled) {\n registInterval(this);\n this.init();\n }\n }\n\n onDevToolOpen () {\n console.warn(`You ar not allow to use DEVTOOL! \u3010type = ${this.type}\u3011`);\n // alert(`You ar not allow to use DEVTOOL! \u3010type = ${type}\u3011`);\n if (config.clearIntervalWhenDevOpenTrigger) {\n clearDDInterval();\n }\n clearDDTimeout();\n config.ondevtoolopen(this.type, closeWindow);\n markDevToolOpenState(this.type);\n }\n\n init () {};\n abstract detect (time: number): void;\n}", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 20:23:12\n * @Description: Coding something\n */\n\nimport {Detector} from '../detector';\nimport {DetectorType} from 'src/utils/enum';\nimport {log} from 'src/utils/log';\nimport {isQQBrowser, isFirefox} from 'src/utils/util';\n\nexport default class extends Detector {\n lastTime: number;\n reg: RegExp;\n \n constructor () {\n super({\n type: DetectorType.RegToString,\n enabled: (isQQBrowser || isFirefox),\n });\n }\n\n init () {\n this.lastTime = 0;\n this.reg = /./;\n log(this.reg);\n this.reg.toString = () => {\n if (isQQBrowser) { // ! qq\u6D4F\u89C8\u5668\u5728\u63A7\u5236\u53F0\u6CA1\u6709\u6253\u5F00\u7684\u65F6\u5019\u4E5F\u4F1A\u89E6\u53D1 \u6253\u5F00\u7684\u65F6\u5019\u4F1A\u8FDE\u7EED\u89E6\u53D1\u4E24\u6B21 \u4F7F\u7528\u8FD9\u4E2A\u6765\u5224\u65AD\n const time = new Date().getTime();\n if (this.lastTime && time - this.lastTime < 100) {\n this.onDevToolOpen();\n } else {\n this.lastTime = time;\n }\n } else if (isFirefox) {\n this.onDevToolOpen();\n }\n return '';\n };\n }\n\n detect () {\n log(this.reg);\n }\n};", "/*\n * @Author: tackchen\n * @Date: 2021-11-15 22:26:57\n/*\n * @Author: tackchen\n * @Date: 2022-09-27 23:05:40\n * @Description: Coding something\n */\n\nimport {Detector} from '../detector';\nimport {DetectorType} from 'src/utils/enum';\nimport {log} from 'src/utils/log';\n\nexport default class extends Detector {\n div: HTMLElement;\n\n constructor () {\n super({\n type: DetectorType.DefineId,\n });\n }\n\n init () {\n this.div = document.createElement('div');\n (this.div as any).__defineGetter__('id', () => {\n this.onDevToolOpen();\n });\n Object.defineProperty(this.div, 'id', {\n get: () => {\n this.onDevToolOpen();\n },\n });\n }\n\n detect () {\n log(this.div);\n }\n}", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 20:23:12\n * @Description: Coding something\n */\n\nimport {Detector} from '../detector';\nimport {DetectorType} from 'src/utils/enum';\nimport {isEdge, isInIframe} from 'src/utils/util';\nimport {clearDevToolOpenState} from 'src/utils/open-state';\n\n\nexport default class extends Detector {\n \n constructor () {\n super({\n type: DetectorType.Size,\n enabled: (!isInIframe && !isEdge)\n });\n }\n\n init () {\n this.checkWindowSizeUneven();\n window.addEventListener('resize', () => {\n setTimeout(() => {\n this.checkWindowSizeUneven();\n }, 100);\n }, true);\n }\n\n detect () {\n }\n\n private checkWindowSizeUneven () {\n const screenRatio = countScreenZoomRatio();\n if (screenRatio === false) { // \u5982\u679C\u83B7\u53D6\u4E0D\u5230\u5C4F\u5E55\u7F29\u653E\u5C3A\u5BF8 \u5219\u4E0D\u542F\u7528sizeDetector\n return true;\n }\n const widthUneven = window.outerWidth - window.innerWidth * screenRatio > 200; // \u8C03\u5927\u4E00\u70B9\u9632\u6B62\u8BEF\u4F24\n const heightUneven = window.outerHeight - window.innerHeight * screenRatio > 300; // \u8C03\u5927\u4E00\u70B9\u9632\u6B62\u8BEF\u4F24\n if (widthUneven || heightUneven) {\n this.onDevToolOpen();\n return false;\n }\n clearDevToolOpenState(this.type);\n return true;\n }\n};\n\nfunction countScreenZoomRatio () {\n if (checkExist(window.devicePixelRatio)) {\n return window.devicePixelRatio;\n }\n const screen = window.screen as any;\n if (checkExist(screen)) {\n return false;\n }\n if (screen.deviceXDPI && screen.logicalXDPI) {\n return screen.deviceXDPI / screen.logicalXDPI;\n }\n return false;\n};\n\nfunction checkExist (v: any) {\n return typeof v !== 'undefined' && v !== null;\n}", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 23:05:40\n * @Description: Coding something\n */\n\nimport {clearLog, log} from '../../utils/log';\nimport {Detector} from '../detector';\nimport {DetectorType} from 'src/utils/enum';\n\nexport default class extends Detector {\n\n date: Date;\n count: 0;\n\n constructor () {\n super({\n type: DetectorType.DateToString\n });\n }\n\n init () {\n this.count = 0;\n this.date = new Date();\n this.date.toString = () => {\n this.count ++;\n return '';\n };\n }\n\n detect () {\n this.count = 0;\n log(this.date);\n clearLog();\n if (this.count >= 2) {\n this.onDevToolOpen();\n }\n }\n}", "/*\n * @Author: tackchen\n * @Date: 2021-11-15 22:26:57\n * @LastEditors: Please set LastEditors\n * @LastEditTime: 2022-09-28 00:05:24\n * @FilePath: /disable-devtool/src/detector/func-to-string.js\n * @Description: Coding something\n */\n\nimport {Detector} from '../detector';\nimport {DetectorType} from 'src/utils/enum';\nimport {clearLog, log} from 'src/utils/log';\nimport {isIOSChrome, isIOSEdge} from 'src/utils/util';\n\nexport default class extends Detector {\n count: number;\n func: Function;\n\n constructor () {\n super({\n type: DetectorType.FuncToString,\n enabled: (!isIOSChrome && !isIOSEdge),\n });\n }\n\n init () {\n this.count = 0;\n this.func = () => {};\n this.func.toString = () => {\n this.count ++;\n return '';\n };\n }\n\n detect () {\n this.count = 0;\n log(this.func);\n clearLog();\n if (this.count >= 2) {\n this.onDevToolOpen();\n }\n }\n}", "/*\n * @Author: tackchen\n * @Date: 2021-11-15 22:26:57\n/*\n * @Author: tackchen\n * @Date: 2022-09-27 23:05:40\n * @Description: Coding something\n */\n\nimport {Detector} from '../detector';\nimport {DetectorType} from 'src/utils/enum';\nimport {now, isIOSChrome, isIOSEdge} from 'src/utils/util';\n\nexport default class extends Detector {\n\n constructor () {\n super({\n type: DetectorType.Debugger,\n enabled: isIOSChrome || isIOSEdge,\n });\n }\n\n detect () {\n const date = now();\n (() => {debugger;})();\n if (now() - date > 100) {\n this.onDevToolOpen();\n }\n }\n}", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 20:23:12\n * @Description: Coding something\n */\n\nimport {Detector} from '../detector';\nimport {DetectorType} from 'src/utils/enum';\nimport {clearLog, log, table} from 'src/utils/log';\nimport {calculateTime, isChrome, createLargeObjectArray} from 'src/utils/util';\n\nexport default class extends Detector {\n largeObjectArray: any;\n maxPrintTime: number;\n\n constructor () {\n super({\n type: DetectorType.Performance,\n enabled: isChrome\n });\n }\n\n init () {\n this.maxPrintTime = 0;\n this.largeObjectArray = createLargeObjectArray();\n }\n\n detect () {\n const tablePrintTime = calculateTime(() => {table(this.largeObjectArray);});\n const logPrintTime = calculateTime(() => {log(this.largeObjectArray);});\n this.maxPrintTime = Math.max(this.maxPrintTime, logPrintTime);\n\n clearLog();\n\n if (tablePrintTime === 0 || this.maxPrintTime === 0) return false;\n\n if (tablePrintTime > this.maxPrintTime * 10) {\n this.onDevToolOpen();\n }\n }\n\n};", "/*\n * @Author: theajack\n * @Date: 2021-07-24 23:16:34\n * @LastEditor: theajack\n * @LastEditTime: 2022-09-27 23:57:26\n * @Description: Coding something\n */\n\nimport {config} from '../utils/config';\nimport RegToStringDetector from './sub-detector/reg-to-string';\nimport DefineIdDetector from './sub-detector/define-id';\nimport SizeDetector from './sub-detector/size';\nimport DateToStringDetector from './sub-detector/date-to-string';\nimport FuncToStringDetector from './sub-detector/func-to-string';\nimport DebuggerDetector from './sub-detector/debugger';\nimport PerformanceDetector from './sub-detector/performance';\n\nimport {DetectorType} from '../utils/enum';\n\nconst Detectors = {\n [DetectorType.RegToString]: RegToStringDetector,\n [DetectorType.DefineId]: DefineIdDetector,\n [DetectorType.Size]: SizeDetector,\n [DetectorType.DateToString]: DateToStringDetector,\n [DetectorType.FuncToString]: FuncToStringDetector,\n [DetectorType.Debugger]: DebuggerDetector,\n [DetectorType.Performance]: PerformanceDetector,\n};\n\nexport function initDetectors () {\n const typeArray = config.detectors === 'all' ?\n Object.keys(Detectors) : config.detectors;\n \n typeArray.forEach(type => {\n const DetectorClass = Detectors[type as Exclude];\n new DetectorClass();\n });\n}\n", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 22:49:01\n * @Description: Coding something\n */\nimport './utils/log';\nimport {disableKeyAndMenu} from './utils/key-menu';\nimport {initInterval} from './utils/interval';\nimport {formatName, getUrlParam} from './utils/util';\nimport {mergeConfig, config, IConfig} from './utils/config';\nimport md5 from './utils/md5';\nimport version from './version';\nimport {initDetectors} from './detector/index';\nimport {DetectorType} from './utils/enum';\nimport {isDevToolOpened} from './utils/open-state';\n\nexport function disableDevtool (opts?: Partial) {\n mergeConfig(opts);\n if (checkTk()) {return;}\n initInterval();\n disableKeyAndMenu();\n initDetectors();\n}\n\ndisableDevtool.md5 = md5;\ndisableDevtool.version = version;\ndisableDevtool.DetectorType = DetectorType;\ndisableDevtool.isDevToolOpened = isDevToolOpened;\n\nfunction checkTk () {\n if (config.md5) { // \u542F\u7528\u4E86 md5\n const tk = getUrlParam(config.tkName);\n if (md5(tk) === config.md5) { // \u547D\u4E2Dtk\n return true;\n }\n }\n return false;\n}\n\nfunction checkScriptUse () {\n if (typeof document === 'undefined') {\n return;\n }\n const dom = document.querySelector('[disable-devtool-auto]');\n if (!dom) {\n return;\n }\n const json: Record = {};\n ['md5', 'url', 'tk-name', 'interval', 'disable-menu', 'detectors'].forEach(name => {\n let value: any = dom.getAttribute(name);\n if (value !== null) {\n if (name === 'interval') {\n value = parseInt(value);\n } else if (name === 'disable-menu') {\n value = value === 'false' ? false : true;\n } else if (name === 'detector') {\n if (value !== 'all') {\n value = value.split(' ');\n }\n }\n json[formatName(name)] = value;\n }\n });\n disableDevtool(json as Partial);\n}\n\ncheckScriptUse();", "import {disableDevtool} from './main';\n\nexport default disableDevtool;", "/*\n * @Author: tackchen\n * @Date: 2022-09-27 21:46:40\n * @Description: Coding something\n */\nimport disableDevtool from '../../src';\n// import disableDevtool from '../npm';\n\ndisableDevtool({\n md5: '0b9e05caf5000360ec1c263335bd83fe', // ddtk\n // url: 'https://www.qq.com',\n ondevtoolopen: (type) => {\n // window.location.href = 'https://www.qq.com';\n document.body.innerHTML = 'devtool opened!; type =' + type;\n // next();\n // console.log(next);\n },\n ondevtoolclose: () => {\n // window.location.href = 'https://www.qq.com';\n \n document.body.innerHTML = 'devtool closed!;';\n // next();\n // console.log(next);\n },\n clearIntervalWhenDevOpenTrigger: true,\n interval: 1000,\n // tkName: 'ddtk',\n disableMenu: false,\n clearLog: false,\n disableCopy: true,\n disableSelect: true,\n disablePaste: true,\n // url: 'https://www.baidu.com'\n // detectors: [disableDevtool.DetectorType.DATE_TO_STRING],\n});\ndocument.addEventListener('click', () => {\n const div = document.createElement('div');\n div.innerText = `isOpen = ${disableDevtool.isDevToolOpened()}`;\n document.body.appendChild(div);\n // alert(disableDevtool.isDevToolOpened());\n});\n\n// console.log(disableDevtool.version);\n// console.log(disableDevtool.md5('xx'));\n\n\n// import {log} from '../src/log';\n\n// setTimeout(() => {\n// log(111);\n// debugger;\n// }, 3000);\n\n\n// window.log = log;"], - "mappings": ";AAYA,IAAI,wBAAwB;AAE5B,IAAM,YAEF,CAAC;AAEE,8BAA+B,MAAoB;AACxD,YAAU,QAAQ;AACpB;AAEO,+BAAgC,MAAoB;AACzD,YAAU,QAAQ;AACpB;AAEO,2BAA4B;AACjC,aAAW,OAAO,WAAW;AAC3B,QAAI,UAAU,MAAiC;AAC7C,8BAAwB;AACxB,aAAO;AAAA,IACT;AAAA,EACF;AACA,0BAAwB;AACxB,SAAO;AACT;AAEO,2BAA4B;AACjC,MACE,OAAO,OAAO,mBAAmB,YACjC;AACA,UAAM,aAAa;AACnB,QAAI,CAAC,gBAAgB,KAAK,YAAY;AACpC,aAAO,eAAe;AAAA,IACxB;AAAA,EACF;AACF;;;AC5CO,eAAgB;AACrB,SAAO,IAAI,KAAK,EAAE,QAAQ;AAC5B;AAEO,uBAAwB,MAAgB;AAC7C,QAAM,QAAQ,IAAI;AAClB,OAAK;AACL,SAAO,IAAI,IAAI;AACjB;AAEO,qBAAsB,MAAc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