Home | History | Annotate | Download | only in cipher

Lines Matching full:ciphertext

19 	ciphertext, _ := hex.DecodeString("f363f3ccdcb12bb883abf484ba77d9cd7d32b5baecb3d4b1b3e0e4beffdb3ded")
27 // include it at the beginning of the ciphertext.
28 if len(ciphertext) < aes.BlockSize {
29 panic("ciphertext too short")
31 iv := ciphertext[:aes.BlockSize]
32 ciphertext = ciphertext[aes.BlockSize:]
35 if len(ciphertext)%aes.BlockSize != 0 {
36 panic("ciphertext is not a multiple of the block size")
42 mode.CryptBlocks(ciphertext, ciphertext)
52 fmt.Printf("%s\n", ciphertext)
74 // include it at the beginning of the ciphertext.
75 ciphertext := make([]byte, aes.BlockSize+len(plaintext))
76 iv := ciphertext[:aes.BlockSize]
82 mode.CryptBlocks(ciphertext[aes.BlockSize:], plaintext)
88 fmt.Printf("%x\n", ciphertext)
93 ciphertext, _ := hex.DecodeString("22277966616d9bc47177bd02603d08c9a67d5380d0fe8cf3b44438dff7b9")
101 // include it at the beginning of the ciphertext.
102 if len(ciphertext) < aes.BlockSize {
103 panic("ciphertext too short")
105 iv := ciphertext[:aes.BlockSize]
106 ciphertext = ciphertext[aes.BlockSize:]
111 stream.XORKeyStream(ciphertext, ciphertext)
112 fmt.Printf("%s", ciphertext)
126 // include it at the beginning of the ciphertext.
127 ciphertext := make([]byte, aes.BlockSize+len(plaintext))
128 iv := ciphertext[:aes.BlockSize]
134 stream.XORKeyStream(ciphertext[aes.BlockSize:], plaintext)
151 // include it at the beginning of the ciphertext.
152 ciphertext := make([]byte, aes.BlockSize+len(plaintext))
153 iv := ciphertext[:aes.BlockSize]
159 stream.XORKeyStream(ciphertext[aes.BlockSize:], plaintext)
166 // also decrypt that ciphertext with NewCTR.
170 stream.XORKeyStream(plaintext2, ciphertext[aes.BlockSize:])
186 // include it at the beginning of the ciphertext.
187 ciphertext := make([]byte, aes.BlockSize+len(plaintext))
188 iv := ciphertext[:aes.BlockSize]
194 stream.XORKeyStream(ciphertext[aes.BlockSize:], plaintext)
201 // also decrypt that ciphertext with NewOFB.
205 stream.XORKeyStream(plaintext2, ciphertext[aes.BlockSize:])
225 // If the key is unique for each ciphertext, then it's ok to use a zero
262 // If the key is unique for each ciphertext, then it's ok to use a zero