我为ios xmppframework
。我能够与GTalk
进行通信,但我需要将此API用于Microsoft OCS以用于我公司的内部应用程序。我们的服务器已配置CWA。
NSString *pURL=@"im.name.com";
NSURL *url = [NSURL URLWithString:pURL];
NSLog (@"%@", [url absoluteString]);
[xmppStream setHostName:[url absoluteString]];
[xmppStream setHostPort:443];
[xmppStream setMyJID:[XMPPJID jidWithString:@"Domain\id"]];
password = @"password";
但是我收到以下错误
SEND: <?xml version='1.0'?>
SEND: <stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' version='1.0' to='companyname.com'>
xmppStream:didReceiveError: Error Domain=AsyncSocketErrorDomain Code=4 "Read operation timed out" UserInfo=0x157460 {NSLocalizedDescription=Read operation timed out}
---------- xmppStreamDidDisconnect: ----------
Unable to connect to server. Check xmppStream.hostName
如果有人可以帮助我,那将会非常有帮助。