pnp / PnP-Tools

Scripts and tools for Office 365 and SharePoint - More for IT Pro's
MIT License
516 stars 395 forks source link

SharePoint Visio Scanner errors, but regular SharePoint Modernization Scanner runs #326

Open VARenee opened 1 year ago

VARenee commented 1 year ago

Hi, when I run the SharePoint Modernization Scanner from: https://github.com/pnp/modernization/tree/master/Tools/SharePoint.Modernization - it runs just fine.

When I run the Visio Modernization Scanner from: https://github.com/pnp/PnP-Tools/tree/master/Solutions/SharePoint.Visio.Scanner I get the following error:

Please advise.

Unhandled Exception: Microsoft.IdentityModel.Clients.ActiveDirectory.AdalServiceException: AADSTS1002016: You are using TLS version 1.0, 1.1 and/or 3DES cipher which are deprecated to improve the security posture of Azure AD. Your TenantID is: . Please refer to https://go.microsoft.com/fwlink/?linkid=2161187 and conduct needed actions to remediate the issue. For further questions, please contact your administrator. <Removed Trace & Correlation ID> Timestamp: 2022-12-10 00:25:29Z ---> System.Net.WebException: The remote server returned an error: (400) Bad Request. at System.Net.HttpWebRequest.GetResponse() at Microsoft.IdentityModel.Clients.ActiveDirectory.HttpWebRequestWrapper.d2.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.IdentityModel.Clients.ActiveDirectory.HttpHelper.d01.MoveNext() --- End of inner exception stack trace --- at Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationContext.RunAsyncTask[T](Task1 task) at Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationContext.AcquireToken(String resource, ClientAssertionCertificate clientCertificate) at OfficeDevPnP.Core.AuthenticationManager.<>c__DisplayClass36_0.b0(Object sender, WebRequestEventArgs args) at System.EventHandler`1.Invoke(Object sender, TEventArgs e) at Microsoft.SharePoint.Client.ClientRuntimeContext.OnExecutingWebRequest(WebRequestEventArgs args) at Microsoft.SharePoint.Client.ClientContext.GetWebRequestExecutor() at Microsoft.SharePoint.Client.ClientContext.db.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.SharePoint.Client.ClientContext.d8.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.SharePoint.Client.ClientContext.d4.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.SharePoint.Client.ClientContextExtensions.d__7.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.SharePoint.Client.ClientContextExtensions.ExecuteQueryRetry(ClientRuntimeContext clientContext, Int32 retryCount, Int32 delay, String userAgent) at Microsoft.SharePoint.Client.TenantExtensions.GetSiteCollections(Tenant tenant, Int32 startIndex, Int32 endIndex, Boolean includeDetail, Boolean includeOD4BSites) at OfficeDevPnP.Core.Framework.TimerJobs.Utilities.SiteEnumeration.FillSitesViaTenantAPI(Tenant tenant, Boolean excludeOD4B) at OfficeDevPnP.Core.Framework.TimerJobs.Utilities.SiteEnumeration.ResolveSite(Tenant tenant, String siteWildCard, List1 resolvedSites, Boolean excludeOD4B) at OfficeDevPnP.Core.Framework.TimerJobs.TimerJob.ResolveSite(String site, List1 resolvedSites) at OfficeDevPnP.Core.Framework.TimerJobs.TimerJob.ResolveAddedSites(List1 addedSites) at SharePoint.Visio.Scanner.VisioScanJob.ResolveAddedSites(List1 addedSites) at OfficeDevPnP.Core.Framework.TimerJobs.TimerJob.Run() at SharePoint.Scanning.Framework.ScanJob.Execute() in C:\github\BertPnPTools\Solutions\SharePoint.Scanning\SharePoint.Scanning.Framework\ScanJob.cs:line 118 at SharePoint.Visio.Scanner.VisioScanJob.Execute() at SharePoint.Visio.Scanner.Program.Main(String[] args)

Thank you.

codenikhil commented 1 year ago

I am getting the below error continuously could you please help.

Scanning is starting...2/8/2023 7:45:37 PM

.\SharePoint.Visio.Scanner.exe : At line:1 char:1

Unhandled Exception: Microsoft.IdentityModel.SecurityTokenService.RequestFailedException: Token request failed. ---> System.Net.WebException: The remote server returned an error: (401) Unauthorized. at System.Net.HttpWebRequest.GetResponse() at SharePointPnP.IdentityModel.Extensions.S2S.Protocols.OAuth2.OAuth2WebRequest.GetResponse() at SharePointPnP.IdentityModel.Extensions.S2S.Protocols.OAuth2.OAuth2S2SClient.Issue(String securityTokenServiceUrl, OAuth2AccessTokenRequest oauth2Request) --- End of inner exception stack trace --- at SharePointPnP.IdentityModel.Extensions.S2S.Protocols.OAuth2.OAuth2S2SClient.Issue(String securityTokenServiceUrl, OAuth2AccessTokenRequest oauth2Request) at OfficeDevPnP.Core.Utilities.TokenHelper.GetAppOnlyAccessToken(String targetPrincipalName, String targetHost, String targetRealm) at OfficeDevPnP.Core.AuthenticationManager.EnsureToken(String siteUrl, String realm, String appId, String appSecret, String acsHostUrl, String globalEndPointPrefix) at OfficeDevPnP.Core.Framework.TimerJobs.TimerJob.ResolveSite(String site, List1 resolvedSites) at OfficeDevPnP.Core.Framework.TimerJobs.TimerJob.ResolveAddedSites(List1 addedSites) at SharePoint.Visio.Scanner.VisioScanJob.ResolveAddedSites(List`1 addedSites) at OfficeDevPnP.Core.Framework.TimerJobs.TimerJob.Run() at SharePoint.Scanning.Framework.ScanJob.Execute() in C:\github\BertPnPTools\Solutions\SharePoint.Scanning\SharePoint.Scanning.Framework\ScanJob.cs:line 118 at SharePoint.Visio.Scanner.VisioScanJob.Execute() at SharePoint.Visio.Scanner.Program.Main(String[] args)