I seem to be regularly running into problems with file permissions running on WordPress. The two specific examples are that image browsing and upload didn't work in KCEditor (due to permissions for KCFinder) and the tracked links in bulk mailings were failing. In both cases I got 500 errors from the browser. I found that I needed to change directory permissions to 755 from 775 and file permissions from 664 to 664 in appropriate places. It seems rather random whether directory/file permissions are 775/664 or 755/644.
I think this is due to the way my hosting provider sets up WordPress and does not allow 775/664 permissions and from what I read this will be a common situation with hosting providers that use suexec.
Changing file permissions manually is a work around, but tedious and unreliable. I may be missing some and things not working properly because of this, but not being so obvious. And when it comes to an upgrade I'll have to go through it all again.
Is there a reason why the WordPress CiviCRM is distributed with these file permissions? Is there a reason for the variation in file permissions (and what is the logic)?
If this can't be changed in the distribution, can I safely change all 775 to 755 and all 664 to 644 and how might I do this?
I don't think the versions are relevant, but this applies to CiviCRM 4.7.24 and WordPress 4.9 and also other recent versions earlier this year. The hosting provider is SiteGround.