将Mule与SharePoint online和内部部署ADF集成时出现的问题

将Mule与SharePoint online和内部部署ADF集成时出现的问题,sharepoint,mule,Sharepoint,Mule,我需要从Mule读取和写入SharePoint列表 设置如下:Mule 3.6、SharePoint online 2013和内部部署ADF 对SharePoint works的Web访问,用户通过以下URL序列: 我打开保存的SharePoint网站页面--https://[company].SharePoint.com/sites/../Collab/.. 我自动重定向到https://login.microsoftonline.com/login.srf?... 键入电子邮件后,我会自动

我需要从Mule读取和写入SharePoint列表

设置如下:Mule 3.6、SharePoint online 2013和内部部署ADF

对SharePoint works的Web访问,用户通过以下URL序列:

  • 我打开保存的SharePoint网站页面--
    https://[company].SharePoint.com/sites/../Collab/..
  • 我自动重定向到
    https://login.microsoftonline.com/login.srf?...
  • 键入电子邮件后,我会自动重定向到“组织的登录页面”-
    https://adfs.[公司].com/adfs/ls/?…
  • 我在那里键入电子邮件和密码,然后自动重定向回登录名为
    login.microsoftonline.com
    ,最后转到
    [company].sharepoint.com
    ,在那里我可以看到列表
在Mule中,我在“索赔连接”模式下使用SharePoint 2013连接器

配置如下:

<sharepoint:claims-connection-config
  disableCnCheck="true"
  name="Microsoft_SharePoint_2013__Claims_Connection"
  username="[user email]"
  password="[password]"
  siteUrl="https://[company].sharepoint.com/sites/[site]/"
  stsUrl="https://adfs.[company].com/adfs/services/trust/13/usernamemixed"
  scope="urn:federation:MicrosoftOnline"
  doc:name="Microsoft SharePoint 2013: Claims Connection"
/>
列表id是从web中找到的,用户可以访问该列表

无论是在单击“测试连接”还是在运行流时,我都会遇到以下异常:

org.mule.api.ConnectionException: Code: 403 Message: {"error":{"code":"-2147024891, System.UnauthorizedAccessException","message":{"lang":"en-US","value":"Access denied. You do not have permission to perform this action or access this resource."}}}
    at org.mule.module.sharepoint.connection.BaseSharepointConnectionStrategy.connect(BaseSharepointConnectionStrategy.java:83) ~[?:?]
    at org.mule.module.sharepoint.connectivity.ClaimsConnectionStrategySharepointConnectorAdapter.connect(ClaimsConnectionStrategySharepointConnectorAdapter.java:21) ~[?:?]
    at org.mule.module.sharepoint.connectivity.ClaimsConnectionStrategySharepointConnectorAdapter.connect(ClaimsConnectionStrategySharepointConnectorAdapter.java:9) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementConnectorFactory.makeObject(ConnectionManagementConnectorFactory.java:47) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementConnectorFactory.makeObject(ConnectionManagementConnectorFactory.java:15) ~[?:?]
    at org.apache.commons.pool.impl.GenericKeyedObjectPool.borrowObject(GenericKeyedObjectPool.java:1220) ~[commons-pool-1.6.jar:1.6]
    at org.mule.module.sharepoint.connectivity.SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.acquireConnection(SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.java:269) ~[?:?]
    at org.mule.module.sharepoint.connectivity.SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.acquireConnection(SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.java:58) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementProcessInterceptor.execute(ConnectionManagementProcessInterceptor.java:47) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementProcessInterceptor.execute(ConnectionManagementProcessInterceptor.java:19) ~[?:?]
    at org.mule.security.oauth.process.RetryProcessInterceptor.execute(RetryProcessInterceptor.java:84) ~[mule-module-devkit-support-3.6.0.jar:3.6.0]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementProcessTemplate.execute(ConnectionManagementProcessTemplate.java:33) ~[?:?]
    ...
调查表明,此异常实际上并不是Mule从SharePoint获得的第一个错误

连接到
https://adfs.[company].com/adfs/services/trust/13/usernamemix/
并获取令牌后,Mule执行POST到
https://[company].sharepoint.com/sites/../\u trust/
。该URL使用HTTP 200 OK进行应答,但HTML包含“对不起,出了问题”和“发生了意外错误”消息

