When trying to connect to SharePoint, Sharegate displays the following error:
You are not authorized to connect to the SharePoint site. Make sure you have entered the correct user name and password.
|Any error code ending with: -158|
This error can occur in one of the following circumstances:
- The supplied username or password is invalid.
- The user does not have access to the SharePoint site.
- The use of Remote Interfaces is disabled on your SharePoint server.
- The authentication mechanism used by your SharePoint server is not correctly handled by Sharegate.
- Your password has changed.
The first thing to do is to make sure that the supplied user name and password are valid and do give access to the site. You can try them in your browser to make sure of that.
You can then verify if the user of Remote Interfaces is enabled by following this procedure:
- Connect to your SharePoint Central Administration.
- Click on Application Management.
- Click on Manage Web Applications.
- Click on your web application and then on "User Permissions".
- Make sure that "Use Remote Interfaces" is selected.
If none of this works, you can try the different authentication modes in Sharegate (Windows, Manual and Browser).
If your password has changed, you will need to disconnect form your environment and re-connect using your new credentials.