Commit Graph
311 Commits
Author SHA1 Message Date
Mike Auty 4d7701be66 Fix the config printer to sort the values. 2016-08-24 01:13:38 +01:00
Mike Auty 6b47b992a7 Ensure splice requirement perpetuates down the HierarchicalDict. 2016-08-24 01:13:20 +01:00
Mike Auty 341ae950b8 Ensure configurations do not include any generated values (ie TranslationLayer/SymbolLayer names) 2016-08-24 01:12:43 +01:00
Mike Auty 01616af655 Remove comment, it's already been converted. 2016-08-24 01:11:46 +01:00
Mike Auty 546bca1893 Rename the IntelHelper to make it a little more accurate. 2016-08-22 02:28:20 +01:00
Mike Auty 3a07d6810b Add in a reminder for additional work required. 2016-08-22 02:27:13 +01:00
Mike Auty 3dc161f9b4 Rework Translation Layers to tie more closely to configurations
This change is quite signficant, and requires that TranslationLayers
get all additional parameters that they need through their requirements.

These are now automatically enumerated and populated on object
construction based on the requirements, so should not require lots of
repetitive filling out of fields.

It does come with the downside that TranslationLayers can only be
contructed with a context (and appropiate config), but TLs in particular
always require a context (to contain the base layer) and blank configs
can be constructed relatively easily (convenience functions can be added
if necessary).

This allows configuration trees to be built up, and their configs
spliced into an existing config (as if it were being loaded from a
file).

Not all ConstructableRequirements use this method, since SymbolTables
(for example) do not have access to the context or config_path in order
to get to any parameters stored in the context's config.  They therefore
are still passed their requirement values as __init__ parameters
instead.
2016-08-22 02:20:10 +01:00
Mike Auty d3e63fbc1a Rename update_configuration to build_configuration and return a standalone config. 2016-08-22 02:18:23 +01:00
Mike Auty a1b9be74c7 Refactor several configuration/requirement structures to avoid import loops. 2016-08-22 02:15:54 +01:00
Mike Auty eb5e3f69de Ensure we're not importing sub-imports from something else. 2016-08-22 02:01:31 +01:00
Mike Auty c5139ba568 Stop exposing the config_path for now, and fix the version that's passed in the construction phase. 2016-08-22 00:36:58 +01:00
Mike Auty f48ee5ff33 Add in the actual stacking automagic. 2016-08-22 00:06:04 +01:00
Mike Auty 05d3da602f Remove splice as too dangerous (and hopefully unnecessary). 2016-08-22 00:05:05 +01:00
Mike Auty 7648c94083 Add in the intial works at a stacking plugin to emulate volatility 2 address space stacking. 2016-08-22 00:00:21 +01:00
Mike Auty dc16d93b77 Alter the config.path_join function to remove empty sections. 2016-08-21 21:47:45 +01:00
Mike Auty e54505701f Refactor Memory into an interface. 2016-08-21 21:26:21 +01:00
Mike Auty 386e8a34c7 Minor clean-up. 2016-08-21 21:23:29 +01:00
Mike Auty f0cf128bdd Add in the self-referential tests to the standalone component of the windows automagic module. 2016-08-20 16:55:32 +01:00
Mike Auty c38d650819 Add in generic self-referential tests. 2016-08-20 16:54:04 +01:00
Mike Auty 77f295f0a4 Calculate the pointer size, rather than taking it as an argument. 2016-08-20 16:53:36 +01:00
Mike Auty 2467917431 Fix up DTB Finder which was broken in commit eccfb1c2. 5:S 2016-08-20 14:16:02 +01:00
Mike Auty 2bd12b834f Fix minor breakage from the previous reordering of parameters. 2016-08-17 23:25:08 +01:00
Mike Auty 6712d5dee1 Update the automagic uses to ensure a consistent ordering of the arguments. 2016-08-17 20:38:18 +01:00
Mike Auty 0fd0fa0d55 Fix up the comment to match the acceptance of returning objects other than just offsets. 2016-08-17 20:05:23 +01:00
Mike Auty 462295fc4b Ensure lime is properly imported, so that its classes get picked up by the plugin system. 2016-08-16 10:55:27 +01:00
Mike Auty db21d4628c Rework importing of interfaces, a little more verbose in the code, but a little less complex to import and name. 2016-08-16 10:54:57 +01:00
Mike Auty ca61cf10b9 Refactor the context back into the ConfigurableInterface.
This also adds support for manually constructed configurables to
populate the config tree in the current context.