不知道为什么,可能是因为代码200,Mule忽略了这一点,并继续向
https://[company].sharepoint.com/sites/../\u api/web/id
发出GET请求,返回上述403异常


非常感谢您在排除此连接过程故障方面提供的任何帮助。

最新的Microsoft SharePoint 2013连接器版本2.1.8于2015-10-06发布,最终能够与用户通过prem AD FS连接到SharePoint Online


就我个人而言,我使用了“在线”配置类型。不确定索赔类型是否为auth。

最新的Microsoft SharePoint 2013连接器版本2.1.8于2015年10月06日发布,最终能够与来自prem AD FS的用户连接到SharePoint Online


就我个人而言,我使用了“在线”配置类型。不确定索赔类型auth。

只是为了不让它保持打开状态。连接器文档对此相当混乱。一方面,它在常见问题部分中指出:“对于SharePoint Online,支持使用标准SharePoint Online用户凭据进行身份验证”。另一方面,在“身份验证”一节中,它提到了“Microsoft SharePoint在线身份验证”的“基于声明的身份验证”。但最后,我认为SharePoint online不支持内部部署声明身份验证。如果有人有不同的信息,请分享。只是为了不让这个简单地打开。连接器文档对此相当混乱。一方面,它在常见问题部分中指出:“对于SharePoint Online,支持使用标准SharePoint Online用户凭据进行身份验证”。另一方面,在“身份验证”一节中,它提到了“Microsoft SharePoint在线身份验证”的“基于声明的身份验证”。但最后,我认为SharePoint online不支持内部部署声明身份验证。如果有人有不同的信息,请分享。只是为了不让这个简单地打开。连接器文档对此相当混乱。一方面,它在常见问题部分中指出:“对于SharePoint Online,支持使用标准SharePoint Online用户凭据进行身份验证”。另一方面,在“身份验证”一节中,它提到了“Microsoft SharePoint在线身份验证”的“基于声明的身份验证”。但最后,我认为SharePoint online不支持内部部署声明身份验证。如果有人有不同的信息,请分享。
org.mule.api.ConnectionException: Code: 403 Message: {"error":{"code":"-2147024891, System.UnauthorizedAccessException","message":{"lang":"en-US","value":"Access denied. You do not have permission to perform this action or access this resource."}}}
    at org.mule.module.sharepoint.connection.BaseSharepointConnectionStrategy.connect(BaseSharepointConnectionStrategy.java:83) ~[?:?]
    at org.mule.module.sharepoint.connectivity.ClaimsConnectionStrategySharepointConnectorAdapter.connect(ClaimsConnectionStrategySharepointConnectorAdapter.java:21) ~[?:?]
    at org.mule.module.sharepoint.connectivity.ClaimsConnectionStrategySharepointConnectorAdapter.connect(ClaimsConnectionStrategySharepointConnectorAdapter.java:9) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementConnectorFactory.makeObject(ConnectionManagementConnectorFactory.java:47) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementConnectorFactory.makeObject(ConnectionManagementConnectorFactory.java:15) ~[?:?]
    at org.apache.commons.pool.impl.GenericKeyedObjectPool.borrowObject(GenericKeyedObjectPool.java:1220) ~[commons-pool-1.6.jar:1.6]
    at org.mule.module.sharepoint.connectivity.SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.acquireConnection(SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.java:269) ~[?:?]
    at org.mule.module.sharepoint.connectivity.SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.acquireConnection(SharepointConnectorClaimsConnectionConfigConnectionManagementConnectionManager.java:58) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementProcessInterceptor.execute(ConnectionManagementProcessInterceptor.java:47) ~[?:?]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementProcessInterceptor.execute(ConnectionManagementProcessInterceptor.java:19) ~[?:?]
    at org.mule.security.oauth.process.RetryProcessInterceptor.execute(RetryProcessInterceptor.java:84) ~[mule-module-devkit-support-3.6.0.jar:3.6.0]
    at org.mule.devkit.3.6.1.shade.connection.management.ConnectionManagementProcessTemplate.execute(ConnectionManagementProcessTemplate.java:33) ~[?:?]
    ...