Ordo  0.3.4
Symmetric Cryptography Library
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
ofb.h
Go to the documentation of this file.
1 /*===-- enc/block_modes/ofb.h --------------------------*- PUBLIC -*- H -*-===*/
19 /*===----------------------------------------------------------------------===*/
20 
21 #ifndef ORDO_OFB_MODE_H
22 #define ORDO_OFB_MODE_H
23 
25 #include "ordo/common/interface.h"
29 
30 #ifdef __cplusplus
31 extern "C" {
32 #endif
33 
34 /*===----------------------------------------------------------------------===*/
35 
36 #define ofb_init ordo_ofb_init
37 #define ofb_update ordo_ofb_update
38 #define ofb_final ordo_ofb_final
39 #define ofb_query ordo_ofb_query
40 #define ofb_bsize ordo_ofb_bsize
41 
42 /*===----------------------------------------------------------------------===*/
43 
46 ORDO_PUBLIC
47 int ofb_init(struct OFB_STATE *state,
48  struct BLOCK_STATE *cipher_state,
49  const void *iv, size_t iv_len,
50  int dir,
51  const void *params);
52 
55 ORDO_PUBLIC
56 void ofb_update(struct OFB_STATE *state,
57  struct BLOCK_STATE *cipher_state,
58  const void *in, size_t in_len,
59  void *out, size_t *out_len);
60 
63 ORDO_PUBLIC
64 int ofb_final(struct OFB_STATE *state,
65  struct BLOCK_STATE *cipher_state,
66  void *out, size_t *out_len);
67 
70 ORDO_PUBLIC
71 size_t ofb_query(prim_t cipher,
72  int query, size_t value);
73 
80 ORDO_PUBLIC
81 size_t ofb_bsize(void);
82 
83 /*===----------------------------------------------------------------------===*/
84 
85 #ifdef __cplusplus
86 }
87 #endif
88 
89 #endif
int prim_t
Data type which holds a primitive identifier.
Definition: identification.h:58
ORDO_PUBLIC size_t ofb_bsize(void)
ORDO_PUBLIC int ofb_init(struct OFB_STATE *state, struct BLOCK_STATE *cipher_state, const void *iv, size_t iv_len, int dir, const void *params)
Definition: ofb.c:22
ORDO_PUBLIC void ofb_update(struct OFB_STATE *state, struct BLOCK_STATE *cipher_state, const void *in, size_t in_len, void *out, size_t *out_len)
Definition: ofb.c:43
ORDO_PUBLIC int ofb_final(struct OFB_STATE *state, struct BLOCK_STATE *cipher_state, void *out, size_t *out_len)
Definition: ofb.c:74
ORDO_PUBLIC size_t ofb_query(prim_t cipher, int query, size_t value)
Abstraction Layer.