攻防世界crypto部分Decrypt-the-Message的writeup

15 篇文章 0 订阅

The life that I have
Is all that I have
And the life that I have
Is yours.

The love that I have
Of the life that I have
Is yours and yours and yours.

A sleep I shall have
A rest I shall have
Yet death will be but a pause.

For the peace of my years
In the long green grass
Will be yours and yours and yours.

decrypted message: emzcf sebt yuwi ytrr ortl rbon aluo konf ihye cyog rowh prhj feom ihos perp twnb tpak heoc yaui usoa irtd tnlu ntke onds goym hmpq

这是一种比较奇特的加密方式,叫做Poem Codes,详见:http://wmbriggs.com/post/1001/

加密过程如下:

(1)就其算法而言,去诗歌头一个单词,全部罗列出来,然后所有单词的字母按字母表排序并编码,如第一个a为1,第二个a为2,如果没有a了就看b,第一个b为3,第二个b为4,一直排列下去。。。

(2)将要加密的信息的字母每18个一行(不足一行的abcdef....补足)

(3)将加密的信息第一个字母对应第一步的编码数字,到第二步生成的字母表中取某列。

(4)分组即成加密信息。

解密过程非常复杂,不过,有人已经写好了解密工具,详见:https://github.com/abpolym/crypto-tools/tree/master/poemcode

具体用法如下(请注意只支持python2):

python poemcode.py examples/2/ctfpoem  examples/2/ctfcip

猜解出一大堆消息,选择最像的那条即可,flag是:

