You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
write wcf client test code for service mentioned in step1, provide correct user name, but transport certificate in machine A is not trusted by machine B
run wcf test client project, observe the exception
Expected behavior
Similar as .NetFramework project, should throw exception with the actual error message:
System.ServiceModel.Security.SecurityNegotiationException
HResult=0x80131501
Message=The X.509 certificate CN=xxx, O=xxx, OU=Created by https://github.com/dotnet/wcf chain building failed. The certificate that was used has a trust chain that cannot be verified. Replace the certificate or change the certificateValidationMode. A certificate chain could not be built to a trusted root authority.
Actual error
System.Diagnostics.Tracing.EventSourceException
HResult=0x80131500
Message=The payload for a single event is too large.
Source=System.Private.CoreLib
StackTrace:
at System.Diagnostics.Tracing.EventSource.ThrowEventSourceException(String eventName, Exception innerEx)
at System.Diagnostics.Tracing.EventSource.WriteEventVarargs(Int32 eventId, Guid* childActivityID, Object[] args)
at System.Diagnostics.Tracing.EventSource.WriteEvent(Int32 eventId, Object[] args)
at System.Runtime.WcfEventSource.ThrowingException(String data1, String data2, String SerializedException, String AppDomain) in //src/System.Private.ServiceModel/src/Internals/WcfEventSource.cs:line 2040
at System.Runtime.WcfEventSource.ThrowingException(String data1, String data2, String SerializedException) in //src/System.Private.ServiceModel/src/Internals/WcfEventSource.cs:line 2046
at System.Runtime.TraceCore.ThrowingException(EtwDiagnosticTrace trace, String param0, String param1, Exception exception) in //src/System.Private.ServiceModel/src/Internals/TraceCore.cs:line 114
at System.Runtime.ExceptionTrace.TraceException[TException](TException exception, String eventSource) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/ExceptionTrace.cs:line 236
at System.Runtime.ExceptionTrace.TraceException[TException](TException exception) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/ExceptionTrace.cs:line 228
at System.Runtime.ExceptionTrace.AsError(Exception exception) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/ExceptionTrace.cs:line 43
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/AsyncResult.cs:line 351
at System.ServiceModel.Channels.ServiceChannel.SendAsyncResult.End(SendAsyncResult result) in //src/System.Private.ServiceModel/src/System/ServiceModel/Channels/ServiceChannel.cs:line 1909
at System.ServiceModel.Channels.ServiceChannel.EndCall(String action, Object[] outs, IAsyncResult result) in //src/System.Private.ServiceModel/src/System/ServiceModel/Channels/ServiceChannel.cs:line 806
at System.ServiceModel.Channels.ServiceChannelProxy.TaskCreator.<>c__DisplayClass1_0.b__0(IAsyncResult asyncResult) in //src/System.Private.ServiceModel/src/System/ServiceModel/Channels/ServiceChannelProxy.cs:line 184
--- End of stack trace from previous location ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at TransportWithMsgCredentialClient.Program.TestClient() in E:\test\TransportWithMsgCredentialClient\Program.cs:line 35
at TransportWithMsgCredentialClient.Program.Main(String[] args) in E:\test\TransportWithMsgCredentialClient\Program.cs:line 16
This exception was originally thrown at this call stack:
System.Diagnostics.Tracing.EventSource.ThrowEventSourceException(string, System.Exception)
System.Diagnostics.Tracing.EventSource.WriteEventVarargs(int, System.Guid*, object[])
System.Diagnostics.Tracing.EventSource.WriteEvent(int, object[])
System.Runtime.WcfEventSource.ThrowingException(string, string, string, string) in WcfEventSource.cs
System.Runtime.WcfEventSource.ThrowingException(string, string, string) in WcfEventSource.cs
System.Runtime.TraceCore.ThrowingException(System.Runtime.Diagnostics.EtwDiagnosticTrace, string, string, System.Exception) in TraceCore.cs
System.Runtime.ExceptionTrace.TraceException(TException, string) in ExceptionTrace.cs
System.Runtime.ExceptionTrace.TraceException(TException) in ExceptionTrace.cs
System.Runtime.ExceptionTrace.AsError(System.Exception) in ExceptionTrace.cs
System.Runtime.AsyncResult.End(System.IAsyncResult) in AsyncResult.cs
...
[Call Stack Truncated]
The text was updated successfully, but these errors were encountered:
Describe the bug
"EventSourceException:The payload for a single event is too large" instead of the actual exception thrown from .net core wcf client
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Similar as .NetFramework project, should throw exception with the actual error message:
System.ServiceModel.Security.SecurityNegotiationException
HResult=0x80131501
Message=The X.509 certificate CN=xxx, O=xxx, OU=Created by https://github.com/dotnet/wcf chain building failed. The certificate that was used has a trust chain that cannot be verified. Replace the certificate or change the certificateValidationMode. A certificate chain could not be built to a trusted root authority.
Actual error
System.Diagnostics.Tracing.EventSourceException
HResult=0x80131500
Message=The payload for a single event is too large.
Source=System.Private.CoreLib
StackTrace:
at System.Diagnostics.Tracing.EventSource.ThrowEventSourceException(String eventName, Exception innerEx)
at System.Diagnostics.Tracing.EventSource.WriteEventVarargs(Int32 eventId, Guid* childActivityID, Object[] args)
at System.Diagnostics.Tracing.EventSource.WriteEvent(Int32 eventId, Object[] args)
at System.Runtime.WcfEventSource.ThrowingException(String data1, String data2, String SerializedException, String AppDomain) in //src/System.Private.ServiceModel/src/Internals/WcfEventSource.cs:line 2040
at System.Runtime.WcfEventSource.ThrowingException(String data1, String data2, String SerializedException) in //src/System.Private.ServiceModel/src/Internals/WcfEventSource.cs:line 2046
at System.Runtime.TraceCore.ThrowingException(EtwDiagnosticTrace trace, String param0, String param1, Exception exception) in //src/System.Private.ServiceModel/src/Internals/TraceCore.cs:line 114
at System.Runtime.ExceptionTrace.TraceException[TException](TException exception, String eventSource) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/ExceptionTrace.cs:line 236
at System.Runtime.ExceptionTrace.TraceException[TException](TException exception) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/ExceptionTrace.cs:line 228
at System.Runtime.ExceptionTrace.AsError(Exception exception) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/ExceptionTrace.cs:line 43
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result) in //src/System.Private.ServiceModel/src/Internals/System/Runtime/AsyncResult.cs:line 351
at System.ServiceModel.Channels.ServiceChannel.SendAsyncResult.End(SendAsyncResult result) in //src/System.Private.ServiceModel/src/System/ServiceModel/Channels/ServiceChannel.cs:line 1909
at System.ServiceModel.Channels.ServiceChannel.EndCall(String action, Object[] outs, IAsyncResult result) in //src/System.Private.ServiceModel/src/System/ServiceModel/Channels/ServiceChannel.cs:line 806
at System.ServiceModel.Channels.ServiceChannelProxy.TaskCreator.<>c__DisplayClass1_0.b__0(IAsyncResult asyncResult) in //src/System.Private.ServiceModel/src/System/ServiceModel/Channels/ServiceChannelProxy.cs:line 184
--- End of stack trace from previous location ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at TransportWithMsgCredentialClient.Program.TestClient() in E:\test\TransportWithMsgCredentialClient\Program.cs:line 35
at TransportWithMsgCredentialClient.Program.Main(String[] args) in E:\test\TransportWithMsgCredentialClient\Program.cs:line 16
This exception was originally thrown at this call stack:
System.Diagnostics.Tracing.EventSource.ThrowEventSourceException(string, System.Exception)
System.Diagnostics.Tracing.EventSource.WriteEventVarargs(int, System.Guid*, object[])
System.Diagnostics.Tracing.EventSource.WriteEvent(int, object[])
System.Runtime.WcfEventSource.ThrowingException(string, string, string, string) in WcfEventSource.cs
System.Runtime.WcfEventSource.ThrowingException(string, string, string) in WcfEventSource.cs
System.Runtime.TraceCore.ThrowingException(System.Runtime.Diagnostics.EtwDiagnosticTrace, string, string, System.Exception) in TraceCore.cs
System.Runtime.ExceptionTrace.TraceException(TException, string) in ExceptionTrace.cs
System.Runtime.ExceptionTrace.TraceException(TException) in ExceptionTrace.cs
System.Runtime.ExceptionTrace.AsError(System.Exception) in ExceptionTrace.cs
System.Runtime.AsyncResult.End(System.IAsyncResult) in AsyncResult.cs
...
[Call Stack Truncated]
The text was updated successfully, but these errors were encountered: