我試圖訪問通過IFD公開的MS CRM,並且出現身份驗證問題。Ruby和MS Dynamics CRM身份驗證
SOAP端點位於NTLM後面,我可以訪問它。問題是,路過請求時,像下面的我得到401回覆:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<Execute xmlns="http://schemas.microsoft.com/crm/2007/CrmDiscoveryService">
<Request xsi:type="RetrieveCrmTicketRequest">
<OrganizationName>#{CRM_CONFIG[:org_name]}</OrganizationName>
<UserId>#{CRM_CONFIG[:username]}</UserId>
<Password>#{CRM_CONFIG[:password]}</Password>
</Request>
</Execute>
</soap:Body>
</soap:Envelope>
有沒有在服務器上調試這個的方法嗎?我可以檢查任何日誌以獲取更有意義的錯誤消息?
<?xml version=\"1.0\" encoding=\"utf-8\"?>
<soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\">
<soap:Header>
<CrmAuthenticationToken xmlns=\"http://schemas.microsoft.com/crm/2007/WebServices\">
<AuthenticationType xmlns=\"http://schemas.microsoft.com/crm/2007/CoreTypes\">2</AuthenticationType>
<OrganizationName xmlns=\"http://schemas.microsoft.com/crm/2007/CoreTypes\">#{CRM_CONFIG[:org_name]}</OrganizationName>
<CallerId xmlns=\"http://schemas.microsoft.com/crm/2007/CoreTypes\">#{TOUCH}</CallerId>
</CrmAuthenticationToken>
</soap:Header>
<soap:Body>
<RetrieveMultiple xmlns=\"http://schemas.microsoft.com/crm/2007/WebServices\">
<query xmlns:q1=\"http://schemas.microsoft.com/crm/2006/Query\" xsi:type=\"q1:QueryExpression\">
<q1:EntityName>contact</q1:EntityName>
</query>
</RetrieveMultiple>
</soap:Body>
</soap:Envelope>