I'm still toying around with this though, I need to figure out
what to do with optional values and think the whole thing through
to make sure it's worthwhile.
2016-08-14 21:28:43 +01:00
Mike Auty ce16d60eaf Add a warning about the dangers of splicing. 2016-08-14 21:27:13 +01:00
Mike Auty 9111f13a8a Get rid of obsolete fulfillment method (now handled by _construct_class in ConstructableRequirementInterface). 2016-08-14 11:44:18 +01:00
Mike Auty 8089a03f81 Convert the private file attribute to a property to allow for cloning. 2016-08-14 01:09:36 +01:00
Mike Auty e02feed16e Python 3 has a sane super() implementation (no arguments), so convert to using that. 2016-08-14 00:55:02 +01:00
Mike Auty 523e159047 Add in convenience functions for working with the configuration and context. 2016-08-14 00:32:22 +01:00
Mike Auty 303ca04a5a Remove the (emtpy) fileformat file in preparation for a dataformat version. 2016-08-14 00:30:25 +01:00
Mike Auty c6b60a0035 Add in more error checking on the automagic routine. 2016-08-14 00:28:20 +01:00
Mike Auty c160698465 Add in comment concerning when the dtb finder fails. 2016-08-01 00:39:49 +01:00
Mike Auty cb1b226bbb Fix an obvious typo. 2016-07-30 18:38:12 +01:00
Mike Auty 8fc925a920 Remove the obsolete generic scan (it was only generic for 64-bit register size). 2016-07-30 18:38:03 +01:00
Mike Auty eccfb1c247 Conver the individual tests to the scanner framework, and work that into the automagic. 2016-07-30 18:20:14 +01:00
Mike Auty 0a0054e30a Make the logging a bit clearer and remove the print statement. 2016-07-30 02:41:26 +01:00
Mike Auty b92ccd771f Fix up the DTB finder code and stick it all together. 2016-07-30 02:35:40 +01:00
Mike Auty 43aba96e3f Minor pylint (alphabetical imports) and refactoring the construct class to work for symbols. 2016-07-30 01:58:29 +01:00
Mike Auty 1c3521cf64 Give construct_layers a forcably low priority, it's important. 2016-07-30 01:54:42 +01:00
Mike Auty 710214fffd Refactor automagics so that the UI can control which ones run. 2016-07-30 01:53:29 +01:00
Mike Auty d3a226d7a8 Remove constraints as a thing, they'll need to come back, but in a different form. 2016-07-30 01:52:44 +01:00
Mike Auty 7661d2ce52 Remove errant debugging statements. 2016-07-30 00:42:46 +01:00
Mike Auty 8db3adae05 Update the scanner interface to return all kind of objects.
This one's slightly contencious, in that scanner now don't all return a
uniform value, and therefore nothing can simply run through scanners.

Worst case scenario we make a separate stricter interface that says it
only returns offsets which will then allow things that need it to
dynamically find them, but it's probably too useful to be able to return
arbitrary objects of a type (as long as the objects returned are always
of that type).
2016-07-30 00:38:53 +01:00
Mike Auty 32b0b073ce Remove unnecessary components after all the refactoring. 2016-07-30 00:37:24 +01:00
Mike Auty f8c3019165 Refactor requirements to expose the name ordering for quicker lookups. 2016-07-29 03:28:02 +01:00
Mike Auty 14c0cc262c Significantly rework the configuration system.
So this is where I ripped out the guts of the dependency tree
and made it a little better defined in some ways, and delayed
populating it in others.  The validate function signature has
changed and I'm still up in the air whether to validate with
True/False or throw/catch exceptions.

So now, configurables have a list of requirements, these are
then bundled into a single requirement and can be passed to
automagic.  Automagic runs a set of things over the deptree
to help build/manage it.  These run in order of priority.

The tree is still built from the top down, but now automagic
can build branch from the bottom up and try and splice them
into the tree where appropriate.  Hopefully this will make it
easier to see follow.
2016-07-29 03:24:52 +01:00
Mike Auty b63f07f493 Rework the imports to make the intel layers easier to read. 2016-07-29 02:57:10 +01:00