Skip to main content

SharePoint Provider Hosted App throwing 401 Unauthorized on newly created Office 365 tenants

I was working on some new tenant with the clients. There we had some requirement to create new SharePoint Provider Hosted App with App-Only principals. It was created successfully & working fine in my older tenant. 

After testing of it, I deployed on newly created tenant where it has started showing issues :



I have registered a support ticket to Microsoft SharePoint team . They tried to support with lots of meetings & collected logs but they have not given the solution.

After did lots of research , I found the solution from Microsoft Q & A site. Lots of SharePoint experts are facing same issue. They have mentioned some workaround as well.

They are asking to run a command :

Set-SPOTenant -DisableCustomAppAuthentication $false

After running this command, every thing has started working. 

Just one thing, You have to use latest SharePoint Online Management Shell.


Comments

Popular posts from this blog

Export / Import from Excel file in SharePoint

SharePoint Web Part - Export or Import from Excel Here is the tool which will help you to import excel file into a list. This tool will not create any kind of list or column. It will help users to import their excel file in specific list. This tool also allows users to update existing records directly from excel file. I have develop the tool in SharePoint Framework. Currently this tool is for SharePoint Online version only. We are supporting following columns : Single line of text Multiple lines of text Number Yes/No Person or Group (Person + Group) Person or Group (Person + Group) (Allow multiple selections) Date and Time Choice Choice (Allow multiple selections) Hyperlink or Picture Currency Managed Metadata Managed Metadata (Allow multiple values) Lookup Lookup (Allow multiple values) Installation of App :- 1. Click here to download the sps-import-from-excel.sppkg . 2. Visit the Microsoft 365 SharePoint Admin Center 3. Go to Apps -> App Catalog. If you don't have ap...

Not able to load Sharepoint online PowerShell module after installation

I did installation of SharePoint Online PowerShell Module but it was throwing error when I was using it : Error Detail: [PS] C:\Windows\system32>Import-Module Microsoft.Online.SharePoint.PowerShell -DisableNameChecking Import-Module : Could not load type 'Microsoft.Online.SharePoint.TenantAdministration.SPOTenantCdnType' from assembly 'Microsoft.Online.SharePoint.Client.Tenant, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c'. At line:1 char:1 + Import-Module Microsoft.Online.SharePoint.PowerShell -DisableNameChec ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     + CategoryInfo          : NotSpecified: (:) [Import-Module], TypeLoadException     + FullyQualifiedErrorId : System.TypeLoadException,Microsoft.PowerShell.Commands.ImportModuleCommand I verified that the module is installed: [PS] C:\Windows\system32>Get-Module -ListAvailable -Name "Microsoft.Online.SharePoint.PowerShell" | ft ver...

Get all default task lists from Microsoft To Do with Microsoft Graph APIs

Hi, I was working on to get all tasks from Microsoft To Do lists.  The documentation does not say about it. But I figured out a way to get all task lists from Microsoft To Do. Here is the way : POST /me/todo/lists/Tasks/tasks POST /users/{id|userPrincipalName}/todo/lists/Tasks/tasks GET /me/todo/lists/Tasks/tasks GET /users/{id|userPrincipalName}/todo/lists/Tasks/tasks 😃