반응형

해커 12

리눅스 파일 내용 비교 diff 명령어 | Bandit Level 17 -> Level 18

문제 Level17. 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 리눅스 diff 명령어 diff 명령어는 두 파일을 한 줄씩 비교할 수 있는 명령어..

Bandit 2023.09.06

리눅스 ncat SSL 네트워크 통신 | Bandit Level 15 -> Level 16

문제 Level 15. The password for the next level can be retrieved by submitting the password of the current level to port 30001 on localhost using SSL encryption. Helpful note: Getting “HEARTBEATING” and “Read R BLOCK”? Use -ign_eof and read the “CONNECTED COMMANDS” section in the manpage. Next to ‘R’ and ‘Q’, the ‘B’ command also works in this version of that command… localhost 30001 으로 SSL 암호화를 사용..

Bandit 2023.09.03

리눅스 nc 데이터 전송 명령 | Bandit Level 14 -> Level 15

문제 Level 14. The password for the next level can be retrieved by submitting the password of the current level to port 30000 on localhost. 리눅스 nc 명령어 nc(NetCat) 설명 nc는 NetCat의 약자로 TCP 또는 UDP 프로토콜을 사용하는 네트워크 환경에서 데이터를 읽/쓰기를 하는데 사용되는 프로그램이다. 추가적으로 특정 서버의 포트 오픈을 확인하는데에도 사용되고, 방화벽 확인을 할 수도 있다. 하지만 포트를 특정지어 연결을 확인해야하니 확실한 포트랑 연결할 때 사용할 것 같다. nc 사용법 nc [옵션] [IP] [PORT] nc 옵션 종류 default : tcp로 IP / PORT..

Bandit 2023.09.02

리눅스 ssh key 접속 / RSA 공개키 암호화 | Bandit Level 13 -> Level 14

문제 Level 13. The password for the next level is stored in /etc/bandit_pass/bandit14 and can only be read by user bandit14. For this level, you don’t get the next password, but you get a private SSH key that can be used to log into the next level. Note: localhost is a hostname that refers to the machine you are working on. /etc/bamdit_pass/bandit14 에 패스워드가 저장되어있지만, bandit14만 읽기 권한이 있다. 이 단계에선 다음 ..

Bandit 2023.09.01

리눅스 압축 풀기 gzip, tar, bzip2 | Bandit Level 12 -> Level 13

문제 level12. The password for the next level is stored in the file data.txt, which is a hexdump of a file that has been repeatedly compressed. For this level it may be useful to create a directory under /tmp in which you can work using mkdir. For example: mkdir /tmp/myname123. Then copy the datafile using cp, and rename it using mv (read the manpages!) 오늘은 문제를 풀기위해서 필요한 내용이 굉장히 단순해요! 하지만 좀 푸는 과정이..

Bandit 2023.08.31

리눅스 문자 변환, 삭제 명령어 tr | Bandit Level 11 -> Level 12

문제 Level 11. The password for the next level is stored in the file data.txt, where all lowercase (a-z) and uppercase (A-Z) letters have been rotated by 13 positions 이 문제를 풀기 전에 알아야 할 리눅스 명령어를 공부해보도록 해요! 문제를 풀은 과정의 비하인드는 아래에 말해드리죠....ㅠㅠ 리눅스 tr 명령어 리눅스의 tr 명령어는 특정 문화를 변환 또는 삭제할 수 있게 해주는 명령어입니다! 지정한 문자 패턴을 변환 전과 변환 후를 특정하여 사용할 수 있습니다! tr 사용법 tr [옵션] [변환 전] [변환 후] tr 옵션별 사용법 default : 특정 문자열을 특정 문자열..

Bandit 2023.08.31

Bandit Level 9 -> Level 10 -> level 11 | 리눅스 문자만 추출 strings, base64 인코딩

문제 Level 9. The password for the next level is stored in the file data.txt in one of the few human-readable strings, preceded by several ‘=’ characters. Level 10.The password for the next level is stored in the file data.txt, which contains base64 encoded data 풀이 level 9 는.... 솔직히 말해서 정확한 풀이법을 모르겠어서.. 좀 알아봤습니다..(정답은 찾았지만 그래도 좀 더 완벽하게..ㅠㅠ) level 10의 data.txt 파일은 매우 지저분한 파일형태로 존재합니다.(binary 파일?!) ..

Bandit 2023.08.31

Bandit Level 8 -> Level 9 | 리눅스 중복 단어 제거 sort, uniq

문제 The password for the next level is stored in the file data.txt and is the only line of text that occurs only once 풀이 data.txt 파일에 단 한번 나타나는 특정 텍스트가 다음 레벨로 가는 비밀번호이다! 이번에 우리가 알아야할 내용은 파일안에 특정 문자가 한번만 나오도록 바꿔주는게 문제인 것 같다. 어떻게 문제를 풀면 될까?! 곰곰히 생각해보면 몇가지 키워드를 우리가 알 수 있다. 리눅스 파일에서 중복 단어 제거! 리눅스 파일에서 한번만 나온 단어 출력! 이 내용을 구글링을 한 결과 너무 바로 나와서 놀랐다. 바로 sort 와 uniq 명령어 두개를 통해 풀 수 있는 문제였다! (여기까지 힌트를 얻었다면, ..

Bandit 2023.08.30

Bandit Level 7 -> Level 8 | 리눅스 특정 단어 찾기 vi, grep

문제 The password for the next level is stored in the file data.txt next to the word millionth. 풀이 data.txt 파일에 millionth라는 단어에 비밀번호가 숨겨져 있다! 파일에 millionth라는 단어를 검색해보자! 이 문제는 생각보다 단순하게 접근할 수 있다고 생각했다. 특정 단어만 파일에서 찾으면 되어서 두가지로 접근해보려한다. 리눅스 vi 단어 찾기 리눅스의 vi 에디터에서는 특정 단어를 찾는 기능이 있다. 바로 명령모드에서 /[단어] 를 이용한 검색법이다. 이 단어를 사용한 예시는 아래 글에서 담고 있으니 필요하면 보도록 하자! https://youngari.tistory.com/entry/Bandit-Level-5..

Bandit 2023.08.30
반응형