-
Notifications
You must be signed in to change notification settings - Fork 1
Description
Since multiple arches need to be parsed, we need a way to tell if ei_data has a valid value and that it matches the expected value for the arch in e_machine.
For that there is right now a big table- this can be simplified by first marking all little- and bi-endian arches and then deleting all big-endian entries.
This would result in treating all e_machine values that are not in the table as big endian, however since most arches are big endian this shouldn't cause that many problems.
After all that we need to do is, read e_machine, compare the ei_data value with the expected value and if they match we continue execution and set a variable to 1 if we are on big endian
later in code before printing we need to check the IsBigEndian value and if its set we need to convert the value to little endian (if needed)