Loading... 无聊的时候偶然找到这个网站,解谜的过程还是挺打发时间的。把摸鱼的过程记录一下~ https://p.hancel.org/ ![摸鱼大闯关][1] PS:请不要在上班的时候打开这个页面,不然领导会请你喝茶。 #### 第一关: ![第一关][2] 页面没有任何提示~那就直接改URL吧OωO #### 第二关 ![第二关][3] 直接查看页面元素,发现一个a标签,href地址就是下一关啦 ```html <a href="/nexts.html" style="color:white;float:right;display:inline-block;">下一关>> </a> ``` #### 第三关 ![第三关][4] 还是查看页面元素,依然有个a标签,不过这次在页面全选是发现不了的。 ```html <a href="/gogo.html" style="display:none;">下一关>> </a> ``` 设置display为none后,对应的元素就不会显示了 #### 第四关 ![第四关][5] 查看页面元素,html末尾有段注释 <!-- 不错嘛~ 下一关是 /lang/mac.html --> #### 第五关 ![第五关][6] 操作系统:linux #### 第六关 ![第六关][7] 提示~有个小点点在屏幕上,看源码找到图片地址,就是下关地址了,不过地址可别忘了加上lang https://p.hancel.org//images/what.jpg 前面几关直接看源码就能找到,后面开始需要转一下弯了。 #### 第七关 ![第七关][8] html提示:The password is here #### 第八关 ![第八关][9]  ,html中代表空格,5个字母单词,那就是space了 #### 第九关 ![第九关][10] 最开始看到图片比较懵逼,但是下面的一串字符明显是加密过后的下一关地址,.kwpo对应.html,这是很常见的移位加密,原字符右移3位而得。 ![加密过程][11] 那就很容易得出解密串了。稍微百度一下,就知道这是一种比较古老的加密方式,在古罗马时就很流行,叫做凯撒密码。网上也有很多网站工具可以直接输入位移位数进行加解密的。程序猿肯定要用程序的方式啦。 ```java /** * 〈凯撒密码〉 * <p>〈功能详细描述〉</p> * * @author smalleyes */ public class CaesarCipher { /** * 加密 * * @param input 数据源(需要加密的数据) * @param key 秘钥,即偏移量 * @return 返回加密后的数据 */ public static String encrypt(String input, int key) { char[] chars = input.toCharArray(); for (int i = 0; i < chars.length; i++) { int ascii = chars[i]; ascii = (ascii - '!' + key) % 94 + '!'; char newChar = (char) ascii; chars[i] = newChar; } return new String(chars); } /** * 解密 * * @param input 数据源(被加密后的数据) * @param key 秘钥,即偏移量 * @return 返回解密后的数据 */ public static String decrypt(String input, int key) { //得到字符串里的每一个字符 char[] array = input.toCharArray(); for (int i = 0; i < array.length; ++i) { //字符转换成ASCII 码值 int ascii = array[i]; //恢复字符偏移,例如b->a ascii = (ascii - '~' - key) % 94 + '~'; //ASCII 码值转换为char char newChar = (char) ascii; //替换原有字符 array[i] = newChar; //以上4 行代码可以简写为一行 //array[i] = (char) (array[i] - key); } //字符数组转换成String return new String(array); } public static void main(String[] args) { System.out.println(decrypt("qhaw vwdjh lv pdwkhpdwlf.kwpo",3)); } } ``` 解密到字符串ne^tstageismathematic+html,因为没有做只在字母间的位移,所以解密会有一点偏差,有兴趣可以想想,怎么做到只在字母间加解密。原句是:next stage is mathematic.html #### 第十关 ![第十关][12] 一个数字,猜地址,根据网页标题Hex(16进制),就直接转十六进制下,上代码 ```java public static void main(String[] args) { int num = 251636973; String hex = ""; while (num != 0) { int hexValue = num % 16; char hexNum = (hexValue <= 9 && hexValue >= 0) ? (char) (hexValue + '0') : (char) (hexValue - 10 + 'A'); hex = hexNum + hex; num = num / 16; } System.err.println(hex); } ``` 前十关结束~还是比较简单的... 11-20关解题思路: <div class="preview"> <div class="post-inser post box-shadow-wrap-normal"> <a href="https://www.smalleyes.wang/index.php/archives/12/" target="_blank" class="post_inser_a no-external-link no-underline-link"> <div class="inner-image bg" style="background-image: url(https://qncloud.smalleyes.wang/slackoff/fish_stage_12.png);background-size: cover;"></div> <div class="inner-content" > <p class="inser-title">摸鱼大闯关-答案(11-20关)(涉嫌剧透,谨慎观看)</p> <div class="inster-summary text-muted"> 继续我们的摸鱼之旅~第十一关地址:https://p.hancel.org/helloworld/EFFACED.... </div> </div> </a> <!-- .inner-content #####--> </div> <!-- .post-inser ####--> </div> [1]: https://qncloud.smalleyes.wang/slackoff/fish_stage_0.png [2]: https://qncloud.smalleyes.wang/slackoff/fish_stage_1.png [3]: https://qncloud.smalleyes.wang/slackoff/fish_stage_2.png [4]: https://qncloud.smalleyes.wang/slackoff/fish_stage_3.png [5]: https://qncloud.smalleyes.wang/slackoff/fish_stage_4.png [6]: https://qncloud.smalleyes.wang/slackoff/fish_stage_5.png [7]: https://qncloud.smalleyes.wang/slackoff/fish_stage_6.png [8]: https://qncloud.smalleyes.wang/slackoff/fish_stage_7.png [9]: https://qncloud.smalleyes.wang/slackoff/fish_stage_8.png [10]: https://qncloud.smalleyes.wang/slackoff/fish_stage_9.png [11]: https://qncloud.smalleyes.wang/slackoff/fish_stage_9_answer.png [12]: https://qncloud.smalleyes.wang/slackoff/fish_stage_10.png © Allow specification reprint Support Appreciate the author AliPayWeChat Like 1 If you think my article is useful to you, please feel free to appreciate