Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] .reg as backend to Registry #43

Open
NiKiZe opened this issue Feb 4, 2015 · 2 comments
Open

[Feature Request] .reg as backend to Registry #43

NiKiZe opened this issue Feb 4, 2015 · 2 comments

Comments

@NiKiZe
Copy link
Contributor

NiKiZe commented Feb 4, 2015

As mentioned by @williballenthin in #39

developing a second backend to python-registry that operates over .reg files. So it exposes the familiar RegistryKey/RegistryValue interface, but the underlying data comes from a .reg export.

(For reference this is kind of the inverse of #4)

I think it is worth having a separate issue open for this. (no hurry just wanted it documented)
At least it can be used to discuss how this could be implemented to best fit in the project.

The best I can come up with right now is a separate module that Registry imports, and uses depending on the contents of the file?

@williballenthin
Copy link
Owner

I think almost all the work would be in a file analogous to RegistryParse.py. Registry.py should be made more generic, where really all it does is define the RegistryKey, RegistryValue, and Registry interfaces, and an entrypoint into file parsing (which as you said, might look at the file header, and pick an appropriate backend).

@williballenthin
Copy link
Owner

Let me suggest a course of action, get your feedback, and we can agree on a plan of action (whenever this takes place :-) ).

  • move RegistryParse.py to RegistryParseREGF.py
  • cleanup Registry.py classes to simply be interfaces
    • Registry
    • RegistryValue
    • RegistryKey
  • implement Registry* interfaces for REGF parser in RegistryParseREGF.py
  • in Registry.py, during open, check file header, and delegate to RegistryParseREGF.py, or raise unsupported exception
  • implement RegistryParseReg.py, including
    • possibly low-level structures (sorta like nk/vk/sk records, if necessary, which I don't think it will be)
    • high-level interfaces declared in Registry.py
  • in Registry.py, add possible delegation to RegistryParseReg.py based on file header

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants