You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
Similar to how the INHERIT option controls whether or not thepermissions of the granted role are automatically available to thegrantee, the new SET permission controls whether or not the granteemay use the SET ROLE command to assume the privileges of the grantedrole.In addition, the new SET permission controls whether or not itis possible to transfer ownership of objects to the target roleor to create new objects owned by the target role using commandssuch as CREATE DATABASE .. OWNER. We could alternatively have madethis controlled by the INHERIT option, or allow it when eitheroption is given. An advantage of this approach is that if youare granted a predefined role with INHERIT TRUE, SET FALSE, youcan't go and create objects owned by that role.The underlying theory here is that the ability to create objectsas a target role is not a privilege per se, and thus does notdepend on whether you inherit the target role's privileges. However,it's surely something you could do anyway if you could SET ROLEto the target role, and thus making it contingent on whether youhave that ability is reasonable.Design review by Nathan Bossat, Wolfgang Walther, Jeff Davis,Peter Eisentraut, and Stephen Frost.Discussion:http://postgr.es/m/CA+Tgmob+zDSRS6JXYrgq0NWdzCXuTNzT5eK54Dn2hhgt17nm8A@mail.gmail.com