web services - PHP: certificate chain for SOAP request -


मेरे पास नमूना SOAP अनुरोध संदेश नीचे की तरह है,

  & lt; soapenv: लिफाफा xmlns: Soapenv = "http://schemas.xmlsoap.org/soap/envelope/" xmlns: v = "http://incometaxindiaefiling.gov.in/ws/ds/common/v_1_0" & gt; & LT; soapenv: हैडर / & gt; & LT; soapenv: शरीर & gt; & LT; वी: DITWSAuthInfoEle & gt; & LT; वी: userID & gt; xxxxxxxxxx & lt; / वी: userID & gt; & LT; वी: पासवर्ड & gt; xxxxxxxxxx & lt; / वी: पासवर्ड & gt; & LT; वी: certChain & gt; xxxxxxxxxx & lt; / वी: certChain & gt; & LT; वी: हस्ताक्षर & gt; xxxxxxxxxx & lt; / वी: हस्ताक्षर & gt; & Lt; / वी: DITWSAuthInfoEle & gt; & Lt; / soapenv: शरीर & gt; & Lt; / soapenv: लिफाफा & gt;   

मुझे प्रमाणीकरण विवरण और xyz.pfx फ़ाइल मिली। इस फाइल का उपयोग करके मुझे एक्सएमएल हस्ताक्षर का प्रतिनिधित्व मिला है और एसओएपी अनुरोध से जोड़ा गया है। यहां मेरा प्रश्न है कि मैं प्रमाण पत्र (प्रमाणपत्र श्रृंखला) कैसे प्राप्त कर सकता हूं और एसओएपी अनुरोध को कैसे जोड़ूं? कोई भी इस पर मेरी मदद कर सकता है?

का उपयोग करना, सर्वर प्रमाणपत्र डिफ़ॉल्ट रूप से मान्य है और आप इस तरह एक क्लाइंट प्रमाणपत्र भेज सकते हैं: <पूर्व> $ protected_url = "https: // my-server /? wsdl"; $ My_cert_file = "/my/path/to/mycert.pem"; $ क्लाइंट = नया सोप क्लाइंट ($ संरक्षित_रेल, अरै ('local_cert', $ my_cert_file));

या, यदि आपके प्रमाणपत्र को पासफ़्रेज़ की आवश्यकता होती है:

  $ client = नया सोप क्लाइंट ("https: //url.to.service/", ऐरे ('Local_cert' = & gt; 'client_certificate.pem', 'passphrase' = & gt; 'पास्पार्से', 'कैचे_डेएसडीएल' = & gt; डब्लूएसडीएल_एएकेएचएएनएनओएनओएनएएनएन););   

फिर, अगर आप एक्सएमएल देखना चाहते हैं, तो आप इसका उपयोग कर सकते हैं

PHP पर प्रमाण पत्रों के साथ SOAP का उपयोग करने के बारे में यह विस्तृत उत्तर भी देखें:



Comments

Popular posts from this blog

asp.net - Procedure or function "Procedure name" expects a parameter "Param name" which was not supplied occurs rarely -

jsp - No mapping found for HTTP request with URI with annotation config Spring MVC and Jetty -

sql server ce - Is there some way to make sqlce3.5 and 4.0 co-exist in the C# project -