Created
March 19, 2017 17:17
-
-
Save CodingPapi/34c354a27d3d30eb5bf80465cbd13ec5 to your computer and use it in GitHub Desktop.
Anti debug from browser
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!function test() { | |
// 捕获异常,递归次数过多调试工具会抛出异常。 | |
try{ | |
!function cir(i) | |
{ | |
// 当打开调试工具后,抛出异常,setTimeout执行test无参数,此时i == NaN,("" + i / i).length == 3 | |
// debugger设置断点 | |
( 1 !== ( "" + i / i).length || 0===a ) && function(){}.constructor("debugger")(),cir(++i); | |
} (0) | |
} catch(e) { | |
debugger; | |
setTimeout(test,500) | |
} | |
}() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment