2016-11-18 1 views
0

서비스 참조에서 메서드를 사용하려고하면 플러그인에 문제가 있습니다. 그때 내 플러그인에 이러한 매개 변수를 보내는하는 웹 서비스에 매개 변수를 보내는 클라이언트이, 그때 그 매개 변수를 사용하고 웹 참조 방법를 사용하여 웹 서비스로 보내야합니다 . 웹 서비스에 액세스하려면 마지막 웹 서비스를 소유 한 회사가 노래 한 인증서를 사용해야합니다.플러그인에서 웹 서비스로 SSL/TLS 보안 채널을 만들 수 없습니다.

The request was aborted: Could not create SSL/TLS secure channel. 

마지막으로 웹 서비스가 잘 작동하고 내가 동일한 코드를 사용하는 경우 때문에 인증서가 유효 :

BasicHttpsBinding binding = new BasicHttpsBinding 
      { 
       Security = new BasicHttpsSecurity 
       { 
        Transport = new HttpTransportSecurity 
        { 
         ClientCredentialType = HttpClientCredentialType.Certificate 
        } 
       } 
      }; 

UploaderServiceClient client = new UploaderServiceClient(binding, new EndpointAddress(args.EndPoint)); 

client.ClientCredentials.ClientCertificate.SetCertificate(StoreLocation.LocaMachine, StoreName.My, X509FindType.FindBySerialNumber, args.SerialNum); 

client.approveTransportDocument(appC, FileDesc); 

이 코드를 사용 후, 나는 예외를 얻을 : 내가 사용하는 코드는 다음입니다 양식에 잘 작동합니다. 편집 : 나는 어쩌면 도움이 될 것입니다 내가 얻을 예외를 추가 해요 :

System.ServiceModel.Security.SecurityNegotiationException는 : 권한 'IMAS - ws.vmi와 SSL/TLS에 대한 보안 채널을 설정할 수 없습니다 . lt '. ---> System.Net.WebException : 요청이 중단되었습니다. SSL/TLS 보안 채널을 만들지 못했습니다. System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply (시간 범위 시간 초과) 내부 예외 스택 추적 --- 끝에서 System.Net.HttpWebRequest.GetResponse() ---

서버에서 스택 트레이스 : System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebException (WebException이 WebException이, HttpWebRequest를 요청 HttpAbortReason abortReason)
에서 System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply (시간 범위 초과)에서의 System.ServiceModel.Channels.RequestChannel System.ServiceModel.Channels.ServiceChannel.Call (문자열 작용 부울 일방향, ProxyOperationRuntime 동작에 .Request (메시지 메시지 시간 범위의 초과) System.ServiceModel.Dispatcher.RequestChannelBinder.Request에 (메시지 메시지, 타임 아웃 시간 범위)) System.ServiceModel.Channels.ServiceChannelProxy.Invoke (iMessage를 메시지에 System.ServiceModel.Channels.ServiceChannelProxy.InvokeService (IMethodCallMessage methodCall을, ProxyOperationRuntime 동작)에서 [] 인, 개체 [] 아웃, 타임 스팬 타임 아웃) 개체

[0]에서 다시 예외 처리 :,515,System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage Eur_Iz.Ie.UploaderService에서 System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke에서 (iMessage를 reqMsg, iMessage를 retMsg) (MessageData & msgData, INT32 형). U에서 Eur_Iz.Ie.UploaderServiceClient.submitTransportDocument (TransportDocument LocalTransportDocument FileDescription에 ContextInformation, AdditionalContext AdditionalContext)에서 submitTransportDocument (TransportDocument LocalTransportDocument FileDescription에 ContextInformation, AdditionalContext AdditionalContext) : \ DPB \ Plns \ Eur_Iz \ 서비스 즉 \ 참조 \ 참조 .CS : 라인 3295 Eur_Iz.ClientPlugin.DataHandling에서 (IServicePluginArgs의 인수는)

답변

1

은 클라이언트 인증서 또는 서버 인증서 뭔가 될 수 있습니다. 트러스트 문제 (클라이언트 또는 서버에서 누락 된 CA 인증서) 일 수 있습니다.

CAPI2 로그인 이벤트 로그를 사용하면 Could not create SSL/TLS secure channel. CAPI2 로그가 기본적으로 비활성화되어있는 이유를 알 수 있습니다. 사용하도록 설정하면 요청을 다시 시도하십시오. 원인에 대한 유용한 정보가 포함 된 오류 이벤트가 있어야합니다. CAPI2 event log

0

다음 pepos 내가 내 사용자가 아닌 전체 시스템에 대한 신뢰 때문에 인증서 루트가있다 "루트 신뢰할 수없는"나의 인증서 및 루트 인증서 오류를 등록 다시 후 신뢰할 수없는 것을 발견하는 데 도움 고정되었지만 여전히 "SSL/TLS 보안 채널을 만들지 못했습니다"라는 오류가 나타납니다.

관련 문제