Theos 트윅 제작 실습

요약
Tags
tweak

Theos 트윅 제작 실습

theos 프로젝트 생성

$ $THEOS/bin/nic.pl
notion image
 
  • theos 프로젝트 생성
  • Bundle filter 적용
    • 명시한 번들과 Cydia Substrate 링크 설정
    • 모든 앱을 대상으로 적용시키고 싶으므로 UIKit 프레임워크
    • notion image
 

후킹 트윅 작성

프로젝트를 생성하면 기본 파일 4개가 있다.
notion image
Tweak.x를 수정해서 후킹 메소드를 작성하면 됨.
notion image

Tweak.x 내용 수정

  • nano, vi, vim 등의 텍스트 에디터 활용!
  • apt-get install nano
notion image

트윅 빌드

$ make $ make package
notion image

트윅 설치

$ make install or dpkg –i deb파일
notion image
 

만든 트윅 써보기

  • [Cydia – 설치완료 – 최근] 에서 확인 가능
  • Xcode Console에서 로그 확인
notion image
notion image
 

설치한 트윅과 관련된 dylib 경로

/Library/MobileSubstrate/DynamicLibraries/
  • plist에는 트윅 작성 시 적었던 제약옵션을 확인할 수 있다.
    • 트윅 적용범위 파악
    • notion image
  • 트윅 설치 후 문제가 생겼다면, 원인이라고 의심되는 트윅을 plist와 함께 삭제하면 된다.