pbootcms网站模板|日韩1区2区|织梦模板||网站源码|日韩1区2区|jquery建站特效-html5模板网

    1. <legend id='VOQv7'><style id='VOQv7'><dir id='VOQv7'><q id='VOQv7'></q></dir></style></legend>

      <small id='VOQv7'></small><noframes id='VOQv7'>

        <bdo id='VOQv7'></bdo><ul id='VOQv7'></ul>

        <i id='VOQv7'><tr id='VOQv7'><dt id='VOQv7'><q id='VOQv7'><span id='VOQv7'><b id='VOQv7'><form id='VOQv7'><ins id='VOQv7'></ins><ul id='VOQv7'></ul><sub id='VOQv7'></sub></form><legend id='VOQv7'></legend><bdo id='VOQv7'><pre id='VOQv7'><center id='VOQv7'></center></pre></bdo></b><th id='VOQv7'></th></span></q></dt></tr></i><div class="aga646m" id='VOQv7'><tfoot id='VOQv7'></tfoot><dl id='VOQv7'><fieldset id='VOQv7'></fieldset></dl></div>
        <tfoot id='VOQv7'></tfoot>
      1. 使用 PHP 進行 SOAP 身份驗證

        SOAP authentication with PHP(使用 PHP 進行 SOAP 身份驗證)
      2. <i id='kwOHP'><tr id='kwOHP'><dt id='kwOHP'><q id='kwOHP'><span id='kwOHP'><b id='kwOHP'><form id='kwOHP'><ins id='kwOHP'></ins><ul id='kwOHP'></ul><sub id='kwOHP'></sub></form><legend id='kwOHP'></legend><bdo id='kwOHP'><pre id='kwOHP'><center id='kwOHP'></center></pre></bdo></b><th id='kwOHP'></th></span></q></dt></tr></i><div class="20geyes" id='kwOHP'><tfoot id='kwOHP'></tfoot><dl id='kwOHP'><fieldset id='kwOHP'></fieldset></dl></div>
        <tfoot id='kwOHP'></tfoot>
            <legend id='kwOHP'><style id='kwOHP'><dir id='kwOHP'><q id='kwOHP'></q></dir></style></legend>

              <bdo id='kwOHP'></bdo><ul id='kwOHP'></ul>

                    <tbody id='kwOHP'></tbody>
                1. <small id='kwOHP'></small><noframes id='kwOHP'>

                2. 本文介紹了使用 PHP 進行 SOAP 身份驗證的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  限時送ChatGPT賬號..

                  我需要連接到需要純文本用戶名和密碼形式的身份驗證憑據的 Web 服務.

                  I need to connect to a web service that requires authentication credentials in the form of a plain text user name and password.

                  我對 SOAP 有基本的了解,并且已經設法使用 NuSOAP 連接到其他不需要用戶名或密碼的開放網絡服務.

                  I have a basic understanding of SOAP and have managed to connect to other open web services that do not require a username or password using NuSOAP.

                  以下內容已發送給我:

                  <?php
                  
                  // Set up security options
                  $security_options = array("useUsernameToken" => TRUE);
                  $policy = new WSPolicy(array("security" => $security_options));
                  
                  $security_token = new WSSecurityToken(array(
                      "user" => "xxx",
                      "password" => "xxx",
                      "passwordType" => "basic"));
                  
                  // Create client with options
                  $client = new WSClient(array("wsdl" => "https://xxx.asmx?wsdl",
                      "action" => "http://xxx",
                      "to" => "https://xxx",
                      "useWSA" => 'submission',
                      "CACert" => "cert.pem",
                      "useSOAP" => 1.1,
                      "policy" => $policy,
                      "securityToken" => $security_token));
                  
                  // Send request and capture response
                  $proxy = $client->getProxy();
                  
                  $input_array = array("From" => "2010-01-01 00:00:00",
                      "To" => "2010-01-31 00:00:00");
                  
                  $resMessage = $proxy->xxx($input_array);
                  ?>
                  

                  經過一些研究,我了解到上述實現使用 wso2.我需要能夠在不使用 wso2 的情況下做到這一點.

                  After some research I understand that the above implementation uses wso2. I need to be able to do this without using wso2.

                  我已盡最大努力尋找有關上述內容的資源(Google、論壇等),但一無所獲.我已經閱讀了一些關于 SOAP 的教程,并且已經能夠使用 PHP 設置一個 SOAP 客戶端,但無法理解所有的身份驗證和策略".

                  I have tried my best to look for resources (Google, forums, etc) about the above but haven't been able to find anything. I have read some tutorials on SOAP and have been able to set up a SOAP client using PHP but cannot get my head around all the authentication and "policies".

                  如果我正在扯頭發,我將非常感謝有關如何實現這一點的解釋以及一些進一步閱讀有關此內容的鏈接!理想情況下,我想要一些資源鏈接,供 SOAP 身份驗證的絕對初學者使用.

                  An explanation of how to achieve this and maybe some links to further reading about this would be very much appreciated as I am tearing my hair out! Ideally I would like some links to resources for an absolute beginner to the SOAP authentication.

                  謝謝.P.S 上面的一些鏈接/憑據可能已被 xxx'd 用于隱私.

                  Thanks. P.S some of the links/credentials in the above could have been xxx'd for privacy.

                  推薦答案

                  如果你在 php (php version >= 5.0.1) 中啟用了 SOAP 擴展,你可以使用 SoapClient 類來處理您的請求.要進行身份驗證,您可以將用戶名和密碼傳遞給具有目標 URL 的類:

                  If you have the SOAP extension enabled in php (php version >= 5.0.1), you can use the SoapClient class to process your request. To authenticate, you can pass the username and password to the class with the target URL:

                  $soapURL = "https://www.example.com/soapapi.asmx?wsdl" ;
                  $soapParameters = Array('login' => "myusername", 'password' => "mypassword") ;
                  $soapFunction = "someFunction" ;
                  $soapFunctionParameters = Array('param1' => 42, 'param2' => "Search") ;
                  
                  $soapClient = new SoapClient($soapURL, $soapParameters);
                  
                  $soapResult = $soapClient->__soapCall($soapFunction, $soapFunctionParameters) ;
                  
                  if(is_array($soapResult) && isset($soapResult['someFunctionResult'])) {
                      // Process result.
                  } else {
                      // Unexpected result
                      if(function_exists("debug_message")) {
                          debug_message("Unexpected soapResult for {$soapFunction}: ".print_r($soapResult, TRUE)) ;
                      }
                  }
                  

                  如果您不確定可以調用的函數,您可以在瀏覽器中查看目標 URL(例如以.asmx?wsdl"結尾).您應該得到一個 XML 響應,該響應告訴您可以調用的可用 SOAP 函數以及這些函數的預期參數.

                  If you're not sure about the functions you can call, you can view the target URL (e.g. ending in ".asmx?wsdl") in your browser. You should get an XML response that tells you the available SOAP functions you can call, and the expected parameters of those functions.

                  這篇關于使用 PHP 進行 SOAP 身份驗證的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  enable SOAP on PHP(在 PHP 上啟用 SOAP)
                  Get received XML from PHP SOAP Server(從 PHP SOAP 服務器獲取接收到的 XML)
                  not a valid AllXsd value(不是有效的 AllXsd 值)
                  PHP SoapClient: SoapFault exception Could not connect to host(PHP SoapClient:SoapFault 異常無法連接到主機)
                  Implementation of P_SHA1 algorithm in PHP(PHP中P_SHA1算法的實現)
                  Sending a byte array from PHP to WCF(將字節數組從 PHP 發送到 WCF)

                    • <bdo id='GKiXP'></bdo><ul id='GKiXP'></ul>
                        <tbody id='GKiXP'></tbody>
                      • <small id='GKiXP'></small><noframes id='GKiXP'>

                          1. <tfoot id='GKiXP'></tfoot>

                          2. <i id='GKiXP'><tr id='GKiXP'><dt id='GKiXP'><q id='GKiXP'><span id='GKiXP'><b id='GKiXP'><form id='GKiXP'><ins id='GKiXP'></ins><ul id='GKiXP'></ul><sub id='GKiXP'></sub></form><legend id='GKiXP'></legend><bdo id='GKiXP'><pre id='GKiXP'><center id='GKiXP'></center></pre></bdo></b><th id='GKiXP'></th></span></q></dt></tr></i><div class="2mwa6yy" id='GKiXP'><tfoot id='GKiXP'></tfoot><dl id='GKiXP'><fieldset id='GKiXP'></fieldset></dl></div>

                            <legend id='GKiXP'><style id='GKiXP'><dir id='GKiXP'><q id='GKiXP'></q></dir></style></legend>
                            主站蜘蛛池模板: 牛皮纸|牛卡纸|进口牛皮纸|食品级牛皮纸|牛皮纸厂家-伽立实业 | 尚为传动-专业高精密蜗轮蜗杆,双导程蜗轮蜗杆,蜗轮蜗杆减速机,蜗杆减速机生产厂家 | 气象监测系统_气象传感器_微型气象仪_气象环境监测仪-山东风途物联网 | UV固化机_UVLED光固化机_UV干燥机生产厂家-上海冠顶公司专业生产UV固化机设备 | 邢台人才网_邢台招聘网_邢台123招聘【智达人才网】 | 北京印刷厂_北京印刷_北京印刷公司_北京印刷厂家_北京东爵盛世印刷有限公司 | 成都热收缩包装机_袖口式膜包机_高速塑封机价格_全自动封切机器_大型套膜机厂家 | 活性炭厂家-蜂窝活性炭-粉状/柱状/果壳/椰壳活性炭-大千净化-活性炭 | 精雕机-火花机-精雕机 cnc-高速精雕机-电火花机-广东鼎拓机械科技有限公司 | 精密钢管,冷拔精密无缝钢管,精密钢管厂,精密钢管制造厂家,精密钢管生产厂家,山东精密钢管厂家 | 硅胶布|电磁炉垫片|特氟龙胶带-江苏浩天复合材料有限公司 | 食安观察网| 仓储货架_南京货架_钢制托盘_仓储笼_隔离网_环球零件盒_诺力液压车_货架-南京一品仓储设备制造公司 | 天津散热器_天津暖气片_天津安尼威尔散热器制造有限公司 | 胃口福饺子加盟官网_新鲜现包饺子云吞加盟 - 【胃口福唯一官网】 | 培训一点通 - 合肥驾校 - 合肥新亚驾校 - 合肥八一驾校 | 无水硫酸铝,硫酸铝厂家-淄博双赢新材料科技有限公司 | 北京印刷厂_北京印刷_北京印刷公司_北京印刷厂家_北京东爵盛世印刷有限公司 | VOC检测仪-甲醛检测仪-气体报警器-气体检测仪厂家-深恒安科技有限公司 | 液压升降货梯_导轨式升降货梯厂家_升降货梯厂家-河南东圣升降设备有限公司 | 螺旋压榨机-刮泥机-潜水搅拌机-电动泥斗-潜水推流器-南京格林兰环保设备有限公司 | 地磅-电子地磅维修-电子吊秤-汽车衡-无人值守系统-公路治超-鹰牌衡器 | 迪威娱乐|迪威娱乐客服|18183620002| 杭州画室_十大画室_白墙画室_杭州美术培训_国美附中培训_附中考前培训_升学率高的画室_美术中考集训美术高考集训基地 | 电机保护器-电动机综合保护器-浙江开民| 铣床|万能铣床|立式铣床|数控铣床|山东滕州万友机床有限公司 | 健身器材-健身器材厂家专卖-上海七诚健身器材有限公司 | 金刚网,金刚网窗纱,不锈钢网,金刚网厂家- 河北萨邦丝网制品有限公司 | 吸污车_吸粪车_抽粪车_电动三轮吸粪车_真空吸污车_高压清洗吸污车-远大汽车制造有限公司 | 工业洗衣机_工业洗涤设备_上海力净工业洗衣机厂家-洗涤设备首页 bkzzy在职研究生网 - 在职研究生招生信息咨询平台 | 塑料脸盆批发,塑料盆生产厂家,临沂塑料广告盆,临沂家用塑料盆-临沂市永顺塑业 | 私人别墅家庭影院系统_家庭影院音响_家庭影院装修设计公司-邦牛影音 | 运动木地板厂家_体育木地板安装_篮球木地板选购_实木运动地板价格 | 真空冷冻干燥机_国产冻干机_冷冻干燥机_北京四环冻干 | 萃取箱-萃取槽-PVC萃取箱厂家-混合澄清槽- 杭州南方化工设备 | 上海APP开发-APP制作-APP定制开发-上海APP开发制作公司-咏熠科技 | 分光色差仪,测色仪,反透射灯箱,爱色丽分光光度仪,美能达色差仪维修_苏州欣美和仪器有限公司 | 水压力传感器_数字压力传感器|佛山一众传感仪器有限公司|首页 | 锂电池砂磨机|石墨烯砂磨机|碳纳米管砂磨机-常州市奥能达机械设备有限公司 | 999范文网_优质范文下载写作帮手| 深圳昂为官网-气体分析仪,沼气分析仪,动态配气仪,气体传感器厂家 |