Retrieve NextCloud files for Azure AD users

We’re trying to develop an ASP NET Core web API which lets users authenticate through Azure AD and would like to retrieve files from NextCloud on behalf of this Azure AD user. Our infrastructure is composed of an Ubuntu server running NextCloud 12, a Windows Server running the ASP NET Core web API and an Azure Active Directory instance with Azure AD Domain Services. Signing in through NextCloud using LDAP (provided by AAD Domain Services) works without any issues.

We’ve been trying out SSO with SAML in addition to LDAP but we keep seeing this error message when signing into NextCloud:

Account not provisioned.
Your account is not provisioned, access to this service is thus not possible.

How exactly are we able to retrieve files from NextCloud by using the same Azure AD token we receive when authenticating with our ASP NET web API?

1 Like

Hi ginomessmer, we are setting up a somewhat similar application but are having various issues configuring the SSO SAML part as well. It seems as if the corressponding documentation is officially missing at Nextcloud. https://docs.nextcloud.com/server/13/admin_manual/configuration_server/sso_configuration.html

Sadly I can not help you based on your error message. Can you elaborate on your configuration? And if you managed to solve it at the end?

Maybe we can solve this together.

Looking forward to your response.

Best,Enno

All, after many months and headache trying to solve this issue for my company’s Nextcloud instance, I decided to write a guide once I figured out the successful configuration. Below is a link to a step by step guide for configuring the Nextcloud SSO & SAML authentication app for Microsoft’s Azure AD. Hope it is helpful…

1 Like

First, Thanks to @naterussellrpcs for this step by step guide. It’s for me the one and only useful Guide on the web.

Has someone found a way to import the groups from Azure AD assigned to Nextcloud and likes to share the knowledge?
That would be really awesome :blush:

As often as I try, I don’t get rid of the “Application w/ Identifier cannot be found in directory…” error. Any help, please?