securestring

package
v0.83.0 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2026 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Overview

This package assumes that the caller's use case is not sensitive to timing attacks. In other words, it assumes that, even if an attacker can figure out the current index of the secret key originally used to encrypt the data, that information would not be materially useful to them. This is a reasonable assumption for most use cases. This is a light base64 wrapper over the "securebytes" package.

Index

Constants

View Source
const LegacyHKDFInfoStr = "vorma_kit_securestring_v1_encryption_key"

Deprecated: Use only if you need to support legacy encrypted values.

View Source
const MaxBase64Size = securebytes.MaxSize + securebytes.MaxSize/3

Variables

This section is empty.

Functions

func Parse

func Parse[T any](ks *keyset.Keyset, ss SecureString) (T, error)

Types

type SecureString

type SecureString string // Base64-encoded, encrypted value

func Serialize

func Serialize(ks *keyset.Keyset, rv securebytes.RawValue) (SecureString, error)

Jump to

Keyboard shortcuts

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