pnp / pnp/pnpframework

GetOnPremisesRequestDigestInfoAsync doesn't force windows authentication when multiple authentications are enabled

Open
#889 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
259
Forks
161
Avg merge
10h 33m
Merged PRs (30d)
1

Description

Category

  • Bug

Describe the bug

From ConfigureOnPremisesContext, we use "X-FORMS_BASED_AUTH_ACCEPTED"=f header to force windows authentication, however this header is not configured when retrieve the form digest info GetOnPremisesRequestDigestInfoAsync, so the forbidden exception will be returned for the GetOnPremisesRequestDigestInfoAsync method.

Steps to reproduce

Expected behavior

The PowerShell is able to connect the source on-premise environment when multiple authentications are enabled.

Environment details (development & target environment)

  • SDK version: 1.12.2.0
  • OS: Windows
  • SDK used in: [PnP PowerShell]
  • Framework: [.NET Core v6 ]
Additional context

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in src/lib/PnP.Framework/Extensions/ClientContextExtensions.cs at GetOnPremisesRequestDigestInfoAsync and compare it with ConfigureOnPremisesContext in src/lib/PnP.Framework/AuthenticationManager.cs. Reproduce the multiple-authentication SharePoint on-premises scenario using the documented page-conversion test case. Done means the digest request succeeds and PnP PowerShell can connect to the source environment.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, powershell
Domain
authentication, backend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.