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

--hex-blob fixes the Invalid Byte Sequence error caused by Wordfence #448

Closed
justinmaurerdotdev opened this issue Jan 23, 2018 · 3 comments

Comments

@justinmaurerdotdev
Copy link

I spent the day today working through some of the Wordmove + Wordfence trickiness and I think I've come up with an elegant solution. Specifically, the issue I ran into is that Wordfence stores some data as binary, so the Wordmove adapter fails when it tries to process the dump, as addressed here.

The modification of the adapter file, as recommended by @byron222 on that page, does seem to work. However, blindly replacing non-compatible characters with an empty string leaves me nervous about what we may removing.

Anyway, adding the --hex-blob flag to mysqldump_options seems to perfectly address the issue. It converts all binary columns to hex code, which is conveniently UTF-8-friendly, thereby avoiding any issues with the adapter. I know that this flag has the potential to create larger dump files, but given that it fixes a known Wordmove bug/issue, I wonder if it would be worth including as part of the default dump settings. If nothing else, I would suggest adding mysqldump_options: --hex-blob as a possible workaround on the wiki page I referenced above.

Hope this helps somebody. Cheers.

p.s. If you're looking for other Wordmove + Wordfence tips, the only other advice I have is to create environment-specific versions of wordfence-waf.php and .user.ini (since they include necessary file paths), then add them to your "exclude" list in your Wordmove Movefile.

@alessandro-fazzi
Copy link
Member

This sounds really really good to me; I need to study a bit the documentation you linked (thanks) because I'm totally unaware of that options. Sure I'll do and I'll give you a feedback.

@alessandro-fazzi
Copy link
Member

Have not tested this approach yet. Sorry but time was badass w/ me last month ;)
Keeping open and in the ❤️

@alessandro-fazzi
Copy link
Member

alessandro-fazzi commented Mar 24, 2018

@360Zen I've just update the wiki with your contrib. Adding a flag is just too easy and supported, so I think it could be the best approach.

Mamny many many thanks!

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

No branches or pull requests

2 participants