paragonie/paserk-wrap-aws-kms
最新稳定版本:v0.1.0
Composer 安装命令:
composer require paragonie/paserk-wrap-aws-kms
包简介
Use AWS KMS for key-wrapping with PASERK
README 文档
README
Integrates PASERK with AWS KMS for key-wrapping. Requires PHP 8.1 or newer.
This repository is an extension of PASERK for PHP.
PASERK Specification
The PASERK Specification can be found in this repository.
Installing
composer require paragonie/paserk-aws-kms
Usage
Initialization
You will need a KmsClient object and
a PASETO protocol version object.
<?php use Aws\Kms\KmsClient; use ParagonIE\Paseto\ProtocolInterface; use ParagonIE\Paserk\Operations\Wrap\AwsKms; /** * @var KmsClient $kmsClient * @var ProtocolInterface $pasetoProtocol */ $awsKmsWrapper = new AwsKms($kmsClient, $pasetoProtocol);
If you'd like to specify custom Encryption Context:
$awsKmsWrapper->setEncryptionContex([ 'department' => '10103.0' ]);
You can then pass the AwsKms object to the constructor of the PASERK Wrap Operation class.
/** * @var AwsKms $awsKmsWrapper */ $wrapper = new \ParagonIE\Paserk\Operations\Wrap($awsKmsWrapper);
See the paserk-php documentation for further details.
统计信息
- 总下载量: 3
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: ISC
- 更新时间: 2023-08-25