camellia

package module
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2021 License: MIT Imports: 5 Imported by: 2

README

Camellia

Библиотека, реализующая алгоритм Camellia

cipher, err := NewCameliaCipher(key)
if err != nil {
    log.Fatalf("err: %v", err)
}

var b [16]byte

cipher.Encrypt(b[:], messageText)
cipher.Decrypt(b[:], cipherText)

Documentation

Index

Constants

View Source
const (
	C1 = 0xA09E667F3BCC908B
	C2 = 0xB67AE8584CAA73B2
	C3 = 0xC6EF372FE94F82BE
	C4 = 0x54FF53A5F1D36F1C
	C5 = 0x10E527FADE682D1D
	C6 = 0xB05688C2B3E6C1FD
)
View Source
const BLOCKSIZE = 16
View Source
const MASK32 = 0xffffffff

Variables

This section is empty.

Functions

func NewCipher added in v0.0.5

func NewCipher(key []byte) (cipher.Block, error)

128 бит = 16 байт 256 бит = 32 байт 192 бит = 24 байт

Types

type KeySizeError

type KeySizeError int

func (KeySizeError) Error

func (k KeySizeError) Error() string

Jump to

Keyboard shortcuts

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