aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorlloyd <[email protected]>2013-03-16 16:58:59 +0000
committerlloyd <[email protected]>2013-03-16 16:58:59 +0000
commit3295768d2866d7533bbdf4dfec2675115dddd573 (patch)
treeec4e562325246d52807692168ba9731a3cc581bf /src
parent8f79bb2f6d06912bafd22f686576ce0898bb1eb4 (diff)
Make OCB_Base constructor private
Diffstat (limited to 'src')
-rw-r--r--src/filters/modes/ocb/ocb.h21
1 files changed, 11 insertions, 10 deletions
diff --git a/src/filters/modes/ocb/ocb.h b/src/filters/modes/ocb/ocb.h
index 0c26fb7d6..5497b08a4 100644
--- a/src/filters/modes/ocb/ocb.h
+++ b/src/filters/modes/ocb/ocb.h
@@ -31,16 +31,8 @@ class BOTAN_DLL OCB_Mode : public AEAD_Mode,
private Buffered_Filter
{
public:
- /**
- * @param cipher the 128-bit block cipher to use
- * @param tag_size is how big the auth tag will be
- * @param decrypting true if decrypting
- */
- OCB_Mode(BlockCipher* cipher, size_t tag_size, bool decrypting);
-
- ~OCB_Mode();
-
void set_key(const SymmetricKey& key) override;
+
void set_nonce(const byte nonce[], size_t nonce_len) override;
void set_associated_data(const byte ad[], size_t ad_len) override;
@@ -54,8 +46,17 @@ class BOTAN_DLL OCB_Mode : public AEAD_Mode,
return (length > 0 && length < 16);
}
+ ~OCB_Mode();
+
protected:
- static const size_t BS = 16;
+ /**
+ * @param cipher the 128-bit block cipher to use
+ * @param tag_size is how big the auth tag will be
+ * @param decrypting true if decrypting
+ */
+ OCB_Mode(BlockCipher* cipher, size_t tag_size, bool decrypting);
+
+ static const size_t BS = 16; // intrinsic to OCB definition
// fixme make these private
std::unique_ptr<BlockCipher> m_cipher;