function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AaronLauAaronLau 

Single Sign-On with "service is currently down" error

We are using a developer edition to test SSO, the organization id of the developer edition is "00D3000000018e5", the Single Sign-On Gateway URL configured is: "https://salesforce.didata.com/SignleSignOn/SingleSignOn.asmx". but when we tested it, there is an error "Your company's authentication service is currently down. Please contact the administrator at your company for more information.", the meaning of this error I think is "https://salesforce.didata.com/SignleSignOn/SingleSignOn.asmx" is not accessible, but the true is that is a valid web service url. could you anyone tell me where the problem is? do I miss anything?
Best Answer chosen by Admin (Salesforce Developers) 
SuperfellSuperfell
Your listener is not using the right XML namespaces, compare the WSDL for your service against the WSDL we publish for the service and you'll see the namespaces are different, so we're probably just getting error from your listener.

All Answers

SuperfellSuperfell
Your listener is not using the right XML namespaces, compare the WSDL for your service against the WSDL we publish for the service and you'll see the namespaces are different, so we're probably just getting error from your listener.
This was selected as the best answer
AaronLauAaronLau
it's working now. thank you very much SimonF.
dcyendcyen

Hi Simon,

 

Could you please let me know what's the the right XML namespaces?

I have set the Namespace as below, but it's still getting the same error.

Appreciate if you could let me know anywhere in my XML that's wrong. Our webservice URL is: http://salesforce.tycoasia.com

 

using System;

using System.Collections;

using System.ComponentModel;

using System.Data;

using System.Diagnostics;

using System.Web;

using System.Web.Services;

using System.DirectoryServices;

namespace SalesforceWebService

{

/// <summary>

/// Summary description for SforceAuthenticationService.

/// </summary>

[WebService(Namespace = "urn:authentication.soap.sforce.com")]

public class SforceAuthenticationService : System.Web.Services.WebService

{

[System.Web.Services.WebMethodAttribute()]

[System.Web.Services.Protocols.SoapDocumentMethodAttribute("",

RequestNamespace="urn:authentication.soap.sforce.com",

ResponseElementName="AuthenticateResult",

ResponseNamespace="urn:authentication.soap.sforce.com",

Use=System.Web.Services.Description.SoapBindingUse.Literal,

ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]

[return: System.Xml.Serialization.XmlElementAttribute("Authenticated")]

public AuthenticateResponse Authenticate ( string username,

string password, string sourceip)

{

AuthenticateResponse response = new AuthenticateResponse();

 

// try and bind to an AD entry, this will authenticate the username & password we supply

// TODO: you'll need to change this to match your AD name

 const string root = "LDAP://servername/OU=Asia,OU=APAC,OU=Divisions,DC=TYCOFS,DC=COM";

try

{

String username1 = username.Replace("@tycoint.com.ASIADEV", "");

String account1 = "tycofs\\" + username1;

DirectoryEntry de = new DirectoryEntry(root, account1, password);

// retrieve a property

 string tempName = de.Name;

response.Authenticated = true;

return response;

//System.Diagnostics.EventLog.WriteEntry("Salesforce_WebService", "Username: " + username + "Password: " + password, System.Diagnostics.EventLogEntryType.SuccessAudit, 3);

}

catch(Exception)

{

response.Authenticated = false; return response;

}

}

}

}

======================================

AuthenticateResponse.cs

===================

 

using System;

namespace SalesforceWebService

{

/// <summary>

/// Summary description for AuthenticateResponse.

/// </summary>

 public class AuthenticateResponse

{

private bool authenticated; public bool Authenticated

{

get{ return authenticated;}

set{ authenticated = value;}

}

 

}

}

=================================================

This is the Response that will be sent to Salesforce.

  

  <?xml version="1.0" encoding="utf-8" ?>
- <AuthenticateResponse xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:authentication.soap.sforce.com">
  <Authenticated>true</Authenticated>
  </AuthenticateResponse>
 
===================================================
 
Thank you.
Message Edited by dcyen on 06-29-2009 02:04 AM