xor

package
v1.6.29 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: BSD-2-Clause-Patent Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Base64

func Base64(item1, item2 string) (string, error)

Base64 function XOR two Base64-encoded string and returns the Base64-encoded result string

func Bytes

func Bytes(item1, item2 []byte) ([]byte, error)

Bytes function XOR two byte arrays

func Complement

func Complement(item []byte) []byte

Complement computes the XOR complement of the passed byte array, ie. Complement(x) = 1 ^ x

func String

func String(item1, item2 string) (string, error)

String function XOR two strings in the sense that each charCode/rune are xored

Types

type NotSameLengthError

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

NotSameLengthError ...

func NewNotSameLengthError

func NewNotSameLengthError() *NotSameLengthError

NewNotSameLengthError ...

func (NotSameLengthError) Error

func (e NotSameLengthError) Error() string

Jump to

Keyboard shortcuts

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