Hi Users,

Does anyone have any experience using C# as a SOAP client to sipXecs?
I'm using visual studio 2010 and I was able to import the WSDL but not
matter what I try I can't get my code to authenticate.  Both basic and
digest are supported now correct?


Code snippet:

 VersionClient _versionClient = new VersionClient("Version");

_versionClient.ClientCredentials.UserName.UserName = "superadmin";
_versionClient.ClientCredentials.UserName.Password = "superpassword";

version = _versionClient.getVersion();

Config file:

        <system.serviceModel>
                <bindings>
                        <basicHttpBinding>
                                <binding name="VersionSoapBinding" 
closeTimeout="00:01:00"
openTimeout="00:01:00"
                    receiveTimeout="00:10:00" sendTimeout="00:01:00"
allowCookies="false"
                    bypassProxyOnLocal="false"
hostNameComparisonMode="StrongWildcard"
                    maxBufferSize="65536" maxBufferPoolSize="524288"
maxReceivedMessageSize="65536"
                    messageEncoding="Text" textEncoding="utf-8"
transferMode="Buffered"
                    useDefaultWebProxy="true">
                                        <readerQuotas maxDepth="32" 
maxStringContentLength="8192"
maxArrayLength="16384"
                        maxBytesPerRead="4096" maxNameTableCharCount="16384" />
                                        <security mode="Transport">
                                                <transport 
clientCredentialType="Basic" proxyCredentialType="None"
                            realm="" />
                                        </security>
                                </binding>
                        </basicHttpBinding>
                </bindings>
                <client>
                        <endpoint 
address="https://example.com:8443/sipxconfig/services/Version";
                binding="basicHttpBinding"
bindingConfiguration="VersionSoapBinding"
                contract="SIPX_Version_Service.Version" name="Version" />
                </client>
        </system.serviceModel>



-- 
Kyle Haefner, M.S.
Communication Systems Programmer
Colorado State University
Fort Collins, CO
Phone: 970-491-1012
Email:  [email protected]
_______________________________________________
sipx-users mailing list
[email protected]
List Archive: http://list.sipfoundry.org/archive/sipx-users/

Reply via email to