38 this->invalidEntries = 0;
56 if (
entry->isValid()) {
61 this->invalidEntries++;
65 this->parsedSize +=
val;
90 this->invalidEntries = 0;
93 if (!reloc)
return false;
97 size_t maxSize = reloc->SizeOfBlock;
103 if (!
entry->getPtr()) {
107 if (
entry->isValid()) {
112 this->invalidEntries++;
116 this->parsedSize +=
sizeof(pe::BASE_RELOCATION_ENTRY);
117 this->
entries.push_back(entry);
125 if (this->parentDir ==
NULL)
return NULL;
127 if (!reloc)
return NULL;
152 this->cachedRaw =
raw;
168 if (!ptr)
return NULL;
174 this->cachedRaw =
raw;
180 if (this->parentDir ==
NULL)
return 0;
182 if (!reloc)
return 0;
184 if (reloc->SizeOfBlock > 0)
return reloc->SizeOfBlock;
192 if (!reloc)
return NULL;
195 case PAGE_VA:
return (
void*) &reloc->VirtualAddress;
196 case BLOCK_SIZE :
return (
void*) &reloc->SizeOfBlock;
210 case PAGE_VA:
return "Page RVA";
248 if (this->cachedMaxNum > 0)
return this->cachedMaxNum;
251 if (!reloc)
return 0;
273 if (!
getPtr())
return false;
277 if (!
isOk)
return false;
288 if (this->parentDir ==
NULL)
return NULL;
302 if (this->parentDir ==
NULL)
return 0;
315 return entry->Offset;
321 case 0 :
return "Padding (skipped)";
322 case 1 :
return "High WORD of 32-bit field";
323 case 2 :
return "Low WORD of 32-bit field";
324 case 3 :
return "32 bit field";
325 case 4 :
return "HighAdj";
326 case 5 :
return "MIPS JumpAddr";
327 case 6 :
case 7 :
return "Reserved";
328 case 9 :
return "MIPS16 JumpAddr";
329 case 10 :
return "64 bit field";
INT_TYPE _getNumValue(void *ptr)
const offset_t INVALID_ADDR
bufsize_t getDirEntrySize(bool trimToExeSize=false)
offset_t getDirEntryAddress()
virtual bufsize_t getFieldSize(size_t fieldId, size_t subField=FIELD_NONE)
virtual offset_t getFieldOffset(size_t fieldId, size_t subField=FIELD_NONE)
virtual offset_t getOffset()
virtual uint64_t getNumValue(size_t fieldId, size_t subField, bool *isOk)
virtual ExeNodeWrapper * getEntryAt(size_t fieldId)
std::vector< ExeNodeWrapper * > entries
BYTE * getContentAt(offset_t offset, bufsize_t size, bool allowExceptions=false)
virtual offset_t getRawSize() const
virtual QString getFieldName(size_t fieldId)
virtual WrappedValue::data_type containsDataType(size_t fieldId, size_t subField)
virtual void * getFieldPtr(size_t fieldId, size_t subField=FIELD_NONE)
virtual QString getName()
virtual bufsize_t getSize()
size_t maxEntriesNumInBlock()
virtual Executable::addr_type containsAddrType(size_t fieldId, size_t subField)
IMAGE_BASE_RELOCATION * myReloc()
friend class RelocBlockWrapper
IMAGE_BASE_RELOCATION * reloc()
offset_t deltaToRVA(WORD delta)
static QString translateType(WORD type)
virtual bufsize_t getSize()
static WORD getDelta(WORD relocEntryVal)
static WORD getType(WORD relocEntryVal)