반응형
https://overthewire.org/wargames/bandit/bandit1.html
 

OverTheWire: Level Goal

We're hackers, and we are good-looking. We are the 1%. <!-- Please read and accept the Rules! --> Level Goal The password for the next level is stored in a file called readme located in the home directory. Use this password to log into bandit1 using SSH. W

overthewire.org


Bandit Level 0 → Level 1


Level Goal


The password for the next level is stored in a file called readme located in the home directory. Use this password to log into bandit1 using SSH. Whenever you find a password for a level, use SSH (on port 2220) to log into that level and continue the game.

Commands you may need to solve this level
ls , cd , cat , file , du , find

 

 

문제 해석

 

Level 0 -> Level 1로 가기 위한 비밀번호는 readme라는 홈 디렉토리안에 있다. SSH 통신을 활용하여 비밀번호를 찾아보자.

 


home 디렉토리 안에 readme 파일이 있으니, home 디렉토리로 이동해보자.

 

우선, pwd를 이용하여 내가 어느 위치에 있는지 확인해보자.

pwd : 현재 자신의 위치를 나타냄
bandit0@bandit:~$ pwd
/home/bandit0

 

/home/bandit0 를 통해, 현재 위치가 home 디렉토리라는 것을 확인했다.

 

ls 명령어를 이용하여, 현재 디렉토리에 어떤 파일, 폴더가 있는 출력해보자

ls : 현재 디렉토리에 있는 파일, 폴더 출력
ls -l : [파일 형태] [권한] [하드 링크 수] [소유자] [그룹] [파일 크기] [시간] [파일 이름]
bandit0@bandit:~$ ls -l
total 4
-rw-r----- 1 bandit1 bandit0 437 Jul 17 15:57 readme

-rw-r-----에서 가장 첫 번째 문자가 d이면 directory, -이면 일반 파일

 

이로써, 현재 home 디렉토리에 readme 파일이 있는 것을 확인할 수 있다.

 

cat 명령어를 사용하여 readme 파일 내용을 출력하자

cat : 해당 파일의 내용을 출력, 또는 입력할 수 있음
bandit0@bandit:~$ cat readme
Congratulations on your first steps into the bandit game!!
Please make sure you have read the rules at https://overthewire.org/rules/
If you are following a course, workshop, walthrough or other educational activity,
please inform the instructor about the rules as well and encourage them to
contribute to the OverTheWire community so we can keep these games free!

The password you are looking for is: ZjLjTmM6FvvyRnrb2rfNWOZOTa6ip5If

 

이로서, Level 0에서 Level 1로 가는 ZjLjTmM6FvvyRnrb2rfNWOZOTa6ip5If 비밀번호를 획득했다.

 

참고로, bandit 비밀번호는 따로 메모장에 저장해두는 게 좋다! 

Level0 -> Level1

Level1 -> Level2

당연한 이야기지만, 각 레벨마다 비밀번호가 다르기 때문..!

 

정리 

1. pwd를 사용하여 현재 위치 확인

2. ls -l로 현재 위치의 디렉토리나 파일 확인

3. cat으로 readme 파일의 내용 출력


잡지식 Time

 

Putty 텍스트 복사 -> windows 텍스트 붙여넣기

- Putty에서 드래그 후 Ctrl + c, 윈도우에서 Ctrl + v

 

Windows 텍스트 복사 -> Putty 텍스트 붙여넣기

- 윈도우에서 Ctrl + c 후 Putty에서 Shift + Inesrt

 

Putty에서 clear 명령어 혹은 ctrl + l (i 아니고 L 이다) 하면 화면 깨끗해짐

 

반응형

'네트워크 공부 > bandit' 카테고리의 다른 글

[Bandit] Level 4 -> Level 5  (0) 2024.07.19
[Bandit] Level 3 -> Level 4  (0) 2024.07.18
[Bandit] Level 2 -> Level 3  (0) 2024.07.18
[Bandit] Level 1 -> Level 2  (0) 2024.07.18
[Bandit] Bandit Level 0 putty로 시작하기  (0) 2024.07.18

+ Recent posts