Lines Matching refs:counter
57 // NOTE: the IV/counter CTR mode is big-endian. The code itself
60 // increment counter (128-bit int) by 1
61 static void ctr128_inc(uint8_t *counter) {
66 c += counter[n];
67 counter[n] = (uint8_t) c;
74 // The input encrypted as though 128bit counter mode is being used. The extra
76 // contained in *num, and the encrypted counter is kept in ecount_buf. Both
80 // This algorithm assumes that the counter is in the x lower bits of the IV
83 // the counter doesn't overflow into the rest of the IV when incremented.
144 // increment upper 96 bits of 128-bit counter by 1
145 static void ctr96_inc(uint8_t *counter) {
150 c += counter[n];
151 counter[n] = (uint8_t) c;
184 // As (*func) operates on 32-bit counter, caller