1

I have configured FBA to work with SP 2016

I am looking at adding the roles defined in the SQL DB

The result should mean i get something like below added to SP

c:0-.f|FbaRoleManager|[groupname]

Does anyone know how can i add roles based on SQL FBA db hopefully via PowerShell

I currently get an error "The specified user cannot be found"

1

Make sure you have created a custom Role Provider for our SharePoint environment, which allows you to specify SharePoint roles and assign them to custom users.

The “Adding SQL users and roles for FBA” part cannot be completed using PowerShell.

Here are some articles you can refer to for this process:

  1. Step by Step – Configure SharePoint 2010 Forms Based Authentication with SQL.
  2. What configuration can be done using PowerShell: SharePoint Form-Based Authentication with SQL using PowerShell.
  3. Another one with video tutorial: Configuring Forms Based Authentication in SharePoint 2016 and SharePoint 2019 – Part 4 – Adding Users to the Membership Database.
| improve this answer | |
1

This can be done using PnP PowerShell

Just not using using New-SPUser

The cmdlet that works is as below

New-PnPUser -LoginName "c:0-.f|FbaRoleManager|[groupname"

| improve this answer | |
  • Thanks for the clarification. Can you share the cmdlet for this action? – Chelsea_MSFT Aug 21 at 1:11
  • Updated answer above – user3799810 Aug 22 at 3:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.