Skip to main content

Notifications

Announcements

No record found.

Business Central forum
Suggested answer

Assigning permissions to users with New-NAVServerUserPermissionSet

Posted on by 34

I want to automate the process of assigning permissions in Business Centran Onprem but when I want to assign a permission for example LOGIN get the following error.

New-NAVServerUserPermissionSet : The Aggregate Permission Set does not exist. Identification fields and values: Scope='Tenant',App
ID='{63CA2FA4-4F03-4F2B-A480-172FEF340D3F}',Role ID='LOGIN'

The command I use is as follows.

New-NAVServerUserPermissionSet -ServerInstance BC200 -UserName Desarrollo -AppName "System Application" -PermissionSetId LOGIN -Scope System

Categories:
  • Suggested answer
    Marco Mels Profile Picture
    Marco Mels on at
    RE: Assigning permissions to users with New-NAVServerUserPermissionSet

    Hello,

    Best probably is to make a copy of the system permission set and then run the following command:

    New-NAVServerUserPermissionSet -ServerInstance <<serverinstance>> -Tenant <<tenantname>> -PermissionSetId  <<COPY OF PS>> -Scope Tenant -UserName <<username>>

    You then also have the opportunity to enable "Notify on Change Permission Set" which is helpful if you want to be notified when the original System permission set is changed. Note: This option is only enabled if the related notification is enabled.

    Hope this is an OK workaround for you. If not, please raise it to Microsoft via your partner or CSP so support engineer can ask Product Group what the expected behavior should be. I agree that New-NavUserPermission set is not useful if you can only add one or two permission sets to the user.

    Thank you.

  • Fernando Jose R Profile Picture
    Fernando Jose R 34 on at
    RE: Assigning permissions to users with New-NAVServerUserPermissionSet

    I already found the configuration file, it's true if I change the property you say to false, only the SUPER permission appears, so how can I fix the problem? Why can I assign SUPER, SECURITY and my extensions permissions, but I can't with all others like BASIC and LOGIN?

  • Fernando Jose R Profile Picture
    Fernando Jose R 34 on at
    RE: Assigning permissions to users with New-NAVServerUserPermissionSet

    no, it is not multitenant that I know of, but something strange happens is that if I assign a set of permissions from my own extension if it works, the scope of my extension appears as tenant.

    where is the customsettings.config file located?

  • Suggested answer
    Marco Mels Profile Picture
    Marco Mels on at
    RE: Assigning permissions to users with New-NAVServerUserPermissionSet

    Hello,

    If you set UsePermissionSetsFromExtensions to false in the customsettings.config file and run Get-Get-NavServerPermissionSet  after restarting NST for the changes to take effect, you will see that the only System Permission is SUPER.

    Are you operating from a multi tenant system?

    Thanks.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Anton Venter – Community Spotlight

Kudos to our October Community Star of the month!

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Dynamics 365 Community Newsletter - September 2024

Check out the latest community news

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,532 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,501 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans