ghindows/php-signed-soap-client
最新稳定版本:1.0.0
Composer 安装命令:
composer require ghindows/php-signed-soap-client
包简介
PHP SoapClient with SOAP Message Security
README 文档
README
SoapClient extensions which adds ability to sign messages and open HTTPS connections
Requirements
- PHP compiled with SOAP support
- xmllint utility (ubuntu/debian has it in libxml2-utils package)
Usage
This class supports SOAP Message Security standard.
You should set certificate (in PFX or PKCS7 format) while initializng class. Other HTTP options, identical to HTTPRequest class request options are accepted too:
$client = new SignedSoapClient(
'https://example.com?wsdl',
array(
'ssl' => array(
'cert' => '/file',
'certpasswd' => 'password'
)
)
);
Class signes SOAP-ENV:Body part of the message by default, this behaviour can be changed
in buildSignedInfo method.
Create a public/private key pair using OpenSSL
The basics command line steps to generate a private and public key using OpenSSL are as follows:
openssl genrsa -out privatekey.pem 1024 openssl req -new -x509 -key privatekey.pem -out publickey.cer -days 1825 openssl pkcs12 -export -out public_privatekey.pfx -inkey privatekey.pem -in publickey.cer
统计信息
- 总下载量: 3.28k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-08-21