Topic on Extension talk:OATHAuth

Syntax for revoking permissions

6
Roy Batty 82 (talkcontribs)

Hi,

What is the correct syntax for $wgOATHExclusiveRights ? I want to revoke sysop right for deleteperm. Should i type something like this ? false or true ? I think adding one example would help users to understand better. :)

$wgOATHExclusiveRight['sysop']['deleteperm'] = false;

Or should i just type : $wgOATHExclusiveRight['sysop']= true;

And will it revoke all sysop rights until they activate 2FA ?

thanks,

158.37.20.201 (talkcontribs)

I'm wondering about the same, nothing seems to work. I dug into CheckExclusiveRights.php and i'm still confused.

MLWatts (talkcontribs)

You should list the permissions you want to restrict in the array:

$wgOATHExclusiveRights = ['edit', 'move'];

I don't think you can take a permission away from a specific group. If you want to take the "delete" permission away from sysops unless they log in with 2FA, it will be simply:

$wgOATHExclusiveRights = ['delete'];

and then only those who logged in with 2FA will be able to delete pages, as long as their user group allows for that. Hope this is helpful!

68.13.205.48 (talkcontribs)

What if I wanted to force 2FA for all logins? Could I take away ALL permissions? Something like this...


$wgOATHExclusiveRights = ['*'];

91.218.216.4 (talkcontribs)

it seems doesnt work "up"

12.205.176.1 (talkcontribs)

Have you tried taking away the 'read' right?

Reply to "Syntax for revoking permissions"