mirror of
https://github.com/dobin/SuperMega
synced 2026-06-03 01:27:11 +00:00
refactor: iat related
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
from typing import Dict, List
|
||||
import logging
|
||||
|
||||
from model.exehost import ExeHost
|
||||
|
||||
logger = logging.getLogger("ExeHost")
|
||||
|
||||
|
||||
class IatEntry():
|
||||
def __init__(self, name: str, placeholder: bytes):
|
||||
self.name: str = name # Function Name, like "VirtualAlloc"
|
||||
self.placeholder: bytes = placeholder # Random bytes as placeholder
|
||||
|
||||
|
||||
|
||||
class Carrier():
|
||||
def __init__(self):
|
||||
self.iat_requests: List[IatEntry] = []
|
||||
|
||||
|
||||
def init(self):
|
||||
pass
|
||||
|
||||
|
||||
def add_iat_request(self, func_name: str, placeholder: bytes):
|
||||
self.iat_requests.append(IatEntry(func_name, placeholder))
|
||||
|
||||
|
||||
def get_all_iat_requests(self) -> List[IatEntry]:
|
||||
return self.iat_requests
|
||||
Reference in New Issue
Block a user