package dnsclient

import "github.com/google/certificate-transparency-go/dnsclient"

Package dnsclient is a client library for performing CT operations over DNS. The DNS mechanism is experimental and subject to change.

Index

Types

type DNSClient

type DNSClient struct {
	Verifier *ct.SignatureVerifier // nil for no verification (e.g. no public key available)
	// contains filtered or unexported fields
}

DNSClient represents a DNS client for a given CT Log instance

func New

func New(base string, opts jsonclient.Options) (*DNSClient, error)

New constructs a new DNSClient instance. The base parameter gives the top-level domain name; opts can be used to provide a custom logger interface and a public key for signature verification.

func (*DNSClient) BaseURI

func (c *DNSClient) BaseURI() string

BaseURI returns a base dns: URI (cf. RFC 4501) that DNS queries will be built on.

func (*DNSClient) GetProofByHash

func (c *DNSClient) GetProofByHash(ctx context.Context, hash []byte, treeSize uint64) (*ct.GetProofByHashResponse, error)

GetProofByHash returns an audit path for the hash of an SCT.

func (*DNSClient) GetSTH

func (c *DNSClient) GetSTH(ctx context.Context) (*ct.SignedTreeHead, error)

GetSTH retrieves the current STH from the log.

func (*DNSClient) GetSTHConsistency

func (c *DNSClient) GetSTHConsistency(ctx context.Context, first, second uint64) ([][]byte, error)

GetSTHConsistency retrieves the consistency proof between two snapshots.

Source Files

dnsclient.go

Version
v1.0.18
Published
May 22, 2018
Platform
linux/amd64
Imports
13 packages
Last checked
57 minutes ago

Tools for package owners.