x19sing

package
v0.0.1-alpha1 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2025 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// KeyLength is the fixed length of the key
	KeyLength = 32
	// GoldenRatio is a constant used in the encryption/decryption process
	GoldenRatio = 2654435769
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Cipher

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

func New

func New(key string) (*Cipher, error)

New creates a new Cipher instance with the provided key.

func (*Cipher) Decrypt

func (c *Cipher) Decrypt(encryptedData string) (string, error)

Decrypt decrypts the given encrypted data string.

func (*Cipher) Encrypt

func (c *Cipher) Encrypt(plainData string) (string, error)

Encrypt encrypts the given plain text data string.

Jump to

Keyboard shortcuts

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