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

Error with targetversion #17

Open
kafkaesqu3 opened this issue Jul 24, 2019 · 1 comment
Open

Error with targetversion #17

kafkaesqu3 opened this issue Jul 24, 2019 · 1 comment

Comments

@kafkaesqu3
Copy link

kafkaesqu3 commented Jul 24, 2019

I am trying to stomp the macro code to target 32 bit Office 2016 on a Windows 10 64 bit machine.
When I stomp, I use the command -t 2016x86.
My test VM gives me the error "Sub or function not defined", despite the install being the correct target.
I hope you can shed some light on this, let me know if I can provide anything.

EDIT: I think i've figured this out. If you create a document in 64-bit version of word, and then stomp with -t 2016x86, it will give you the error message. You need to create the document with 32 bit version of Word in order to stomp targeting 32 bit. It might be helpful to document this somewhere so other people don't make the same mistake I did.

Thanks for the great tool!

@stanhegt
Copy link
Contributor

Your assumption is correct. This is an undocumented edge case. The _VBA_PROJECT stream (which is crucial for interpretation of P-code) is different between 32 and 64 bit versions of Office. As a result, cross-platform stomping does not work well. I haven't yet been able to figure out what it is exactly that causes this.

I will leave this issue open until it has been properly documented. Thanks for your feedback!

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