承接 stayallive/tlsa 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

stayallive/tlsa

Composer 安装命令:

composer require stayallive/tlsa

包简介

Generate TLSA records in PHP.

关键字:

README 文档

README

Latest Version on Packagist Total Downloads

This package contains a class that can generate TLSA resource records.

$tlsa = new Stayallive\TLSA\Builder('alexbouma.me');

$tlsa->forCertificate($pemEncodedCertificate);

$tlsa->getRecord(); // returns the full DNS record

$tlsa->getRecordContents(); // returns the DNS record contents only

Installation

You can install the package via composer:

composer require stayallive/tlsa

Usage

The class can generate a TLSA resource record for all certificate usages, selectors and matching types.

For more information check out the Wikipedia entry: https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities#RR_data_fields

use Stayallive\TLSA;

$tlsa = new TLSA\Builder('alexbouma.me', 25, 'udp'); // Builder for the alexbouma.me domain, port 25 and the UDP protocol

$tlsa->forCertificate($pemEncodedCertificate);
$tlsa->forPublicKey($pemEncodedPublicKey);

$tlsa->certificateUsage(TLSA\Builder::CERTIFICATE_USAGE_DOMAIN_ISSUED_CERTIFICATE); // Set the certificate usage to `3` (default)

$tlsa->selector(TLSA\Builder::SELECTOR_PUBLIC_KEY); // Set the selector to `1` (default)

$tlsa->matchingType(TLSA\Builder::MATCHING_TYPE_SHA256); // Set the matching type to `1` (default)

$dns->getRecord(); // returns the full DNS record
$dns->getRecordContents(); // returns the DNS record contents

Testing

composer test

Changelog

Please see CHANGELOG for more information what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security

If you discover any security related issues, please email me@alexbouma.me instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 2.44k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2018-09-15

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固