MCPcopy Create free account
hub / github.com/XTLS/Go / cipherAES

Function cipherAES

cipher_suites.go:414–420  ·  view source on GitHub ↗
(key, iv []byte, isRead bool)

Source from the content-addressed store, hash-verified

412}
413
414func cipherAES(key, iv []byte, isRead bool) any {
415 block, _ := aes.NewCipher(key)
416 if isRead {
417 return cipher.NewCBCDecrypter(block, iv)
418 }
419 return cipher.NewCBCEncrypter(block, iv)
420}
421
422// macSHA1 returns a SHA-1 based constant time MAC.
423func macSHA1(key []byte) hash.Hash {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…