通过PHP和SOAP验证(索赔)到SharePoint / Office356 [英] Authenticating (claims) to Sharepoint/Office356 through PHP and SOAP

查看:163
本文介绍了通过PHP和SOAP验证(索赔)到SharePoint / Office356的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试使用PHP5的要求身份验证标准的SOAP的lib使SOAP请求到SharePoint列表(通过http://url.co.uk/_vti_bin/Lists.asmx?WSDL)。我有它使用NTLM身份验证(这是一个痛苦的,但最终的工作),但现在该项目的职责是通过索赔的验证,它会为任何一个Sharepoint的安装或office365实例工作。

I am trying to make SOAP requests to Sharepoint lists (via 'http://url.co.uk/_vti_bin/Lists.asmx?WSDL) using PHP5's standard SOAP lib that require authentication. I had it working fine using NTLM authentication (which was a pain but worked in the end) but now the remit of the project is to authenticate through CLAIMS so that it will work for either a Sharepoint install or an office365 instance.

我从一开始就意识到,一个标准的SOAP验证是行不通的......但我想也无妨!不出所料,我接收到错误背列表故障code:HTTPList故障字符串:禁止。

I realised from the outset that a standard SOAP authentication would not work...but I tried it anyway! Unsurprisingly, I received an error back "List Fault code: HTTPList Fault string: Forbidden".

是否有可能由一个纯PHP /基于SOAP的解决方案,通过索赔来验证和若然是实现这一目标的最佳途径?我已阅读不同的声明身份验证的文章为SharePoint与使用Apache的技巧等,以不同的身份验证解决方案。我工作的项目需要这是一个纯PHP解决方案。

Is it possible to Authenticate through CLAIMS by a Pure PHP/SOAP based solution and if so what is the best way of achieving this? I have read varying articles on Claims auth for sharepoint with varying solutions using Apache tricks etc to authenticate. The project I am working on requires this to be a pure PHP solution.

这可能是值得指出的是,我不是一个MS开发人员,理赔认证知识有限(这可能也无济于事!)

It may be worth pointing out that I am not a MS developer and have limited knowledge on CLAIMS authentication (which probably doesn't help!)

推荐答案

phpSPO - SharePoint客户端的PHP 库允许你使用SharePoint Online的一个基于REST / OData的API SharePoint列表数据执行CRUD操作。

phpSPO - SharePoint client for PHP library allows you to performs CRUD operations on SharePoint list data using an REST/OData based API for SharePoint Online.

目前的版本使用基于声明的身份验证支持SharePoint Online中。

The current version supports SharePoint Online using claims based authentication.

如何在SharePoint Online中(SPO)进行认证:

How to perform authentication in SharePoint Online (SPO):

try {
    $client = new SPOClient($url);
    $client->signIn($username,$password);
    echo 'You have been authenticated successfully\n';
}
catch (Exception $e) {
    echo 'Authentication failed: ',  $e->getMessage(), "\n";
}

这篇关于通过PHP和SOAP验证(索赔)到SharePoint / Office356的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