BearParser
Portable Executable parsing library (from PE-bear)
Loading...
Searching...
No Matches
SecurityDirWrapper.h
Go to the documentation of this file.
1#pragma once
2
4
5/*
6typedef struct WIN_CERTIFICATE {
7 DWORD dwLength;
8 WORD wRevision;
9 WORD wCertificateType;
10 BYTE bCertificate[];
11} WIN_CERTIFICATE, *LPWIN_CERTIFICATE;
12*/
13
15{
16public:
17
26
28 : DataDirEntryWrapper(pe, pe::DIR_SECURITY), sizeOk(false)
29 {
30 wrap();
31 }
32
33 ~SecurityDirWrapper() { clear(); }
34
35 bool wrap();
36
37 virtual void* getPtr();
38
39 virtual bufsize_t getSize();
40 virtual QString getName() { return "Security"; }
41 virtual size_t getFieldsCount() { return FIELD_COUNTER; }
42 virtual size_t getSubFieldsCount() { return 1; }
43
44 virtual void* getFieldPtr(size_t fieldId, size_t subField);
45 virtual QString getFieldName(size_t fieldId);
46 virtual WrappedValue::data_type containsDataType(size_t fieldId, size_t subField = FIELD_NONE);
47
48 QString translateType(int type);
49 virtual QString translateFieldContent(size_t fieldId);
50
51private:
52 pe::WIN_CERTIFICATE* getCert();
53 void clear() {}
54
55 bool sizeOk;
56};
uint32_t bufsize_t
#define FIELD_NONE
virtual QString translateFieldContent(size_t fieldId)
virtual QString getFieldName(size_t fieldId)
virtual void * getPtr()
virtual size_t getFieldsCount()
SecurityDirWrapper(PEFile *pe)
virtual bufsize_t getSize()
virtual WrappedValue::data_type containsDataType(size_t fieldId, size_t subField=FIELD_NONE)
virtual QString getName()
QString translateType(int type)
virtual size_t getSubFieldsCount()
virtual void * getFieldPtr(size_t fieldId, size_t subField)