pkac

package module
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 14, 2022 License: BSD-3-Clause Imports: 10 Imported by: 1

README

pkac Build Status GoDoc

Pkac implements Go support for SPKAC/PKAC data as produced by the html <keygen> element.

PKAC is short for Public Key and Challenge and was defined a very long time ago with the Netscape browser as Signed Public Key And Challenge.

This package implements PKAC parsing and SPKAC validation from ASN.1-encoded []byte slices. For usage examples, see pkac_test.go.

Installation

go get github.com/longsleep/pkac

Documentation

Overview

Package pkac implements support for SPKAC/PKAC data as produced by the html <keygen> element (Signed Public Key And Challenge).

References: - https://web.archive.org/web/20070401073244/http://wp.netscape.com/eng/security/comm4-keygen.html - https://wiki.openssl.org/index.php/Manual:Spkac(1) - http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20080714/07ea5534/attachment.txt

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseSPKAC

func ParseSPKAC(derBytes []byte) (crypto.PublicKey, error)

ParseSPKAC parses a BER-encoded SPKAC and return the public key from it without validating a signature.

This function is provided for compatibility with PKAC blobs using message digests that are known to be broken (e.g. RSA with MD2).

func ValidateSPKAC

func ValidateSPKAC(derBytes []byte) (pub crypto.PublicKey, err error)

ValidateSPKAC parses a BER-encoded SPKAC and return the public key from it, validating a signature to ensure integrity.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL