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

Force strong passwords from network admin screens #12

Merged
merged 1 commit into from Mar 25, 2015

Conversation

@dpiquet
Copy link
Contributor

commented Mar 25, 2015

Hi,

This PR is a proposal to fix the bug #2

Wordpress capabilities are affected on a per blog basis. Calling user_can from a network admin screen is pointless because there is no blog context, so no caps.

A choice must be made here. Force strong passwords on admin screens, regardless of user capabilities, or cross every blog to check caps. Checking on every blog might cause performance problems or worst (exec time exceed) when fired on very large networks.

In my PR, i chose to simply force strong passwords from network admin screens as only power users can access it and if they chose to use this plugin, they surely want strong passwords to be used.

@dpiquet

This comment has been minimized.

Copy link
Contributor Author

commented Mar 25, 2015

For the record, is_network_admin was introduced in 3.1.0 so it won't change the plugin's compatibilities.

gyrus added a commit that referenced this pull request Mar 25, 2015
Merge pull request #12 from dpiquet/multisite-compat
Force strong passwords from network admin screens

@gyrus gyrus merged commit 97a346e into boogah:master Mar 25, 2015

@gyrus

This comment has been minimized.

Copy link
Collaborator

commented Mar 25, 2015

Many thanks for this. I have no experience with MU, so I'll have to rely on your testing for this. Your reasoning sounds good though. I've merged this, I'll shout out so anyone interested can give it a go, and if there's no negative feedback I'll release it to wordpress.org.

@dpiquet

This comment has been minimized.

Copy link
Contributor Author

commented Mar 25, 2015

Great! Let me know if bugs/problems are found so i can improve the code where needed.

@boogah

This comment has been minimized.

Copy link
Owner

commented Mar 25, 2015

Thanks for the fix @dpiquet! We're going to test this for a few Multisite users who've had problems with the plugin in the past at WP Engine. If we hear of any issues, I'll let you know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.