Sp-dev-docs: Can I use Client secret besides certificates for realizing app-only access for my Azure AD app?

Created on 31 Mar 2019  Â·  5Comments  Â·  Source: SharePoint/sp-dev-docs

I'm not able to access sharepoint online tenant using azure ad app with client secret , i'm getting 401 access denied message. But when i'm trying with certificate i'm able to access the sharepoint tenant using my console app. Need suggestion.


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

add-ins auth csorest answered question

Most helpful comment

The FAQ at the bottom states the following:
"Q: Can I use other means besides certificates for realizing app-only access for my Azure AD app?
A: No, all other options are blocked by SharePoint Online and will result in an Access Denied message."

All 5 comments

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

Can you confirm what auth flow you are using to authenticate with Azure AD to obtain a token and how you are accessing the SharePoint? SharePoint CSOM/REST, Microsoft Graph API, etc?

It sounds like the Azure AD application using the client credentials via the app-only flow but need to confirm...

The FAQ at the bottom states the following:
"Q: Can I use other means besides certificates for realizing app-only access for my Azure AD app?
A: No, all other options are blocked by SharePoint Online and will result in an Access Denied message."

Thanks @andrewconnell :- We use Client grand Auth flow using CSOM classes to obtain token with certificate and without certificate. But we are successfully able to connect with the token provided cetificate only, others giving 401 error.

Issues that have been closed & had no follow-up activity for at least 7 days are automatically locked. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: Issue List: Our approach to locked issues

Was this page helpful?
0 / 5 - 0 ratings