首页 > 其他分享 >Wargames-Bandit-Level11

Wargames-Bandit-Level11

时间:2022-11-30 02:12:14浏览次数:35  
标签:字符 Wargames Level tr Bandit Level11 set1 set2 长度

Level 11

目录

Level Goal

The password for the next level is stored in the file data.txt, where all lowercase (a-z) and uppercase (A-Z) letters have been rotated by 13 positions

Solution

说是rot13加密了,其实也就是单表替换呗,但是在linux shell里面怎么做我确实不知道,本来想一个一个字符读出来然后变换,没有成功,最后找了个rot13的函数:

tr只能通过stdin(标准输入)接收输入(无法通过命令行参数接收)。其调用格式如下:

tr [options] set1 set2

来自stdin的输入字符按照位置从set1映射到set2(set1中的第一个字符映射到set2 中的第一个字符,以此类推),然后将输出写入stdout(标准输出)。set1和set2是字符类或字符组。如果两个字符组的长度不相等,那么set2  不断复制其最后一个字符,直到长度与set1 相同。如果set2的长度大于set1,那么在set2中超出set1长度的那部分字符则全部被忽略


bandit11@bandit:~$ cat data.txt | tr 'a-zA-Z' 'n-za-mN-ZA-M'
The password is JVNBBFSmZwKKOP0XbFXOoW8chDz5yVRv

标签:字符,Wargames,Level,tr,Bandit,Level11,set1,set2,长度
From: https://www.cnblogs.com/dyhaohaoxuexi/p/16937255.html

相关文章

  • Wargames-Bandit-Level15
    Level15目录Level15LevelGoalSolutionLevelGoalThepasswordforthenextlevelcanberetrievedbysubmittingthepasswordofthecurrentleveltoport300......
  • Wargames-Bandit-Level14
    Level14目录Level14LevelGoalSolutionLevelGoalThepasswordforthenextlevelcanberetrievedbysubmittingthepasswordofthecurrentleveltoport300......
  • Wargames-Bandit-Level13
    Level13目录Level13LevelGoalSolutionLevelGoalThepasswordforthenextlevelisstoredin/etc/bandit_pass/bandit14andcanonlybereadbyuserbandit14......
  • Wargames-Bandit-Level5
    Level5目录Level5LevelGoalSolutionLevelGoalThepasswordforthenextlevelisstoredinafilesomewhereundertheinheredirectoryandhasallofthefo......
  • Wargames-Bandit-Level9
    Level9目录Level9LevelGoalSolutionLevelGoalThepasswordforthenextlevelisstoredinthefiledata.txtinoneofthefewhuman-readablestrings,prece......
  • Wargames-Bandit-Level7
    Level7目录Level7LevelGoalSolutionLevelGoalThepasswordforthenextlevelisstoredinthefiledata.txtnexttothewordmillionthSolution说是million......
  • Wargames-Bandit-Level8
    Level8目录Level8LevelGoalSolutionLevelGoalThepasswordforthenextlevelisstoredinthefiledata.txtandistheonlylineoftextthatoccursonlyo......
  • Wargames-Bandit-Level6
    Level6目录Level6LevelGoalSolutionLevelGoalThepasswordforthenextlevelisstoredsomewhereontheserverandhasallofthefollowingproperties:ow......
  • Wargames-Bandit-Level10
    Level10目录Level10LevelGoalSolutionLevelGoalThepasswordforthenextlevelisstoredinthefiledata.txt,whichcontainsbase64encodeddataSolution......
  • Wargames-Bandit-Level0
    Level0目录Level0LevelGoalSolution毕业好久了...重拾一下博客今天开始学习Wargames,尽量不用翻译,顺便练习一下英语~~Bandit第一关非常入门:LevelGoalThegoalof......