aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorlloyd <[email protected]>2008-09-24 14:44:01 +0000
committerlloyd <[email protected]>2008-09-24 14:44:01 +0000
commit5a120e856c78973d1a75bf6b6db9716367038166 (patch)
tree1137ae6c7560182c05a785dd8412787a35e49d76 /include
parent52750a635deee0f526492f905e4f115b13c2d304 (diff)
Expose CMAC::poly_double as a static function since it looks like I may
want to inline the CMAC computation in EAX mode. Also optimize CMAC::final_result slightly. Only write to state directly, instead of also the write buffer (this should help L1 data caching), and avoid what was basically a no-op where we zeroized part of a buffer and then xored it against another buffer.
Diffstat (limited to 'include')
-rw-r--r--include/cmac.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/cmac.h b/include/cmac.h
index de3f8b87a..c7f107258 100644
--- a/include/cmac.h
+++ b/include/cmac.h
@@ -19,6 +19,10 @@ class BOTAN_DLL CMAC : public MessageAuthenticationCode
void clear() throw();
std::string name() const;
MessageAuthenticationCode* clone() const;
+
+ static SecureVector<byte> poly_double(const MemoryRegion<byte>& in,
+ byte polynomial);
+
CMAC(const std::string&);
~CMAC() { delete e; }
private: