I am trying to run the sample code for UCMA 3.0 SDK title InstantMessageCall, but I get the following error Unable to perform authentication of credentials.
The two methods supported are Ntlm and Kerberos, and I see that my endpoint has Mtls as protocol. Are these related? I also followed some instructions on creating a certificate for the trusted application pool in order to communicate with the FE server but I do not know how to verify.
I have an application that does however work with presence so the endpoint seems to successfully establish connections. It seems that the IM is what fails.
Application Output :
Creating User Endpoint for IMCall Sample User...
Please enter the FQDN of the Microsoft Lync Server that the IMCall Sample User endpoint is homed on => front_end_pool.myCompany.com
Please enter the User Name for IMCall Sample User (or hit the ENTER key to use current credentials)
Please enter the User Name => myUser
Enter the User Password for IMCall Sample User => myPassword
Please enter the User Domain for IMCall Sample User => myCompany.com
Please enter the User URI for IMCall Sample User in the
User@Host format => myUser@myCompany.com
Platform started...
Unable to perform authentication of credentials.
Endpoint established...
The User Endpoint owned by URI: sip:myUser@myCompany.com is now established and registered.
Enter the URI of the user logged onto Microsoft Lync, in the
User@Host format =>
Unhandled Exception: SupportedAuthenticationProtocols=Ntlm, Kerberos
Realm=SIP Communications Service
FailureReason=NoAuthenticatingAuthority
ErrorCode=-2146893039
Microsoft.Rtc.Signaling.AuthenticationException:Unable to perform authentication of credentials. ---> Microsoft.Rtc.Internal.Sip.AuthException: NegotiateSecurityAssociation failed, error: -2
146893039
at Microsoft.Rtc.Internal.Sip.SipAuthenticationHelper.NegotiateSecurityAssociation(SecurityAssociationBase sa, String inputString, ContextFlags inContextAttributes, String& outputString)
at Microsoft.Rtc.Internal.Sip.ProtocolAuth.DoProtocolOutgoingNegotiation(SecurityAssociation sa, SipMessage message, ChallengeData challengeData)
at Microsoft.Rtc.Internal.Sip.AuthenticationControlModule.NegotiateSecurityAssociation(SecurityAssociation sa, SipMessage message, NegotiateArgs negotiateArguments)
--- End of inner exception stack trace ---
at Microsoft.Rtc.Signaling.SipAsyncResult`1.ThrowIfFailed()
at Microsoft.Rtc.Signaling.Helper.EndAsyncOperation[T](Object owner, IAsyncResult result)
at Microsoft.Rtc.Collaboration.LocalEndpoint.EndEstablish(IAsyncResult result)
at Microsoft.Rtc.Collaboration.Sample.Common.UCMASampleHelper.EndEndpointEstablish(IAsyncResult ar) in C:\Program Files\Microsoft UCMA 3.0\SDK\Core\Sample Applications\QuickStarts\Common\UCMASampleHelper.cs:line 625
at Microsoft.Rtc.Signaling.CompletionCallbackWorkItem.Microsoft.Rtc.Signaling.IWorkitem.Process()
at Microsoft.Rtc.Signaling.WorkitemQueue.ProcessItems()
at Microsoft.Rtc.Signaling.SerializationQueue`1.ResumeProcessing()
at Microsoft.Rtc.Signaling.SerializationQueue`1.ResumeProcessingCallback(Object state)
at Microsoft.Rtc.Signaling.QueueWorkItemState.ExecuteWrappedMethod(WaitCallback method, Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(_ThreadPoolWaitCallback tpWaitCallBack)
at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(Object state)
Detected at System.Environment.get_StackTrace()
at Microsoft.Rtc.Signaling.FailureResponseException..ctor(String message, Exception innerException, SipResponseData responseData)
at Microsoft.Rtc.Signaling.AuthenticationException..ctor(String message, Exception innerException, SipAuthenticationProtocolsInternal authenticationProtocolsSupportedByServer, String realm, AuthenticationFailureReason failureReason, Int32 errorCode)
at Microsoft.Rtc.Signaling.ExceptionUtilities.TryMapS4Exception(Exception s4Exception, SecurityAssociationContext securityContext, Boolean isSipEndpoint, String traceId, Object parentObject, Object childObject, RealTimeException& ex)
at Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.Transaction_MessageSendFailed(Object sender, MessageProcessingFailedEventArgs e)
at Microsoft.Rtc.Internal.Sip.SipCoreManager.OnMessageSendFailed(Object sender, MessageProcessingFailedEventArgs eventArgs)
at Microsoft.Rtc.Internal.Sip.SipStack.OnMessageSentInternal(SipMessage message, Exception error)
at Microsoft.Rtc.Internal.Sip.SingleThreadedDispatcherQueue.DispatcherCallback(Object queue)
at System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(_ThreadPoolWaitCallback tpWaitCallBack)
at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(Object state)
Press any key to continue . . .
PS> Get-CsTrustedApplication
Identity : trusted_app_pool.myCompany.com/urn:application:myTestapplication
ComputerGruus : {trusted_server.myCompany.com sip:trusted_server.myCompany.com@myCompany.com;gruu;opaque=srvr:myTestapplication:tscNt7I7OFW2dH43cssDuQAA}
ServiceGruu : sip:trusted_app_pool.myCompany.com@myCompany.com;gruu;opaque=srvr:myTestapplication:m84QGEhyTlK5LL8e8rOENwAA
Protocol : Mtls
ApplicationId : urn:application:myTestapplication
TrustedApplicationPoolFqdn : trusted_app_pool.myCompany.com
Port : 10607
LegacyApplicationName : myTestapplication
PS> Get-CsTrustedApplicationEndpoint
Identity : CN={02f81c7f-c02c-40db-b2ee-aa0e0d6fe1dd},CN=Application Contacts,CN=RTC Service,CN=Services,CN=Configuration,DC=myCompany,DC=com
RegistrarPool : front_end_pool.myCompany.com
HomeServer : CN=Lc Services,CN=Microsoft,CN=1:2,CN=Pools,CN=RTC Service,CN=Services,CN=Configuration,DC=myCompany,DC=com
OwnerUrn : urn:application:myTestapplication
SipAddress : sip:myUser@myCompany.com
DisplayName : IM Bot
DisplayNumber :
LineURI :
PrimaryLanguage : 0
SecondaryLanguages : {}
EnterpriseVoiceEnabled : True
Enabled : True
Any clues or suggestions will help. Thanks in advance.