Error when Debugging in Visual Studio for the Mac;

2019-08-03 05:32发布

I'm using Visual Studio for the Mac, and I'm receiving the following error message:

http://127.0.0.1:8080/

Application Exception
System.NotImplementedException
SSL encryption for data sent between client and server is not implemented.

Description: HTTP 500.Error processing request.
Details: Non-web exception. Exception origin (name of application or object): System.Data.
Exception stack trace:
  at System.Data.SqlClient.SqlConnection.SetProperties (System.String name, System.String value) [0x00361] in /private/tmp/source-mono-4.8.0/bockbuild-mono-4.8.0-branch/profiles/mono-mac-xamarin/build-root/mono-x86/mcs/class/System.Data/System.Data.SqlClient/SqlConnection.cs:777 
  at System.Data.SqlClient.SqlConnection.SetConnectionString (System.String connectionString) [0x00178] in /private/tmp/source-mono-4.8.0/bockbuild-mono-4.8.0-branch/profiles/mono-mac-xamarin/build-root/mono-x86/mcs/class/System.Data/System.Data.SqlClient/SqlConnection.cs:672 
  at System.Data.SqlClient.SqlConnection.set_ConnectionString (System.String value) [0x00017] in /private/tmp/source-mono-4.8.0/bockbuild-mono-4.8.0-branch/profiles/mono-mac-xamarin/build-root/mono-x86/mcs/class/System.Data/System.Data.SqlClient/SqlConnection.cs:153 
  at System.Data.Entity.Infrastructure.Interception.DbConnectionDispatcher.<SetConnectionString>b__18 (System.Data.Common.DbConnection t, System.Data.Entity.Infrastructure.Interception.DbConnectionPropertyInterceptionContext`1[TValue] c) [0x00007] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Infrastructure.Interception.InternalDispatcher`1[TInterceptor].Dispatch[TTarget,TInterceptionContext] (TTarget target, System.Action`2[T1,T2] operation, TInterceptionContext interceptionContext, System.Action`3[T1,T2,T3] executing, System.Action`3[T1,T2,T3] executed) [0x0000f] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Infrastructure.Interception.DbConnectionDispatcher.SetConnectionString (System.Data.Common.DbConnection connection, System.Data.Entity.Infrastructure.Interception.DbConnectionPropertyInterceptionContext`1[TValue] interceptionContext) [0x00042] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Internal.LazyInternalConnection.InitializeFromConnectionStringSetting (System.Configuration.ConnectionStringSettings appConfigConnection) [0x00062] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Internal.LazyInternalConnection.TryInitializeFromAppConfig (System.String name, System.Data.Entity.Internal.AppConfig config) [0x0000b] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Internal.LazyInternalConnection.Initialize () [0x0005b] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Internal.LazyInternalConnection.get_Connection () [0x00000] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Internal.LazyInternalContext.get_Connection () [0x00024] in <000f54522ad145bf987b3043022f9799>:0 
  at System.Data.Entity.Database.get_Connection () [0x00000] in <000f54522ad145bf987b3043022f9799>:0 
  at Microsoft.AspNet.Identity.EntityFramework.IdentityDbContext`1[TUser].IsIdentityV1Schema (System.Data.Entity.DbContext db) [0x00006] in <be6c0ac8ba754afcbd0c83ce45dc28c2>:0 
  at Microsoft.AspNet.Identity.EntityFramework.IdentityDbContext`1[TUser]..ctor (System.String nameOrConnectionString, System.Boolean throwIfV1Schema) [0x0000a] in <be6c0ac8ba754afcbd0c83ce45dc28c2>:0 
  at Microsoft.AspNet.Identity.EntityFramework.IdentityDbContext`1[TUser]..ctor (System.String nameOrConnectionString) [0x00000] in <be6c0ac8ba754afcbd0c83ce45dc28c2>:0 
  at CardiacTesting.BL.CardiacTestingContext..ctor () [0x00000] in /Users/stecampe1/Desktop/MyFiles/projects/CardiacTestingAlt/CardiacTesting.BL/DataAccess/CardiacTestingContext.cs:15 
  at CardiacTesting.Logic.Repositories.GenericRepository`2[TEntity,TViewModel]..ctor (System.String currentUser) [0x0000f] in /Users/stecampe1/Desktop/MyFiles/projects/CardiacTestingAlt/CardiacTesting/Logic/Repositories/GenericRepository.cs:28 
  at (wrapper managed-to-native) System.Reflection.MonoCMethod:InternalInvoke (System.Reflection.MonoCMethod,object,object[],System.Exception&)
  at System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) [0x00002] in /private/tmp/source-mono-4.8.0/bockbuild-mono-4.8.0-branch/profiles/mono-mac-xamarin/build-root/mono-x86/mcs/class/corlib/System.Reflection/MonoMethod.cs:661 
Version Information: 4.8.0 (mono-4.8.0-branch/8f6d0f6 Thu Mar 9 11:59:17 EST 2017); ASP.NET Version: 4.0.30319.42000
Powered by Mono

I previously had this working. The code is same. Three things changed: My OS was updated from 10.11 to 10.12; Xcode was installed; and, since there are sass files, I used npm start on the files (probably should have confirmed it was working before doing so).

I suspect my connection string is the issue. Here it is:

<connectionStrings>
    <add name="ProjectTestingConnection" connectionString="Server=tcp:testserver.database.windows.net,1433;Initial Catalog=ProjectTesting;Persist Security Info=False;User ID=ProjectTestingWeb;Password=kZ>N4?q>*.;MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=False;Connection Timeout=30;" providerName="System.Data.SqlClient" />
    <!--<add name="ProjectTestingConnection" connectionString="Data Source=10.10.18.159;Initial Catalog=ProjectTesting;User ID=ProjectTestingWeb;Password=pr@jectte$ting" providerName="System.Data.SqlClient" />-->
  </connectionStrings>

I'm trying to view it locally. Again, I had it working 2 days ago. I've tried some of the suggestions in other posts with no success. The last one involved changing the brackets (>) in the password, as it was suggested that could cause a problem - didn't fix anything, so I put it back.

How can I troubleshoot this?

1条回答
我想做一个坏孩纸
2楼-- · 2019-08-03 06:29

You've probably already done this, but did you install HomeBrew and then install ssl. Here is the link https://www.microsoft.com/net/core#macos

查看更多
登录 后发表回答