Lines Matching refs:cs
19 CipherState *cs; in initaes() local
22 cs = emalloc9p(sizeof(CipherState)); in initaes()
24 setupAESstate(&cs->state, c->s2cek, bits/8, c->s2civ); in initaes()
26 setupAESstate(&cs->state, c->c2sek, bits/8, c->c2siv); in initaes()
28 return cs; in initaes()
50 encryptaes(CipherState *cs, uchar *buf, int nbuf) in encryptaes() argument
52 if(cs->state.setup != 0xcafebabe || cs->state.rounds > AESmaxrounds) in encryptaes()
55 aesCBCencrypt(buf, nbuf, &cs->state); in encryptaes()
60 decryptaes(CipherState *cs, uchar *buf, int nbuf) in decryptaes() argument
62 if(cs->state.setup != 0xcafebabe || cs->state.rounds > AESmaxrounds) in decryptaes()
65 aesCBCdecrypt(buf, nbuf, &cs->state); in decryptaes()