PHP code example of stayallive / tlsa
1. Go to this page and download the library: Download stayallive/tlsa library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
stayallive / tlsa example snippets
$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