diff --git a/BurnOutSharp.Wrappers/PortableExecutable.cs b/BurnOutSharp.Wrappers/PortableExecutable.cs
index cf9bf32e..6c5079d3 100644
--- a/BurnOutSharp.Wrappers/PortableExecutable.cs
+++ b/BurnOutSharp.Wrappers/PortableExecutable.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.IO;
+using System.Linq;
using System.Text;
using System.Xml;
using static BurnOutSharp.Builder.Extensions;
@@ -301,16 +302,22 @@ namespace BurnOutSharp.Wrappers
///
public Models.PortableExecutable.ExportTable ExportTable => _executable.ExportTable;
+ ///
+ public string[] ExportNameTable => _executable.ExportTable?.ExportNameTable?.Strings;
+
///
public Models.PortableExecutable.ImportTable ImportTable => _executable.ImportTable;
+ ///
+ public string[] ImportHintNameTable => _executable.ImportTable?.HintNameTable != null
+ ? _executable.ImportTable.HintNameTable.Select(entry => entry.Name).ToArray()
+ : null;
+
///
public Models.PortableExecutable.ResourceDirectoryTable ResourceDirectoryTable => _executable.ResourceDirectoryTable;
#endregion
- // TODO: Determine what properties can be passed through
-
#endregion
#region Extension Properties
@@ -364,6 +371,152 @@ namespace BurnOutSharp.Wrappers
}
}
+ ///
+ /// Dictionary of resource data
+ ///
+ public Dictionary ResourceData
+ {
+ get
+ {
+ lock (_resourceDataLock)
+ {
+ // Use the cached data if possible
+ if (_resourceData != null)
+ return _resourceData;
+
+ // If we have no resource table, just return
+ if (_executable.OptionalHeader?.ResourceTable == null
+ || _executable.OptionalHeader.ResourceTable.VirtualAddress == 0
+ || _executable.ResourceDirectoryTable == null)
+ return null;
+
+ // Otherwise, build and return the cached dictionary
+ ParseResourceDirectoryTable(_executable.ResourceDirectoryTable, types: new List