OverTheWire Bandit write-up(Level 20 → Level 21)steemCreated with Sketch.

in wargame •  6 years ago 

To comply with the rule, in this write-up, I just deal with some hints related to this challenge. Here is no correct answer and no solution.

룰을 준수하기 위해, 이 문서에서는 이 챌린지와과 관련된 몇 가지 힌트만을 다룹니다. 여기에 정답과 솔루션은 없습니다.


Bandit Level 20 → Level 21

Level Goal
There is a setuid binary in the homedirectory that does the following: it makes a connection to localhost on the port you specify as a commandline argument. It then reads a line of text from the connection and compares it to the password in the previous level (bandit20). If the password is correct, it will transmit the password for the next level (bandit21).

레벨 목표
홈 디렉토리에 setuid 권한이 적용된 실행 파일이 있는데 이런 기능이 있다: 이 프로그램은 당신이 입력한 아규먼트로 입력한 포트를 이용하여 localhost로 접속한다. 이후 텍스트 한 줄을 읽고, 읽은 값을 이전 레벨의 패스워드(bandit20)와 비교한다. 만약 일치한다면, 이 프로그램은 다음 레벨(bandit21)을 위한 패스워드를 전송할 것이다.

NOTE: Try connecting to your own network daemon to see if it works as you think

주의: 당신의 네트워크에 접속하여 당신이 생각한대로 작동하는지 확인하라.

Commands you may need to solve this level
이 레벨을 클리어하기 위해 필요할 것으로 예상되는 명령어.
ssh, nc, cat, bash, screen, tmux, Unix ‘job control’ (bg, fg, jobs, &, CTRL-Z, …)


This challenge requires the ability to make a simple server. If you have experience with nc, it will be easier.

이 챌린지는 단순한 서버를 생성하는 능력을 요구합니다. 만약 당신이 nc와 관련된 경험이 있다면 보다 수월할 것입니다. 


The below is some part of the resolution procedures. I could find the flag as follow.

아래는 풀이 과정중 일부입니다. 아래와 같이 플래그를 찾을 수 있었습니다. 

[server]
bandit20@bandit:~$ ■■■■■■■■000 < ■■■■■■■■_pass/bandit20

[client]
bandit20@bandit:~$ ./suconnect 32000
Read: GbK■■■■■■■■s6il5■■■■■■■■je5f0j
Password matches, sending next password

[server]
bandit20@bandit:~$ ■■■■■■■■000 < ■■■■■■■■_pass/bandit20
gE26■■■■pwgrj0■■■■■■c9DGr


If you need the full write-up PDF, please refer to the following page.

풀 write-up PDF가 필요하신 분은 아래 페이지를 참고하시기 바랍니다.

https://cysecguide.blogspot.com/2017/10/wargame-write-up-list.html
Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!