sqlstore

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2026 License: Apache-2.0 Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package sqlstore persists passkey ceremonies and credentials via database/sql against PostgreSQL-compatible servers (PostgreSQL, SereneDB, and similar).

Index

Constants

View Source
const Schema = `` /* 671-byte string literal not displayed */

Schema is applied idempotently by Open.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

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

Store is a multi-host passkey.Store.

func Open

func Open(ctx context.Context, db *sql.DB) (*Store, error)

Open pings db and applies Schema.

func (*Store) CountCredentials

func (s *Store) CountCredentials(ctx context.Context, subjectID string) (int, error)

func (*Store) DeleteCredential

func (s *Store) DeleteCredential(ctx context.Context, subjectID string, credentialID []byte) error

func (*Store) ListCredentials

func (s *Store) ListCredentials(ctx context.Context, subjectID string) ([]passkey.CredentialRecord, error)

func (*Store) LookupCredential

func (s *Store) LookupCredential(ctx context.Context, credentialID []byte, subjectID string) (passkey.CredentialRecord, error)

func (*Store) PutCeremony

func (s *Store) PutCeremony(ctx context.Context, c passkey.Ceremony) error

func (*Store) PutCredential

func (s *Store) PutCredential(ctx context.Context, rec passkey.CredentialRecord) error

func (*Store) TakeCeremony

func (s *Store) TakeCeremony(ctx context.Context, digest [32]byte) (passkey.Ceremony, error)

func (*Store) UpdateCredential

func (s *Store) UpdateCredential(ctx context.Context, rec passkey.CredentialRecord) error

Jump to

Keyboard shortcuts

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