aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/modes/aead
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2016-01-10 00:51:48 -0500
committerJack Lloyd <[email protected]>2016-01-10 00:51:48 -0500
commit45124582e3b964800f0be1f88773dd6f2cafc672 (patch)
tree9bd788556ddf9731e466b7f24a16e604f662ea24 /src/lib/modes/aead
parent672d29570e55686b90126b5d6f5d337ddf0b8f04 (diff)
Add final attribute to many classes
In some cases this can offer better optimization, via devirtualization. And it lets the user know the class is not intended for derivation. Some discussion in GH #402
Diffstat (limited to 'src/lib/modes/aead')
-rw-r--r--src/lib/modes/aead/ccm/ccm.h4
-rw-r--r--src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h4
-rw-r--r--src/lib/modes/aead/eax/eax.h4
-rw-r--r--src/lib/modes/aead/gcm/gcm.h4
-rw-r--r--src/lib/modes/aead/ocb/ocb.h4
-rw-r--r--src/lib/modes/aead/siv/siv.h4
6 files changed, 12 insertions, 12 deletions
diff --git a/src/lib/modes/aead/ccm/ccm.h b/src/lib/modes/aead/ccm/ccm.h
index 58ca447e8..8277a8f93 100644
--- a/src/lib/modes/aead/ccm/ccm.h
+++ b/src/lib/modes/aead/ccm/ccm.h
@@ -74,7 +74,7 @@ class BOTAN_DLL CCM_Mode : public AEAD_Mode
/**
* CCM Encryption
*/
-class BOTAN_DLL CCM_Encryption : public CCM_Mode
+class BOTAN_DLL CCM_Encryption final : public CCM_Mode
{
public:
/**
@@ -98,7 +98,7 @@ class BOTAN_DLL CCM_Encryption : public CCM_Mode
/**
* CCM Decryption
*/
-class BOTAN_DLL CCM_Decryption : public CCM_Mode
+class BOTAN_DLL CCM_Decryption final : public CCM_Mode
{
public:
/**
diff --git a/src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h b/src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h
index f496590af..5aa2dc010 100644
--- a/src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h
+++ b/src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h
@@ -58,7 +58,7 @@ class BOTAN_DLL ChaCha20Poly1305_Mode : public AEAD_Mode
/**
* ChaCha20Poly1305 Encryption
*/
-class BOTAN_DLL ChaCha20Poly1305_Encryption : public ChaCha20Poly1305_Mode
+class BOTAN_DLL ChaCha20Poly1305_Encryption final : public ChaCha20Poly1305_Mode
{
public:
size_t output_length(size_t input_length) const override
@@ -74,7 +74,7 @@ class BOTAN_DLL ChaCha20Poly1305_Encryption : public ChaCha20Poly1305_Mode
/**
* ChaCha20Poly1305 Decryption
*/
-class BOTAN_DLL ChaCha20Poly1305_Decryption : public ChaCha20Poly1305_Mode
+class BOTAN_DLL ChaCha20Poly1305_Decryption final : public ChaCha20Poly1305_Mode
{
public:
size_t output_length(size_t input_length) const override
diff --git a/src/lib/modes/aead/eax/eax.h b/src/lib/modes/aead/eax/eax.h
index 970bb9d43..e3d942d5e 100644
--- a/src/lib/modes/aead/eax/eax.h
+++ b/src/lib/modes/aead/eax/eax.h
@@ -62,7 +62,7 @@ class BOTAN_DLL EAX_Mode : public AEAD_Mode
/**
* EAX Encryption
*/
-class BOTAN_DLL EAX_Encryption : public EAX_Mode
+class BOTAN_DLL EAX_Encryption final : public EAX_Mode
{
public:
/**
@@ -85,7 +85,7 @@ class BOTAN_DLL EAX_Encryption : public EAX_Mode
/**
* EAX Decryption
*/
-class BOTAN_DLL EAX_Decryption : public EAX_Mode
+class BOTAN_DLL EAX_Decryption final : public EAX_Mode
{
public:
/**
diff --git a/src/lib/modes/aead/gcm/gcm.h b/src/lib/modes/aead/gcm/gcm.h
index 88afbb43c..ba0d6cad8 100644
--- a/src/lib/modes/aead/gcm/gcm.h
+++ b/src/lib/modes/aead/gcm/gcm.h
@@ -55,7 +55,7 @@ class BOTAN_DLL GCM_Mode : public AEAD_Mode
/**
* GCM Encryption
*/
-class BOTAN_DLL GCM_Encryption : public GCM_Mode
+class BOTAN_DLL GCM_Encryption final : public GCM_Mode
{
public:
/**
@@ -78,7 +78,7 @@ class BOTAN_DLL GCM_Encryption : public GCM_Mode
/**
* GCM Decryption
*/
-class BOTAN_DLL GCM_Decryption : public GCM_Mode
+class BOTAN_DLL GCM_Decryption final : public GCM_Mode
{
public:
/**
diff --git a/src/lib/modes/aead/ocb/ocb.h b/src/lib/modes/aead/ocb/ocb.h
index 53723a730..92edce970 100644
--- a/src/lib/modes/aead/ocb/ocb.h
+++ b/src/lib/modes/aead/ocb/ocb.h
@@ -73,7 +73,7 @@ class BOTAN_DLL OCB_Mode : public AEAD_Mode
secure_vector<byte> m_stretch;
};
-class BOTAN_DLL OCB_Encryption : public OCB_Mode
+class BOTAN_DLL OCB_Encryption final : public OCB_Mode
{
public:
/**
@@ -95,7 +95,7 @@ class BOTAN_DLL OCB_Encryption : public OCB_Mode
void encrypt(byte input[], size_t blocks);
};
-class BOTAN_DLL OCB_Decryption : public OCB_Mode
+class BOTAN_DLL OCB_Decryption final : public OCB_Mode
{
public:
/**
diff --git a/src/lib/modes/aead/siv/siv.h b/src/lib/modes/aead/siv/siv.h
index 8336026cb..d46c7dcfd 100644
--- a/src/lib/modes/aead/siv/siv.h
+++ b/src/lib/modes/aead/siv/siv.h
@@ -67,7 +67,7 @@ class BOTAN_DLL SIV_Mode : public AEAD_Mode
/**
* SIV Encryption
*/
-class BOTAN_DLL SIV_Encryption : public SIV_Mode
+class BOTAN_DLL SIV_Encryption final : public SIV_Mode
{
public:
/**
@@ -86,7 +86,7 @@ class BOTAN_DLL SIV_Encryption : public SIV_Mode
/**
* SIV Decryption
*/
-class BOTAN_DLL SIV_Decryption : public SIV_Mode
+class BOTAN_DLL SIV_Decryption final : public SIV_Mode
{
public:
/**