
There are 2 files in the homedirectory: passwords.old and passwords.new. The password for the next level is in passwords.new and is the only line that has been changed between passwords.old and passwords.new
NOTE: if you have solved this level and see ‘Byebye!’ when trying to log into bandit18, this is related to the next level, bandit19
home 디렉토리에 2개의 파일이 있다: passwords.old, passwords.new. 다음 레벨의 패스워드는 passwords.new 파일에 있고, 이는 passwords.old 파일에서 변경된 값이다.
노트: 만약 이 레벨을 해결해 bandit18에 접근하려 하면 'Byebye!'를 보게 될 것이다. 이는 다음 레벨인 bandit19와 관련이 있다.
cat, grep, ls, diff
bandit17@bandit:~$ ls -al
total 36
drwxr-xr-x 3 root root 4096 Oct 5 2023 .
drwxr-xr-x 70 root root 4096 Oct 5 2023 ..
-rw-r----- 1 bandit17 bandit17 33 Oct 5 2023 .bandit16.password
-rw-r--r-- 1 root root 220 Jan 6 2022 .bash_logout
-rw-r--r-- 1 root root 3771 Jan 6 2022 .bashrc
-rw-r----- 1 bandit18 bandit17 3300 Oct 5 2023 passwords.new
-rw-r----- 1 bandit18 bandit17 3300 Oct 5 2023 passwords.old
-rw-r--r-- 1 root root 807 Jan 6 2022 .profile
drwxr-xr-x 2 root root 4096 Oct 5 2023 .ssh
bandit17@bandit:~$ file passwords.*
passwords.new: ASCII text
passwords.old: ASCII text
두 파일은 모두 ASCII text 파일이다. 눈으로 차이를 비교하려면 시간이 많이 소요되므로 diff 명령어를 이용해 두 파일간의 차이를 확인했다.
bandit17@bandit:~$ diff -c ./passwords.old ./passwords.new
bandit18에 해당 플래그로 접근하면 접근이 거부되고 'Byebye!' 로그를 확인할 수 있다.
Byebye !
Connection to bandit.labs.overthewire.org closed.