Goal: Find the password and log into level 9. The password is the only password that appears only once.

First, lets see what is even in the data.txt file.

bandit8@bandit:~$ cat data.txt 
dPk8jhZUckmUiDsn4fXE28LpV5VTvev7
CgUjZiluCoMEvzNAge1Nbv3g9tpLQQj2
UuNP4xguSOjcTHAzdtHBgm2eNz1Z5133
[...]

As we can see there are hundreds of possible passwords so we are going to need to do more work. First, lets sort all of the passwords so it is easier to pick out unique passwords.

bandit8@bandit:~$ cat data.txt | sort
Z6SdYkOf5loRVj4uRk6cNiz10RfPnwNy
Z6SdYkOf5loRVj4uRk6cNiz10RfPnwNy
Z6SdYkOf5loRVj4uRk6cNiz10RfPnwNy
Z6SdYkOf5loRVj4uRk6cNiz10RfPnwNy
Z6SdYkOf5loRVj4uRk6cNiz10RfPnwNy
zokSjnkcDj1hdGEBE4feukfCtFmv82ZZ
zokSjnkcDj1hdGEBE4feukfCtFmv82ZZ
[...]

Okay we could definitely look through all of these passwords to see any unique passwords. However, we could also use the uniq command! This command usually just gets rid of repeated lines but we can use the -u flag to only print unique lines.

bandit8@bandit:~$ cat data.txt | sort | uniq -u
[REDACTED]

Now we have our password for level 9 and we sign into the next level!