aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/modes
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2016-12-27 15:48:00 -0500
committerJack Lloyd <[email protected]>2017-09-19 22:30:41 -0400
commit12c4dfec24e999ab80ff3a45e0b837976d4c390c (patch)
tree7de91a2b86aec055800b8e046729fcc10a31d6d8 /src/lib/modes
parent0c6c4e058109791a9f17971ca782dc10af3eb9bc (diff)
Add API stability annotations.
Defined in build.h, all equal to BOTAN_DLL so ties into existing system for exporting symbols.
Diffstat (limited to 'src/lib/modes')
-rw-r--r--src/lib/modes/aead/aead.h4
-rw-r--r--src/lib/modes/aead/ccm/ccm.h6
-rw-r--r--src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h6
-rw-r--r--src/lib/modes/aead/eax/eax.h6
-rw-r--r--src/lib/modes/aead/gcm/gcm.h8
-rw-r--r--src/lib/modes/aead/ocb/ocb.h6
-rw-r--r--src/lib/modes/aead/siv/siv.h6
-rw-r--r--src/lib/modes/cbc/cbc.h10
-rw-r--r--src/lib/modes/cfb/cfb.h6
-rw-r--r--src/lib/modes/mode_pad/mode_pad.h14
-rw-r--r--src/lib/modes/stream_mode.h2
-rw-r--r--src/lib/modes/xts/xts.h6
12 files changed, 40 insertions, 40 deletions
diff --git a/src/lib/modes/aead/aead.h b/src/lib/modes/aead/aead.h
index a0b11541b..95a595542 100644
--- a/src/lib/modes/aead/aead.h
+++ b/src/lib/modes/aead/aead.h
@@ -19,7 +19,7 @@ namespace Botan {
* which is not included in the ciphertext (for instance a sequence
* number).
*/
-class BOTAN_DLL AEAD_Mode : public Cipher_Mode
+class BOTAN_PUBLIC_API(2,0) AEAD_Mode : public Cipher_Mode
{
public:
bool authenticated() const override { return true; }
@@ -82,7 +82,7 @@ class BOTAN_DLL AEAD_Mode : public Cipher_Mode
* @param name AEAD name
* @param direction ENCRYPTION or DECRYPTION
*/
-BOTAN_DLL AEAD_Mode* get_aead(const std::string& name, Cipher_Dir direction);
+BOTAN_PUBLIC_API(2,0) AEAD_Mode* get_aead(const std::string& name, Cipher_Dir direction);
}
diff --git a/src/lib/modes/aead/ccm/ccm.h b/src/lib/modes/aead/ccm/ccm.h
index 93dd0d7e1..636df6fa7 100644
--- a/src/lib/modes/aead/ccm/ccm.h
+++ b/src/lib/modes/aead/ccm/ccm.h
@@ -20,7 +20,7 @@ namespace Botan {
* Base class for CCM encryption and decryption
* @see RFC 3610
*/
-class BOTAN_DLL CCM_Mode : public AEAD_Mode
+class BOTAN_PUBLIC_API(2,0) CCM_Mode : public AEAD_Mode
{
public:
size_t process(uint8_t buf[], size_t sz) override;
@@ -75,7 +75,7 @@ class BOTAN_DLL CCM_Mode : public AEAD_Mode
/**
* CCM Encryption
*/
-class BOTAN_DLL CCM_Encryption final : public CCM_Mode
+class BOTAN_PUBLIC_API(2,0) CCM_Encryption final : public CCM_Mode
{
public:
/**
@@ -99,7 +99,7 @@ class BOTAN_DLL CCM_Encryption final : public CCM_Mode
/**
* CCM Decryption
*/
-class BOTAN_DLL CCM_Decryption final : public CCM_Mode
+class BOTAN_PUBLIC_API(2,0) 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 4245e5e01..bbe21fdba 100644
--- a/src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h
+++ b/src/lib/modes/aead/chacha20poly1305/chacha20poly1305.h
@@ -21,7 +21,7 @@ namespace Botan {
* If a nonce of 64 bits is used the older version described in
* draft-agl-tls-chacha20poly1305-04 is used instead.
*/
-class BOTAN_DLL ChaCha20Poly1305_Mode : public AEAD_Mode
+class BOTAN_PUBLIC_API(2,0) ChaCha20Poly1305_Mode : public AEAD_Mode
{
public:
void set_associated_data(const uint8_t ad[], size_t ad_len) override;
@@ -62,7 +62,7 @@ class BOTAN_DLL ChaCha20Poly1305_Mode : public AEAD_Mode
/**
* ChaCha20Poly1305 Encryption
*/
-class BOTAN_DLL ChaCha20Poly1305_Encryption final : public ChaCha20Poly1305_Mode
+class BOTAN_PUBLIC_API(2,0) ChaCha20Poly1305_Encryption final : public ChaCha20Poly1305_Mode
{
public:
size_t output_length(size_t input_length) const override
@@ -78,7 +78,7 @@ class BOTAN_DLL ChaCha20Poly1305_Encryption final : public ChaCha20Poly1305_Mode
/**
* ChaCha20Poly1305 Decryption
*/
-class BOTAN_DLL ChaCha20Poly1305_Decryption final : public ChaCha20Poly1305_Mode
+class BOTAN_PUBLIC_API(2,0) 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 fc991ab1f..67679dcc2 100644
--- a/src/lib/modes/aead/eax/eax.h
+++ b/src/lib/modes/aead/eax/eax.h
@@ -19,7 +19,7 @@ namespace Botan {
/**
* EAX base class
*/
-class BOTAN_DLL EAX_Mode : public AEAD_Mode
+class BOTAN_PUBLIC_API(2,0) EAX_Mode : public AEAD_Mode
{
public:
void set_associated_data(const uint8_t ad[], size_t ad_len) override;
@@ -66,7 +66,7 @@ class BOTAN_DLL EAX_Mode : public AEAD_Mode
/**
* EAX Encryption
*/
-class BOTAN_DLL EAX_Encryption final : public EAX_Mode
+class BOTAN_PUBLIC_API(2,0) EAX_Encryption final : public EAX_Mode
{
public:
/**
@@ -89,7 +89,7 @@ class BOTAN_DLL EAX_Encryption final : public EAX_Mode
/**
* EAX Decryption
*/
-class BOTAN_DLL EAX_Decryption final : public EAX_Mode
+class BOTAN_PUBLIC_API(2,0) 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 e2e3a2c9d..0326533ff 100644
--- a/src/lib/modes/aead/gcm/gcm.h
+++ b/src/lib/modes/aead/gcm/gcm.h
@@ -20,7 +20,7 @@ class GHASH;
/**
* GCM Mode
*/
-class BOTAN_DLL GCM_Mode : public AEAD_Mode
+class BOTAN_PUBLIC_API(2,0) GCM_Mode : public AEAD_Mode
{
public:
void set_associated_data(const uint8_t ad[], size_t ad_len) override;
@@ -60,7 +60,7 @@ class BOTAN_DLL GCM_Mode : public AEAD_Mode
/**
* GCM Encryption
*/
-class BOTAN_DLL GCM_Encryption final : public GCM_Mode
+class BOTAN_PUBLIC_API(2,0) GCM_Encryption final : public GCM_Mode
{
public:
/**
@@ -83,7 +83,7 @@ class BOTAN_DLL GCM_Encryption final : public GCM_Mode
/**
* GCM Decryption
*/
-class BOTAN_DLL GCM_Decryption final : public GCM_Mode
+class BOTAN_PUBLIC_API(2,0) GCM_Decryption final : public GCM_Mode
{
public:
/**
@@ -110,7 +110,7 @@ class BOTAN_DLL GCM_Decryption final : public GCM_Mode
* GCM's GHASH
* Maybe a Transform?
*/
-class BOTAN_DLL GHASH : public SymmetricAlgorithm
+class BOTAN_PUBLIC_API(2,0) GHASH : public SymmetricAlgorithm
{
public:
void set_associated_data(const uint8_t ad[], size_t ad_len);
diff --git a/src/lib/modes/aead/ocb/ocb.h b/src/lib/modes/aead/ocb/ocb.h
index 69f5fde60..4c06527ba 100644
--- a/src/lib/modes/aead/ocb/ocb.h
+++ b/src/lib/modes/aead/ocb/ocb.h
@@ -28,7 +28,7 @@ class L_computer;
* @see Free Licenses http://www.cs.ucdavis.edu/~rogaway/ocb/license.htm
* @see OCB home page http://www.cs.ucdavis.edu/~rogaway/ocb
*/
-class BOTAN_DLL OCB_Mode : public AEAD_Mode
+class BOTAN_PUBLIC_API(2,0) OCB_Mode : public AEAD_Mode
{
public:
void set_associated_data(const uint8_t ad[], size_t ad_len) override;
@@ -76,7 +76,7 @@ class BOTAN_DLL OCB_Mode : public AEAD_Mode
secure_vector<uint8_t> m_stretch;
};
-class BOTAN_DLL OCB_Encryption final : public OCB_Mode
+class BOTAN_PUBLIC_API(2,0) OCB_Encryption final : public OCB_Mode
{
public:
/**
@@ -98,7 +98,7 @@ class BOTAN_DLL OCB_Encryption final : public OCB_Mode
void encrypt(uint8_t input[], size_t blocks);
};
-class BOTAN_DLL OCB_Decryption final : public OCB_Mode
+class BOTAN_PUBLIC_API(2,0) 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 ea6ad8234..3266c6644 100644
--- a/src/lib/modes/aead/siv/siv.h
+++ b/src/lib/modes/aead/siv/siv.h
@@ -19,7 +19,7 @@ namespace Botan {
/**
* Base class for SIV encryption and decryption (@see RFC 5297)
*/
-class BOTAN_DLL SIV_Mode : public AEAD_Mode
+class BOTAN_PUBLIC_API(2,0) SIV_Mode : public AEAD_Mode
{
public:
size_t process(uint8_t buf[], size_t size) override;
@@ -76,7 +76,7 @@ class BOTAN_DLL SIV_Mode : public AEAD_Mode
/**
* SIV Encryption
*/
-class BOTAN_DLL SIV_Encryption final : public SIV_Mode
+class BOTAN_PUBLIC_API(2,0) SIV_Encryption final : public SIV_Mode
{
public:
/**
@@ -95,7 +95,7 @@ class BOTAN_DLL SIV_Encryption final : public SIV_Mode
/**
* SIV Decryption
*/
-class BOTAN_DLL SIV_Decryption final : public SIV_Mode
+class BOTAN_PUBLIC_API(2,0) SIV_Decryption final : public SIV_Mode
{
public:
/**
diff --git a/src/lib/modes/cbc/cbc.h b/src/lib/modes/cbc/cbc.h
index 54b574981..f088b817b 100644
--- a/src/lib/modes/cbc/cbc.h
+++ b/src/lib/modes/cbc/cbc.h
@@ -18,7 +18,7 @@ namespace Botan {
/**
* CBC Mode
*/
-class BOTAN_DLL CBC_Mode : public Cipher_Mode
+class BOTAN_PUBLIC_API(2,0) CBC_Mode : public Cipher_Mode
{
public:
std::string name() const override;
@@ -65,7 +65,7 @@ class BOTAN_DLL CBC_Mode : public Cipher_Mode
/**
* CBC Encryption
*/
-class BOTAN_DLL CBC_Encryption : public CBC_Mode
+class BOTAN_PUBLIC_API(2,0) CBC_Encryption : public CBC_Mode
{
public:
/**
@@ -87,7 +87,7 @@ class BOTAN_DLL CBC_Encryption : public CBC_Mode
/**
* CBC Encryption with ciphertext stealing (CBC-CS3 variant)
*/
-class BOTAN_DLL CTS_Encryption final : public CBC_Encryption
+class BOTAN_PUBLIC_API(2,0) CTS_Encryption final : public CBC_Encryption
{
public:
/**
@@ -107,7 +107,7 @@ class BOTAN_DLL CTS_Encryption final : public CBC_Encryption
/**
* CBC Decryption
*/
-class BOTAN_DLL CBC_Decryption : public CBC_Mode
+class BOTAN_PUBLIC_API(2,0) CBC_Decryption : public CBC_Mode
{
public:
/**
@@ -134,7 +134,7 @@ class BOTAN_DLL CBC_Decryption : public CBC_Mode
/**
* CBC Decryption with ciphertext stealing (CBC-CS3 variant)
*/
-class BOTAN_DLL CTS_Decryption final : public CBC_Decryption
+class BOTAN_PUBLIC_API(2,0) CTS_Decryption final : public CBC_Decryption
{
public:
/**
diff --git a/src/lib/modes/cfb/cfb.h b/src/lib/modes/cfb/cfb.h
index ce85d2c2e..14e4e3d0e 100644
--- a/src/lib/modes/cfb/cfb.h
+++ b/src/lib/modes/cfb/cfb.h
@@ -17,7 +17,7 @@ namespace Botan {
/**
* CFB Mode
*/
-class BOTAN_DLL CFB_Mode : public Cipher_Mode
+class BOTAN_PUBLIC_API(2,0) CFB_Mode : public Cipher_Mode
{
public:
std::string name() const override;
@@ -58,7 +58,7 @@ class BOTAN_DLL CFB_Mode : public Cipher_Mode
/**
* CFB Encryption
*/
-class BOTAN_DLL CFB_Encryption final : public CFB_Mode
+class BOTAN_PUBLIC_API(2,0) CFB_Encryption final : public CFB_Mode
{
public:
/**
@@ -78,7 +78,7 @@ class BOTAN_DLL CFB_Encryption final : public CFB_Mode
/**
* CFB Decryption
*/
-class BOTAN_DLL CFB_Decryption final : public CFB_Mode
+class BOTAN_PUBLIC_API(2,0) CFB_Decryption final : public CFB_Mode
{
public:
/**
diff --git a/src/lib/modes/mode_pad/mode_pad.h b/src/lib/modes/mode_pad/mode_pad.h
index c221882cc..7b54db985 100644
--- a/src/lib/modes/mode_pad/mode_pad.h
+++ b/src/lib/modes/mode_pad/mode_pad.h
@@ -23,7 +23,7 @@ namespace Botan {
* a padding mode for CBC, which happens to consume the last
* two block (and requires use of the block cipher).
*/
-class BOTAN_DLL BlockCipherModePaddingMethod
+class BOTAN_PUBLIC_API(2,0) BlockCipherModePaddingMethod
{
public:
/**
@@ -65,7 +65,7 @@ class BOTAN_DLL BlockCipherModePaddingMethod
/**
* PKCS#7 Padding
*/
-class BOTAN_DLL PKCS7_Padding final : public BlockCipherModePaddingMethod
+class BOTAN_PUBLIC_API(2,0) PKCS7_Padding final : public BlockCipherModePaddingMethod
{
public:
void add_padding(secure_vector<uint8_t>& buffer,
@@ -82,7 +82,7 @@ class BOTAN_DLL PKCS7_Padding final : public BlockCipherModePaddingMethod
/**
* ANSI X9.23 Padding
*/
-class BOTAN_DLL ANSI_X923_Padding final : public BlockCipherModePaddingMethod
+class BOTAN_PUBLIC_API(2,0) ANSI_X923_Padding final : public BlockCipherModePaddingMethod
{
public:
void add_padding(secure_vector<uint8_t>& buffer,
@@ -99,7 +99,7 @@ class BOTAN_DLL ANSI_X923_Padding final : public BlockCipherModePaddingMethod
/**
* One And Zeros Padding (ISO/IEC 9797-1, padding method 2)
*/
-class BOTAN_DLL OneAndZeros_Padding final : public BlockCipherModePaddingMethod
+class BOTAN_PUBLIC_API(2,0) OneAndZeros_Padding final : public BlockCipherModePaddingMethod
{
public:
void add_padding(secure_vector<uint8_t>& buffer,
@@ -116,7 +116,7 @@ class BOTAN_DLL OneAndZeros_Padding final : public BlockCipherModePaddingMethod
/**
* ESP Padding (RFC 4304)
*/
-class BOTAN_DLL ESP_Padding final : public BlockCipherModePaddingMethod
+class BOTAN_PUBLIC_API(2,0) ESP_Padding final : public BlockCipherModePaddingMethod
{
public:
void add_padding(secure_vector<uint8_t>& buffer,
@@ -133,7 +133,7 @@ class BOTAN_DLL ESP_Padding final : public BlockCipherModePaddingMethod
/**
* Null Padding
*/
-class BOTAN_DLL Null_Padding final : public BlockCipherModePaddingMethod
+class BOTAN_PUBLIC_API(2,0) Null_Padding final : public BlockCipherModePaddingMethod
{
public:
void add_padding(secure_vector<uint8_t>&, size_t, size_t) const override {}
@@ -149,7 +149,7 @@ class BOTAN_DLL Null_Padding final : public BlockCipherModePaddingMethod
* Get a block cipher padding mode by name (eg "NoPadding" or "PKCS7")
* @param algo_spec block cipher padding mode name
*/
-BOTAN_DLL BlockCipherModePaddingMethod* get_bc_pad(const std::string& algo_spec);
+BOTAN_PUBLIC_API(2,0) BlockCipherModePaddingMethod* get_bc_pad(const std::string& algo_spec);
}
diff --git a/src/lib/modes/stream_mode.h b/src/lib/modes/stream_mode.h
index 27a94a7c7..bee740b3a 100644
--- a/src/lib/modes/stream_mode.h
+++ b/src/lib/modes/stream_mode.h
@@ -13,7 +13,7 @@
namespace Botan {
-class BOTAN_DLL Stream_Cipher_Mode : public Cipher_Mode
+class BOTAN_PUBLIC_API(2,0) Stream_Cipher_Mode : public Cipher_Mode
{
public:
/**
diff --git a/src/lib/modes/xts/xts.h b/src/lib/modes/xts/xts.h
index 69715c8b9..2c19d7172 100644
--- a/src/lib/modes/xts/xts.h
+++ b/src/lib/modes/xts/xts.h
@@ -17,7 +17,7 @@ namespace Botan {
/**
* IEEE P1619 XTS Mode
*/
-class BOTAN_DLL XTS_Mode : public Cipher_Mode
+class BOTAN_PUBLIC_API(2,0) XTS_Mode : public Cipher_Mode
{
public:
std::string name() const override;
@@ -56,7 +56,7 @@ class BOTAN_DLL XTS_Mode : public Cipher_Mode
/**
* IEEE P1619 XTS Encryption
*/
-class BOTAN_DLL XTS_Encryption final : public XTS_Mode
+class BOTAN_PUBLIC_API(2,0) XTS_Encryption final : public XTS_Mode
{
public:
/**
@@ -74,7 +74,7 @@ class BOTAN_DLL XTS_Encryption final : public XTS_Mode
/**
* IEEE P1619 XTS Decryption
*/
-class BOTAN_DLL XTS_Decryption final : public XTS_Mode
+class BOTAN_PUBLIC_API(2,0) XTS_Decryption final : public XTS_Mode
{
public:
/**