ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • [2021/10/06][짤막한 이야기 - 루틴]
    짤막한 이야기 2021. 10. 6. 06:28
    728x90
    반응형

    [2021/10/06][짤막한 이야기 - 루틴]
    "루틴(Routine)"은 프로그램을 구성하는 단위 중 하나로, PinTool에서 활용되는 개념이다.
    흔히 알고있는 함수(Function)를 PinTool에서 칭하는 개념이며, 따라서 PinTool에서는 루틴과 함수가 동일한 의미로 혼용된다.
    루틴의 경우 하나의 섹션 내에서 여러 개가 존재할 수 있다.
    따라서 섹션에서와 마찬가지로 특별한 순회 방법을 사용하게 된다.
    참고로 PinTool의 가장 큰 구성 단위는 앱(App)이며, 앱 아래에 다수의 이미지(Image)가 있다.
    즉, 앱 내에서 여러개의 이미지가 존재할 수 있기 때문에 이미지의 특별한 순회 방법도 존재한다.
    루틴은 "RTN_"을 포함하는 계측 함수(RTN_AddInstrumentFuction)가 제공된다.
    이 계측 함수를 이용하면 프로그램 실행 중에 적재되는 모든 함수를 출력할 수 있다.
    중요한 점은 적재되는 모든 함수가 반드시 사용되는 모든 함수는 아니라는 점이다.
    다수의 DLL(이미지)이 프로그램 실행 시 적재되고, 이 DLL은 모두 사용되는 것이지만, DLL 내부에 정의되어 있는 함수는 모두 사용되는 것은 아니기 때문이다.
    일반적으로 분석가는 실제 사용되는 함수를 분석하기를 원하므로 이 방법만으로는 불충분하다.
    그렇다면 실제 사용되는 함수를 추출하기 위한 방법은 어떤 것이 있을까?
    [관련된 문서 - 핀툴 프로그래밍 기본서[제1부. 헬로 핀툴 월드!]]
    #이야기 #루니프 #핀 #핀툴 #섹션 #이미지 #루틴 #순회 #계측함수

    [2021/10/06][Short Story - Routine]
    "Routine" is one of the units that compose the program, and is a concept used in PinTool.
    A commonly known "Function" is a concept of routine that is called in PinTool, so in PinTool, routine and function are used interchangeably with the same meaning.
    In the case of a routine, several can exist within one section.
    So, as in the section, we use a special traversal method.
    For reference, the biggest component of PinTool is the app, and there are several images under the app.
    In other words, since there can be multiple images within the app, there is also a special way to traverse the images.
    The routine is provided with an instrumentation function (RTN_AddInstrumentFuction) containing "RTN_".
    By using this instrumentation function, all functions loaded during program execution can be output.
    It is important to note that not all functions loaded are necessarily all functions used.
    A number of DLLs (images) are loaded when the program is run, and these DLLs are all used.
    But not all functions defined inside the DLL are used.
    In general, this method alone is insufficient because analysts want to analyze the functions that are actually used.
    If so, is there any way to extract the functions that are actually used?
    [Related Documents - Basic Book for PinTool Programming[Part1. Hello PinTool World!]]
    #Story #LootNiP #Pin #PinTool #Section #Image #Routine #Traversal #InstrumentationFunction

    728x90
    반응형
Designed by Tistory.