linux

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2023 License: LGPL-3.0 Imports: 7 Imported by: 6

Documentation

Overview

Package linux provides an interface for communicating with TPMs using a Linux TPM character device

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TctiDevice

type TctiDevice struct {
	// contains filtered or unexported fields
}

TctiDevice represents a connection to a Linux TPM character device.

func OpenDevice

func OpenDevice(path string) (*TctiDevice, error)

OpenDevice attempts to open a connection to the Linux TPM character device at the specified path. If successful, it returns a new TctiDevice instance which can be passed to tpm2.NewTPMContext. Failure to open the TPM character device will result in a *os.PathError being returned.

func (*TctiDevice) Close

func (d *TctiDevice) Close() error

Close implements tpm2.TCTI.

func (*TctiDevice) MakeSticky

func (d *TctiDevice) MakeSticky(handle tpm2.Handle, sticky bool) error

MakeSticky implements tpm2.TCTI.

func (*TctiDevice) Read

func (d *TctiDevice) Read(data []byte) (int, error)

Read implmements tpm2.TCTI.

func (*TctiDevice) SetLocality

func (d *TctiDevice) SetLocality(locality uint8) error

SetLocality implements tpm2.TCTI.

func (*TctiDevice) Write

func (d *TctiDevice) Write(data []byte) (int, error)

Write implmements tpm2.TCTI.

Jump to

Keyboard shortcuts

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