Tag: sharepoint 2013

CmisUnauthorizedException:Unauthorized – 使用Apache Chemistry库连接到Sharepoint 2013时出错

我担心使用Apache Chemistry库通过CMIS连接到Sharepoint 2013。 我收到未经授权的错误 ,但我使用的凭证(U / P)是正确的。 我用它来登录Sharepoint Online,因此应该处理我的代码。 希望有人能帮我解决这个问题。 谢谢! 请参阅下面的代码我用来创建一个到Sharepoint的会话: public Session fillParams() {//define some values for the connection string String rest_base = “http:///sites/_api/web/”; String repository_id = “c013ab76-4821-489f-9a1c-1d43bfce1c32”; String atompub_url = rest_base + “/” + repository_id + “”; String username =”notTobeShown”; String password = “notTobeShown”; SessionFactory factory = SessionFactoryImpl.newInstance(); Map parameter = new […]

如何使用泽西发送NTLM认证的post请求?

我正在使用Java对Sharepoint 2013进行restapi调用。 如何使用泽西rest客户端连接到sharepoint 2013? 注意:目前我使用的是apache http组件和NTCredentials类 Credentials credentials=new NTCredentials(username, password, workstation, domain); AuthScope authScope=new AuthScope(AuthScope.ANY); CredentialsProvider credsProvider = new BasicCredentialsProvider(); credsProvider.setCredentials(authScope,credentials); CloseableHttpClient httpclient = HttpClients.custom().setDefaultCredentialsProvider(credsProvider).build(); 如何将此采用到Jersey框架?