Hello,

I am trying to post to a ste that requires me to use a client cert.  I can
get it to work for both windows and unix, but only on the command line.  I
have tried without success to use the PHP built-in methods for doing this.
Here is the command line that works:

curl -d "<REQUEST_GROUP MISMOVersionID='2.1'> <REQUESTING_PARTY>
<PREFERRED_RESPONSE _Format='XML' /> </REQUESTING_PARTY> <REQUEST
LoginAccountIdentifier='12345' LoginAccountPassword='pass'>  <REQUEST_DATA>
<CREDIT_REQUEST MISMOVersionID='2.1'>    <CREDIT_REQUEST_DATA
CreditRequestType='Individual'>     <CREDIT_REPOSITORY_INCLUDED
_EquifaxIndicator='Y' _ExperianIndicator='Y' _TransUnionIndicator='Y'/>
</CREDIT_REQUEST_DATA>    <LOAN_APPLICATION>     <BORROWER
_FirstName='BOBBY' _LastName='BANKRUPT' _PrintPositionType='Borrower'
_SSN='000546327'>      <_RESIDENCE _City='PRESCOTT' _State='AZ'
_PostalCode='86305' BorrowerResidencyType='Current'>
<PARSED_STREET_ADDRESS  _AddressType='NormalAddress'  _HouseNumber='1003'
_StreetName='Enred Way' />      </_RESIDENCE>     </BORROWER>
</LOAN_APPLICATION>   </CREDIT_REQUEST>  </REQUEST_DATA>
</REQUEST></REQUEST_GROUP>" -k -E myCert.pem:myPassword
https://www.mysite.com/Listener.exe

Any ideas of how to make this work with the curl_setopt methods?  I tried
variations of this:

        $ch = curl_init();
        curl_setopt ($ch, CURLOPT_URL, $url);
        curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 0);
        curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, 2);
        curl_setopt ($ch, CURLOPT_SSLKEY, 'myCert.pem');
        curl_setopt ($ch, CURLOPT_SSLKEYPASSWD, 'myPassword');

        $result = curl_exec ($ch);


Thanks,
Scott

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to