opaque

package
v2.4.1 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Overview

Package opaque is an authenticator for Agent communications with the server using the OPAQUE protocol

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UserAuthenticateComplete

func UserAuthenticateComplete(authInitResp opaque.Opaque, user *User) (opaque.Opaque, error)

UserAuthenticateComplete consumes the Server's authentication message and finishes the user authentication and key exchange

func UserAuthenticateInit

func UserAuthenticateInit(AgentID uuid.UUID, user *User) (opaque.Opaque, error)

UserAuthenticateInit is used to authenticate an agent leveraging the OPAQUE Password Authenticated Key Exchange (PAKE) protocol

func UserRegisterComplete

func UserRegisterComplete(regInitResp opaque.Opaque, user *User) (opaque.Opaque, error)

UserRegisterComplete consumes the Server's response and finishes OPAQUE registration

Types

type Authenticator

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

Authenticator is a structure used for OPAQUE authentication

func New

func New(id uuid.UUID) *Authenticator

New returns an OPAQUE Authenticator structure used for Agent authentication

func (*Authenticator) Authenticate

func (a *Authenticator) Authenticate(in messages.Base) (out messages.Base, authenticated bool, err error)

Authenticate goes through the entire OPAQUE process to authenticate to the server and establish a shared secret

func (*Authenticator) Secret

func (a *Authenticator) Secret() (key []byte, err error)

Secret returns the established shared secret as bytes

func (*Authenticator) String

func (a *Authenticator) String() string

String returns the name of the Authenticator type

type User

type User struct {
	Kex *gopaque.KeyExchangeSigma // User Key Exchange
	// contains filtered or unexported fields
}

User is the structure that holds information for the various steps of the OPAQUE protocol as the user

func UserRegisterInit

func UserRegisterInit(AgentID uuid.UUID, user *User) (opaque.Opaque, *User, error)

UserRegisterInit is used to perform the OPAQUE Password Authenticated Key Exchange (PAKE) protocol Registration steps for the user

Jump to

Keyboard shortcuts

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