ctf

NACTF writeup

はじめに Cryptography Vyom's Soggy Croutons - 50 Loony Tunes - Cryptography 50 Dr. J's Group Test Randomizer: Board Problem #0 - Cryptography 100 Reversible Sneaky Algorithm #0 - 125 Reversible Sneaky Algorithm #1 - 275 General Skills SHCA…

CSAW CTF 2019 Writeup [unagi - Web 200]

おそらくXXE。 こちらの記事を参考にflag.txtを読み込んで表示するxmlを作ってアップロードする。 www.mbsd.jp 文字列として"ENTITY", "SYSTEM", "file"が入っていた場合はWAFにブロックされる。 WAFをバイパスする必要がある。 WAFのバイパスに関しては以下…

id0-rsa.pubのメモ【Håstad's Broadcast Attack】

以下問題文。 A message was encrypted with three different 1024 bit RSA public keys, all of which have the exponent e=3 and different moduli N, resulting in three ciphertexts. Luckily, there is an attack that we can use to recover the messa…

id0-rsa.pubのメモ【Easy Passwords】

はじめに やっていきます。 id0-rsa.pub 問題 Warm up with some easy password cracking $1$abadsalt$0abdVS0D4YnJJ4b7l0RRr1 $1$abadsalt$p394aiqZnKUyrO5Rg9Tf01 $1$abadsalt$cJYsdaTkB9F9L9yH2Qjtd. $1$abadsalt$lFZDGpRdmOwRbu6HWuqjv0 $1$abadsalt$1AI…

SECCON Beginners CTF 2019 writeup

はじめに So Tired Party おわりに はじめに yharimaで参加し、11th / 666 placeでした。(自分は実質何もやってない) 今回はbinary強い人とweb強い人がチームにいたのでcryptoに専念してみた。(2問しか解けなかったので死にたい...) 他のメンバーのブログ…

INS'hAck 2019 writeup

ctf

はじめに gflag - MIC 50 Telegram - MIC 50 Yet Another RSA Challenge - Part 1 - CRY 50 おわりに 参考 はじめに あんまりやってないです。最終417位だったぽい。 gflag - MIC 50 以下の内容のファイルが渡される。 https://gist.github.com/kg0r0/0799da…

令和CTF writeup

ctf

最終結果はこんな感じでした。 フラグの例は? (10pt) やるだけ。 bREInWAck (100pt) 以下、問題ファイルの中身。 令和和和和和和和和和和和和和和和和「令和 和和和和令和和和和令和和和和和和和令和和 和和和和令和和平平平平平成」令和和和。令 和和和和…

UUT CTF writeup

はじめに honaというチームで参加してました。 稼働としては、2人で半日くらいでした。最終結果は441チーム中112位だったぽいです。 一応Crypto全完しました。自分が取り組んだ問題について writeupを書きます。 Solve the Crypto (25pt) 以下、問題文。 So…

id0-rsa.pubのメモ【Hello Bitcoin】

以下問題文。 Do you know how bitcoin addresses are constructed? This a number. A big number specifically. If it were a bitcoin secret key, what would its (uncompressed) address be? 9417613792618743863052672548396517564660232418131181494019…

Pragyan CTF 2019 writeup

Easy RSA 以下の値が渡される。eが大きいのでWiener's Attackができるのではと考える。 n = 413514550275673527863957027545525175432824699510881864021105557583918890022061739148026915990124447164572528944722263717357237476264481036272236727160588…

STEM CTF: Cyber Challenge 2019 writeup

はじめに 以前延期になったCTFが開催されていたのでやってみた。 In Plain Text Binary RE - 50 points 以下問題文。 Starring: Mary McCormack, Fred Weller, Nichole Hiltz, Todd Williams, Lesley Ann Warren, Paul Ben-Victor, Cristián de la Fuente, R…

InterKosenCTF writeup

はじめに cryptoは全部解くぞ!!という気持ちで始めたがOh my Hashで撃沈した。ついでに裏で開催されていたInsomni'hack Teaser 2019 CTF も撃沈した。 [Forensics 50pts]attack log 以下問題文。 Someone seems to have tried breaking through our authenti…

CTFで使うWebツールまとめ(個人用)

ctf

はじめに 自分用のCTFで使うWebツールのリンク集です。 忘れたやつとか結構あるので適宜追加していく予定です。 crypto http://factordb.com/ https://planetcalc.com/3324/ https://www.rot13.com/ http://www.decode.org/ https://jwt.io/ https://cryptii…

X-MAS CTF 2018 供養(crypto)

X-MAS CTF 2018の復習をします。crypto全然解けなかったので自分への戒めも込めて別枠で復習。 Hanukkah 以下問題文。 Most of the old religions celebrate Christmas in one way or another! hannukah.zip とりあえずzipを展開すると、Hanukkah.py、pubkey…

X-MAS CTF 2018 供養(Webとか)

X-MAS CTFでチラ見以上したけど解けなかった問題の復習をする。(スコアサーバーが動いているうちに、、、) これはその際のメモとお気持ち。cryptoはまた別でやります。 Santa's lucky number(Web) 以下問題文。 Come on! Santa's lucky number is pretty…

X-MAS CTF 2018 writeup

ctf

