Class NoteAbiTag

java.lang.Object
ghidra.app.util.bin.format.elf.info.ElfNote
ghidra.app.util.bin.format.elf.info.NoteAbiTag
All Implemented Interfaces:
ElfInfoItem

public class NoteAbiTag extends ElfNote
An ELF note that specifies the minimum kernel ABI required by this binary
  • Field Details

  • Constructor Details

    • NoteAbiTag

      public NoteAbiTag(int nameLen, String name, int vendorType, int abiType, int[] requiredKernelVersion)
  • Method Details

    • read

      public static NoteAbiTag read(ElfNote note, Program program) throws IOException
      Deserializes a NoteAbiTag from an already read generic Note.
      Parameters:
      note - generic Note
      program - context
      Returns:
      new NoteAbiTag instance, never null
      Throws:
      IOException - if data error
    • fromProgram

      public static NoteAbiTag fromProgram(Program program)
      Reads a NoteAbiTag from the standard ".note.ABI-tag" section in the specified Program.
      Parameters:
      program - Program to read from
      Returns:
      new instance, or null if not found or data error
    • getAbiType

      public int getAbiType()
    • getAbiTypeString

      public String getAbiTypeString()
    • getRequiredKernelVersion

      public String getRequiredKernelVersion()
    • getNoteValueString

      public String getNoteValueString()
      Description copied from class: ElfNote
      Returns a string representation of this note's 'value', used when creating the PROGRAM_INFO entry.

      Specific Note subclasses should override this to return a better string than this default implementation.

      Overrides:
      getNoteValueString in class ElfNote
      Returns:
      string describing this note's value
    • getNoteTypeName

      public String getNoteTypeName()
      Description copied from class: ElfNote
      Returns a string that describes this note's type, used when creating the default ElfNote.getProgramInfoKey() value.

      Specific Note subclasses can override this to return a better string than this default implementation, or can override the ElfNote.getProgramInfoKey() method.

      Overrides:
      getNoteTypeName in class ElfNote
      Returns:
      descriptive string
    • toStructure

      public StructureDataType toStructure(DataTypeManager dtm)
      Description copied from class: ElfNote
      Returns a Structure datatype that matches the format of this ElfNote, or null if this ElfNote shouldn't be represented/marked up.
      Overrides:
      toStructure in class ElfNote
      Parameters:
      dtm - DataTypeManager that will receive the structure
      Returns:
      StructureDataType that specifies the layout of the ElfNote, or null