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

gomvpkg does not support move destinations whose base names are not valid go identifiers #22

Open
mesameen opened this issue Aug 2, 2019 · 3 comments

Comments

@mesameen
Copy link

mesameen commented Aug 2, 2019

GOPATH: E:\go\src
My Application: E:\go\src\HelloWorld
Working Directory: E:\go\src\

E:\go\src:> go get -u github.com/unixpickle/gobfuscate
E:\go\src:> gobfuscate obfus /ob

2019/08/02 22:07:09 Copying GOPATH... 2019/08/02 22:07:36 Obfuscating package names... Failed to obfuscate package names: package move: invalid move destination: aagdegjpdjopofdlagpg\opfcoehbinlaindbngkp; gomvpkg does not support move destinations whose base names are not valid go identifiers

Couldn't get what's wrong.

@kumpfdp
Copy link

kumpfdp commented Aug 6, 2019

I had this same issue on Windows and seems to be due to the os path separators. It appears you're also on Windows but, correct me if I'm wrong in that assumption. I've had no issues running this tool on a mac, fwiw...

I stepped through the code as it was running and after replacing "\" with "/" in the to/from file paths, it works. Note, there is another place where this is required to get it fully working - during the rename symbols section.

In path\path.go (which is being used in this case), the path.Base func doesn't check for os.Separator. It only checks for "/". Thinking this is because of Go's import paths use unix-style path separators? filepath\path.go checks for the os.Separator.

Hope that helps.

@discoli-zz
Copy link

hi - did anyone ever resolve this, i'm not fully sure what to do with the information above

@Numenorean
Copy link

any solution for this?

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

5 participants
@kumpfdp @mesameen @discoli-zz @Numenorean and others