仕事終わりとかにチマチマやっていました。 cryptoを一問も解けていないので哀しみ。あとで復習します。 そこそこ復習しました。 反省会会場はこちら。 X-MAS CTF 2018 ふくしゅう - 生き恥 X-MAS CTF 2018 ふくしゅう(crypto) - 生き恥 Santa The Weaver…

SECCON2018 Classic Pwn 供養

SECCON2018 Classic Pwn 当日は仮想通貨ガチャ回していて取り組めなかったし、取り組んでいてもどのみち解けなかったと思う。最近pwn欲はあまりないが、Classic Pwnくらいは一般教養として復習しておこうと思った。 Classic Pwn まずはfileコマンドから。 $ …

squarectf2018 writeup

なかなか時間が確保できない今日この頃だが、脳死で解けそうなcrypto問があったので一応解いておいた。 C2: flipping bits 以下問題文。 Disabling C2 requires cracking a RSA message. You have two ciphertexts. The public key is (e1, n). Fortunately …

id0-rsa.pubのメモ【ECDSA Nonce Recovery】

ECDSA Nonce Recovery same k attackの話。以下問題文。 As part of signing something using DSA (digital signature algorithm) one must select a secret, cryptographically secure random number k to be used as a nonce. k must never be reused. Why…

id0-rsa.pubのメモ【Intro to PGP】

Intro to PGP gpgコマンドの使い方の話。 基本的には書かれている内容に沿ってすすめるだけだが、一部不明な点があったので以下の記事も参考に進めた。 qiita.com まず鍵サーバーpgp.mit.eduでid0rsa.pub.gmailを検索するとkeyIDがA81B09D4だとわかる。 鍵サ…

id0-rsa.pubのメモ【Hello OpenSSL】

Hello OpenSSL opensslコマンドの使い方の話。以下問題文。 This is an RSA key -----BEGIN RSA PRIVATE KEY----- MIGtAgEAAiEA5tygpSZdOZUMfuO3oTGWR4cALBtWui5UzrQw2/8JlZ0CAwEAAQIh AI9n4Yp1KFfKlHaF8d15tgUONQXn+e3aI+beFKoi2XipAhEA/ZkHPmcDwXIqloGr mi…

id0-rsa.pubのメモ【CCA on Textbook RSA】

CCA on Textbook RSA 以下問題文。 You've recovered this ciphertext being sent to a server: 912fcd40a901aa4b7b60ec37ce6231bb87783b0bf36f824e51fe77e9580ce1adb5cf894410ff87684969795525a63e069ee962182f3ff876904193e5eb2f34b20cfa37ec7ae0e9391bec3…

id0-rsa.pubのメモ【Insufficient Key Size】

Insufficient Key Size 以下問題文。 An incompetent systems administrator accidentally configured the company's encryption system to use very small keys. This RSA key modulus is only 119 bits. -----BEGIN RSA PUBLIC KEY----- MBYCD3AY9xf8ZmUVD…

id0-rsa.pubのメモ【Ps and Qs】

Ps and Qs 以下問題文。 Here is an RSA public key and a message that's been encrypted with it. -----BEGIN PUBLIC KEY----- MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAKzl5VggSXb/Jm2oqkPeRQwtpmGlLnJT Nre4LKx3VUljtLzYWj4xoG+aHBouwJT7DyeibpasCH8Yderr4zIGT…

id0-rsa.pubのメモ【Cut and Paste Attack On AES-ECB】

Cut and Paste Attack On AES-ECB ブロック暗号のモードの話。以下問題文。 ECB is the most basic mode of operation for block ciphers. When used with AES, any block of 16 bytes (the block size of AES) will encrypt to the same ciphertext when en…

id0-rsa.pubのメモ【Caesar】

Caesar シーザー暗号の話。以下問題文。 Should probably stick to the salad ZNKIGKYGXIOVNKXOYGXKGRREURJIOVNKXCNOINOYXKGRRECKGQOSTUZYAXKNUCURJHKIGAYKOSZUURGFEZURUUQGZZNKCOQOVGMKGZZNKSUSKTZHAZOLOMAXKOZYMUZZUHKGZRKGYZROQKLOLZEEKGXYURJUXCNGZKBKXB…

id0-rsa.pubのメモ【Intro to RSA】

Intro to RSA RSAが何かという話。 以下問題文。 Given the following public key, private key, and encrypted message (c=me mod N), compute the original message (m). Submit your answer as a hex integer (no lead 0x, all lower case characters). (…

id0-rsa.pubのメモ【Intro to Hashing】

crypto強くなりたいということでid0-rsaをちまちまやっていき、その記録を残していくお気持ち。 Intro to Hashing ハッシュ関数とはなんぞやという話。 Introなので記載されている方法に沿ってやればOK。 id0-rsa.pubのsha256ハッシュの値をさらにmd5ハッシ…

pwnable.krのメモ【passcode】

以下、問題文。 Mommy told me to make a passcode based login system. My initial C code was compiled without any error! Well, there was some compiler warning, but who cares about that? ssh passcode@pwnable.kr -p2222 (pw:guest) まず sshで接続…

SECCON2017 writeup

今回はぼっち参加だった。 とりあえず興味のあるCryptoを解いて行こうというお気持ちでスタートした。 解いたのはVigenere3dとSHA-1 is deadとPs and Qsの3問のみ。 Vigenere3d プログラムの以下の箇所より、暗号文は平文の文字と鍵kのi番目と鍵kのlen(k)-i…