这题考察js代码

    1. function dechiffre(pass_enc){
    2. var pass = "70,65,85,88,32,80,65,83,83,87,79,82,68,32,72,65,72,65";
    3. var tab = pass_enc.split(',');
    4. var tab2 = pass.split(',');var i,j,k,l=0,m,n,o,p = "";i = 0;j = tab.length;
    5. k = j + (l) + (n=0);
    6. n = tab2.length;
    7. for(i = (o=0); i < (k = j = n); i++ ){o = tab[i-l];p += String.fromCharCode((o = tab2[i]));
    8. if(i == 5)break;}
    9. for(i = (o=0); i < (k = j = n); i++ ){
    10. o = tab[i-l];
    11. if(i > 5 && i < k-1)
    12. p += String.fromCharCode((o = tab2[i]));
    13. }
    14. p += String.fromCharCode(tab2[17]);
    15. pass = p;return pass;
    16. }
    17. String["fromCharCode"](dechiffre("\x35\x35\x2c\x35\x36\x2c\x35\x34\x2c\x37\x39\x2c\x31\x31\x35\x2c\x36\x39\x2c\x31\x31\x34\x2c\x31\x31\x36\x2c\x31\x30\x37\x2c\x34\x39\x2c\x35\x30"));
    18. h = window.prompt('Enter password');
    19. alert( dechiffre(h) );

    乍一看很多,但实际上都是些没用的变量,经过简化后的代码:

    1. function dechiffre(pass_enc) {
    2. var pass = "70,65,85,88,32,80,65,83,83,87,79,82,68,32,72,65,72,65";
    3. var tab = pass_enc.split(',');
    4. var tab2 = pass.split(',');
    5. var i, p = "";
    6. for (i = 0; i < tab2.length; i++) {
    7. p += String.fromCharCode(tab2[i]);
    8. if (i == 5)
    9. break;
    10. }
    11. for (i = 0; i < tab2.length; i++) {
    12. if (i > 5 && i < tab.length - 1)
    13. p += String.fromCharCode(tab2[i]);
    14. }
    15. p += String.fromCharCode(tab2[17]);
    16. pass = p;
    17. return pass;
    18. }
    19. String["fromCharCode"](dechiffre("\x35\x35\x2c\x35\x36\x2c\x35\x34\x2c\x37\x39\x2c\x31\x31\x35\x2c\x36\x39\x2c\x31\x31\x34\x2c\x31\x31\x36\x2c\x31\x30\x37\x2c\x34\x39\x2c\x35\x30"));

    就不管代码是什么了,直接看pass的内容,写段代码转一下:

    1. let pass=[70,65,85,88,32,80,65,83,83,87,79,82,68,32,72,65,72,65]
    2. let code=pass.map((e)=>{
    3. return String.fromCharCode(e)
    4. })
    5. console.log(code.toString())

    但是解出来发现是加密码
    那么就去解下面那个
    依旧使用上面的代码,不过数组内容换一下

    1. let pass=[55,56,54,79,115,69,114,116,107,49,50]
    2. let code=pass.map((e)=>{
    3. return String.fromCharCode(e)
    4. })
    5. console.log(code.toString())

    得到正确密码,再加上格式cyberspace{},提交即可