ifyouthinkcryptographyistheanswertoyourproblemthenyoudonotknowwhatyourproblemisabcdefghijklmnopqrstu

 

  • 2
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
前端加密所需的js类库,包含各种加密方法,文件列表: crypto-js-develop, 0 , 2017-06-02 crypto-js-develop\.gitignore, 23 , 2017-06-02 crypto-js-develop\.jshintrc, 1036 , 2017-06-02 crypto-js-develop\CONTRIBUTING.md, 482 , 2017-06-02 crypto-js-develop\Gruntfile.js, 1133 , 2017-06-02 crypto-js-develop\LICENSE, 1169 , 2017-06-02 crypto-js-develop\README.md, 4010 , 2017-06-02 crypto-js-develop\docs, 0 , 2017-06-02 crypto-js-develop\docs\QuickStartGuide.wiki, 18085 , 2017-06-02 crypto-js-develop\grunt, 0 , 2017-06-02 crypto-js-develop\grunt\config, 0 , 2017-06-02 crypto-js-develop\grunt\config\clean.js, 107 , 2017-06-02 crypto-js-develop\grunt\config\copy.js, 362 , 2017-06-02 crypto-js-develop\grunt\config\jshint.js, 354 , 2017-06-02 crypto-js-develop\grunt\config\jsonlint.js, 259 , 2017-06-02 crypto-js-develop\grunt\config\modularize.js, 8622 , 2017-06-02 crypto-js-develop\grunt\config\update_json.js, 999 , 2017-06-02 crypto-js-develop\grunt\tasks, 0 , 2017-06-02 crypto-js-develop\grunt\tasks\modularize.js, 2325 , 2017-06-02 crypto-js-develop\package.json, 1143 , 2017-06-02 crypto-js-develop\src, 0 , 2017-06-02 crypto-js-develop\src\aes.js, 8157 , 2017-06-02 crypto-js-develop\src\cipher-core.js, 29262 , 2017-06-02 crypto-js-develop\src\core.js, 22209 , 2017-06-02 crypto-js-develop\src\enc-base64.js, 3570 , 2017-06-02 crypto-js-develop\src\enc-utf16.js, 3607 , 2017-06-02 crypto-js-develop\src\evpkdf.js, 3558 , 2017-06-02 crypto-js-develop\src\format-hex.js, 1410 , 2017-06-02 crypto-js-develop\src\hmac.js, 3666 , 2017-06-02 crypto-js-develop\src\lib-typedarrays.js, 1869 , 2017-06-02 crypto-js-develop\src\md5.js, 9092 , 2017-06-02 crypto-js-develop\src\mode-cfb.js, 1698 , 2017-06-02 crypto-js-develop\src\mode-ctr-gladman.js, 1899 , 2017-06-02 crypto-js-develop\src\mode-ctr.js, 1062 , 2017-06-02 crypto-js-develop\src\mode-ecb.js, 484 , 2017-06-02 crypto-js-develop\src\mode-ofb.js, 924 , 2017-06-02 crypto-js-develop\src\pad-ansix923.js, 854 , 2017-06-02 crypto-js-develop\src\pad-iso10126.js, 706 , 2017-06-02 crypto-js-develop\src\pad-iso97971.js, 505 , 2017-06-02 crypto-js-develop\src\pad-nopadding.js, 138 , 2017-06-02 crypto-js-develop\src\pad-zeropadding.js, 609 , 2017-06-02 crypto-js-develop\src\pbkdf2.js, 4125 , 2017-06-02 crypto-js-develop\src\rabbit-legacy.js, 6224 , 2017-06-02 crypto-js-develop\src\rabbit.js, 6195 , 2017-06-02 crypto-js-develop\src\rc4.js, 3081 , 2017-06-02 crypto-js-develop\src\ripemd160.js, 8812 , 2017-06-02 crypto-js-develop\src\sha1.js, 3722 , 2017-06-02 crypto-js-develop\src\sha224.js, 1521 , 2017-06-02 crypto-js-develop\src\sha256.js, 5206 , 2017-06-02 crypto-js-develop\src\sha3.js, 10236 , 2017-06-02 crypto-js-develop\src\sha384.js, 1833 , 2017-06-02 crypto-js-develop\src\sha512.js, 13077 , 2017-06-02 crypto-js-develop\src\tripledes.js, 23837 , 2017-06-02 crypto-js-develop\src\x64-core.js, 8562 , 2017-06-02 crypto-js-develop\test, 0 , 2017-06-02 crypto-js-develop\test\aes-profile.js, 1104 , 2017-06-02 crypto-js-develop\test\aes-test.js, 4997 , 2017-06-02 crypto-js-develop\test\cipher-test.js, 17242 , 2017-06-02 crypto-js-develop\test\des-profile.js, 1040 , 2017-06-02 crypto-js-develop\test\des-test.js, 6318 , 2017-06-02 crypto-js-develop\test\enc-base64-test.js, 3089 , 2017-06-02 crypto-js-develop\test\enc-hex-test.js, 475 , 2017-06-02 crypto-js-develop\test\enc-latin1-test.js, 503 , 2017-06-02 crypto-js-develop\test\enc-utf16-test.js, 2121 , 2017-06-02 crypto-js-develop\test\enc-utf8-test.js, 1445 , 2017-06-02 crypto-js-develop\test\evpkdf-profile.js, 326 , 2017-06-02 crypto-js-develop\test\evpkdf-test.js, 1375 , 2017-06-02 crypto-js-develop\test\format-openssl-test.js, 1795 , 2017-06-02 crypto-js-develop\test\hmac-md5-profile.js, 947 , 2017-06-02 crypto-js-develop\test\hmac-md5-test.js, 2662 , 2017-06-02 crypto-js-develop\test\hmac-sha224-test.js, 2812 , 2017-06-02 crypto-js-develop\test\hmac-sha256-test.js, 2852 , 2017-06-02 crypto-js-develop\test\hmac-sha384-test.js, 3012 , 2017-06-02 crypto-js-develop\test\hmac-sha512-test.js, 3172 , 2017-06-02 crypto-js-develop\test\kdf-openssl-test.js, 644 , 2017-06-02 crypto-js-develop\test\lib-base-test.js, 3132 , 2017-06-02 crypto-js-develop\test\lib-cipherparams-test.js, 2654 , 2017-06-02 crypto-js-develop\test\lib-passwordbasedcipher-test.js, 966 , 2017-06-02 crypto-js-develop\test\lib-serializablecipher-test.js, 2365 , 2017-06-02 crypto-js-develop\test\lib-typedarrays-test.js, 2249 , 2017-06-02 crypto-js-develop\test\lib-wordarray-test.js, 3303 , 2017-06-02 crypto-js-develop\test\md5-profile.js, 743 , 2017-06-02 crypto-js-develop\test\md5-test.js, 2772 , 2017-06-02 crypto-js-develop\test\mode-cbc-test.js, 2024 , 2017-06-02 crypto-js-develop\test\mode-cfb-test.js, 2103 , 2017-06-02 crypto-js-develop\test\mode-ctr-test.js, 2213 , 2017-06-02 crypto-js-develop\test\mode-ecb-test.js, 1484 , 2017-06-02 crypto-js-develop\test\mode-ofb-test.js, 2042 , 2017-06-02 crypto-js-develop\t

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值