AzureDevops branch permissions settings - azure-devops

I have checked the docs from Microsoft for AzureDevops and I understand how to manage permissions for a branch.
What I would like to know is if a user is automatically added with Edit Policies permission to Allow as he creates the branch (assuming a normal user not admin, and he's not inheriting this permission) ?
If the answer to the above question is yes, then is there any case when a second user could be added to the list of branch permissions automatically ? without an administrator adding it explicitly ? I couldn't find this in the docs anywhere.
*picture from msdn

Yes, for each branch's permission setting, you could directly manage that user's or create a group then add that consultancy in the group, manage the group's permission.
In other words, without adding it explicitly, the user B could also be added to a group.
You just need to make sure that you are not part of any groups that have the complete privilege Denied.
In Azure DevOps, Deny trumps Allow.
Unless you're a member of the Project Collection Administrators group on your organization, membership in a group that explicitly Denies any permission will deny your permission, even if you are in another group that explicitly Allows you the permission and even if you as an individual user are granted Allow on that permission.
We usually add developer to Contributors.
For the Inheritance part, you could turn on your inheritance and clear explicit with single click for each branch which have explicit permissions.
After this, Contributors Group in other branches will totally inherit the permissions set by root path of your repo/workspace. For example, if root path are Allow, your branches should be Allow(inherited), if it's Deny, your branches should be Deny(inherited).
If a permission isn't directly allowed or denied for a user, then it may be inherited in two ways.
Users inherit permissions from the groups to which they belong. When
a permission is allowed for a user directly or through membership in
a group that has that permission, and it is denied, either directly
or through group membership, the permission is denied.
Members of Project Collection Administrators or **Team Foundation
Administrators** retain any allowed permissions, even if they belong to
other groups that deny those permissions.
Object-level permissions that are assigned for nodes of a hierarchy -
areas, iterations, version control folders, work item query folders -
are inherited down the hierarchy. That is, a user's permissions that
are set at area-1 are inherited by area-1/sub-area-1, if the same
permission is not explicitly allowed or denied for area-1/sub-area-1.
If a permission is set explicitly for an object, like
area-1/sub-area-1, then the parent node is not inherited, regardless
of whether it is denied or allowed. If it's not set, then the
permissions for that node are inherited from the closest ancestor
that has the permission explicitly set.
More details please take a look at our official tutorial here: Inheritance and security groups

Related

Missing access to cross-repo policies or project-wide branch policies in Azure DevOps

After the latest update including the cross-repo policies in the Azure DevOps portal, I can't add project-wide branch protections even though I am the Organization and Project owner.
Is there any special permissions that is required to be assigned to my user?
Thanks,
VĂ­
Solution:
Leave all security groups except "Project Administrators"
Is there any special permissions that is required to be assigned to my user?
You should check your user's access level, if they are Stakeholder levels, then they will not have the permissions to add project-wide branch protections.
If set my user as Stakeholder levels on the Organization Settings->Users:
Then, my user will get the states: Yo do not have permission to edict project-wide branch policies:
So, to resolve this issue, you should to assign a higher access level to your users, like Basic.
Hope this helps.
I solved the Problem by leaving all groups, except the "Project Administrators" group.
This was based on #ViMans comment.
Quote:
I have realized the problem was related with a user belonging to
different groups with different access level. E.g: An organization
administrator belonging to the contributor group it will keep the most
restrictive access level based in a least privilege philosophy

Azure Devops - Cannot restrict Library view permissions

I need to give someone access to create work items ONLY. They are a 'stakeholder' user. Currently I cannot restrict them from seeing Variable groups OR Task Groups. I cannot see any deny permmisions and the person is in no other groups. I added them to an organization group with DENY permissions in all 4 Pipelines permissions. Still the user can see them
I added them to an organization group with DENY permissions in all 4
Pipelines permissions. Still the user can see them
That's caused by that the permission listed here used to restrict the build view, such as build definition and etc. But, Variable group and Tasks group does not belong to build, they just be linked/called into the build. Set the View build resources as deny could not restrict these objects' permission. For example, Azure Key Vault's view permission could not be restricted by deny the permission of build. It just can be changed in Azure portal.
These function( such as variable group, task group, key vault and etc) which be linked/called into build called object. To modify its permission, you must go objects' security page to change it.
Since what you are focusing is Variable group and Task group, unfortunately, viewing these objects belong the basic permission of Stackholder and could not be restricted in security configuration.
As you can see that there's no permission to restrict View. So, restrict stackhokders view it could not be achieve.
For security, I think you can change their level as Project reader to restrict them do change to them.

Viewing permissions in Atlassian Stash

I wonder if there is a way for an ordinary user to view the list of user permissions for a given repository in Atlassian Stash. Specifically I'm interested in who has permission to push commits to a repository.
The stuff I've been able to find seems to be about establishing permissions, for use by project administrators.
There are only 3 types of permissions - admin, write and read. Only admins can see and edit the settings (which include permissions).

Assign Access to Multiple Sites in Sitecore 7.5

I have a small question related to granting access to multiple sites in Sitecore 7.5.
Let's say I have a website named as website_1 and another website named as website_2 in my Sitecore environment. Now I have created two roles. One role named as r_website_1 gives access to website_1 and another role r_website_2 gives access to website_2.
In r_website_1, only access to website_1 is granted and access to website_2 is denied. The same goes for r_website_2 but for
website_2.
Now I want to give read and write access to user_1 for both websites. What I did was went to User Manager>user_1>Edit>Member Of and then assigned both roles.
What I noticed that the user_1 only gets access to one website. it seems that both roles are countering each another. For example, the denied permission for website_2 in r_website_1 is conflicting with allowed permission for website_2 in r_website_2.
May I know what's the fix for this problem?
Thanks in advance,
Vaibhav
Deny permission always has priority. You cannot remove by simply adding another role with allow access rights.
Instead of using deny you should break the inheritance of chosen access right for the role1 for site2 and similarly for the role2 for site1.
Here is a quote from Sitecore Administrator Security Cookbook:
We recommend that you use inheritance whenever possible to limit the access that roles have to the items in Sitecore. Using inheritance instead of directly denying access rights to items makes it easier to manage the security system.
And you can read about breaking inheritance of access rights in Assign access rights to a security account document.

Relationships and References in Mongo DB

I am currently working on a project in which there are many threads that users can create. User's have different permissions for the threads that can be specified by users with admin permission. User's need to be added to the thread before they have access to it.
When a user is added to the thread, they are given either read, write or admin permission. Users can also be part of groups. These groups can then be added to a thread in which case, all users in the group will be added along with the permission that is specified for the group.
thread: {id: xxxxx, users:[{id:user01, permission: write, discovery: non}, {id:user02, permission: read, discovery: GroupA}]}
So a user can be added with an individual permission or they can be added with permission given to the group they are a part of. Discovery would specify whether the user was added individually or as a group.
I am wondering if this would be the best method of setting up Mongo for this sort of permission system and also how I would actually define this schema using Mongoose? I think that it would be fastest to have all these aspects embedded into each thread.