From 143f585b0e02ae87e0d383e27c48aa76745db51b Mon Sep 17 00:00:00 2001 From: dusoleil Date: Thu, 16 Mar 2023 18:55:59 -0400 Subject: elf: Automatically lookup Arch on ELF construction Signed-off-by: dusoleil --- sploit/rev/elf.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sploit/rev/elf.py b/sploit/rev/elf.py index e3c0a55..5833bf5 100644 --- a/sploit/rev/elf.py +++ b/sploit/rev/elf.py @@ -1,4 +1,5 @@ from sploit.rev import ldd, r2 +from sploit.arch import lookup_arch from itertools import zip_longest class ELF: @@ -14,6 +15,7 @@ class ELF: bininfo = r2.get_bin_info(self.path) self.info = self.__BININFO__(bininfo) self.security = self.__SECINFO__(bininfo) + self.arch = lookup_arch(self.info.arch_string, self.info.wordsize, self.info.endianness) def __repr__(self): s = 'ELF: ' -- cgit v1.2.3