From 12c4dfec24e999ab80ff3a45e0b837976d4c390c Mon Sep 17 00:00:00 2001 From: Jack Lloyd Date: Tue, 27 Dec 2016 15:48:00 -0500 Subject: Add API stability annotations. Defined in build.h, all equal to BOTAN_DLL so ties into existing system for exporting symbols. --- src/lib/asn1/alg_id.h | 6 +++--- src/lib/asn1/asn1_alt_name.h | 2 +- src/lib/asn1/asn1_attribute.h | 2 +- src/lib/asn1/asn1_obj.h | 8 ++++---- src/lib/asn1/asn1_oid.h | 8 ++++---- src/lib/asn1/asn1_str.h | 2 +- src/lib/asn1/asn1_time.h | 14 +++++++------- src/lib/asn1/ber_dec.h | 2 +- src/lib/asn1/der_enc.h | 2 +- src/lib/asn1/oids.h | 4 ++-- src/lib/asn1/x509_dn.h | 12 ++++++------ 11 files changed, 31 insertions(+), 31 deletions(-) (limited to 'src/lib/asn1') diff --git a/src/lib/asn1/alg_id.h b/src/lib/asn1/alg_id.h index 0a1ed0c66..60cf036f4 100644 --- a/src/lib/asn1/alg_id.h +++ b/src/lib/asn1/alg_id.h @@ -17,7 +17,7 @@ namespace Botan { /** * Algorithm Identifier */ -class BOTAN_DLL AlgorithmIdentifier final : public ASN1_Object +class BOTAN_PUBLIC_API(2,0) AlgorithmIdentifier final : public ASN1_Object { public: enum Encoding_Option { USE_NULL_PARAM }; @@ -42,9 +42,9 @@ class BOTAN_DLL AlgorithmIdentifier final : public ASN1_Object /* * Comparison Operations */ -bool BOTAN_DLL operator==(const AlgorithmIdentifier&, +bool BOTAN_PUBLIC_API(2,0) operator==(const AlgorithmIdentifier&, const AlgorithmIdentifier&); -bool BOTAN_DLL operator!=(const AlgorithmIdentifier&, +bool BOTAN_PUBLIC_API(2,0) operator!=(const AlgorithmIdentifier&, const AlgorithmIdentifier&); } diff --git a/src/lib/asn1/asn1_alt_name.h b/src/lib/asn1/asn1_alt_name.h index 5ea7cfb14..65baba0e2 100644 --- a/src/lib/asn1/asn1_alt_name.h +++ b/src/lib/asn1/asn1_alt_name.h @@ -19,7 +19,7 @@ namespace Botan { /** * Alternative Name */ -class BOTAN_DLL AlternativeName final : public ASN1_Object +class BOTAN_PUBLIC_API(2,0) AlternativeName final : public ASN1_Object { public: void encode_into(class DER_Encoder&) const override; diff --git a/src/lib/asn1/asn1_attribute.h b/src/lib/asn1/asn1_attribute.h index 24d4a4bf1..c545c4c0c 100644 --- a/src/lib/asn1/asn1_attribute.h +++ b/src/lib/asn1/asn1_attribute.h @@ -17,7 +17,7 @@ namespace Botan { /** * Attribute */ -class BOTAN_DLL Attribute final : public ASN1_Object +class BOTAN_PUBLIC_API(2,0) Attribute final : public ASN1_Object { public: void encode_into(class DER_Encoder& to) const override; diff --git a/src/lib/asn1/asn1_obj.h b/src/lib/asn1/asn1_obj.h index 536f75ced..2d349c984 100644 --- a/src/lib/asn1/asn1_obj.h +++ b/src/lib/asn1/asn1_obj.h @@ -58,7 +58,7 @@ enum ASN1_Tag { /** * Basic ASN.1 Object Interface */ -class BOTAN_DLL ASN1_Object +class BOTAN_PUBLIC_API(2,0) ASN1_Object { public: /** @@ -82,7 +82,7 @@ class BOTAN_DLL ASN1_Object /** * BER Encoded Object */ -class BOTAN_DLL BER_Object +class BOTAN_PUBLIC_API(2,0) BER_Object { public: void assert_is_a(ASN1_Tag, ASN1_Tag); @@ -115,7 +115,7 @@ bool maybe_BER(DataSource& src); /** * General BER Decoding Error Exception */ -struct BOTAN_DLL BER_Decoding_Error : public Decoding_Error +struct BOTAN_PUBLIC_API(2,0) BER_Decoding_Error : public Decoding_Error { explicit BER_Decoding_Error(const std::string&); }; @@ -123,7 +123,7 @@ struct BOTAN_DLL BER_Decoding_Error : public Decoding_Error /** * Exception For Incorrect BER Taggings */ -struct BOTAN_DLL BER_Bad_Tag : public BER_Decoding_Error +struct BOTAN_PUBLIC_API(2,0) BER_Bad_Tag : public BER_Decoding_Error { BER_Bad_Tag(const std::string& msg, ASN1_Tag tag); BER_Bad_Tag(const std::string& msg, ASN1_Tag tag1, ASN1_Tag tag2); diff --git a/src/lib/asn1/asn1_oid.h b/src/lib/asn1/asn1_oid.h index 0275b58a9..4cf6e8a93 100644 --- a/src/lib/asn1/asn1_oid.h +++ b/src/lib/asn1/asn1_oid.h @@ -17,7 +17,7 @@ namespace Botan { /** * This class represents ASN.1 object identifiers. */ -class BOTAN_DLL OID final : public ASN1_Object +class BOTAN_PUBLIC_API(2,0) OID final : public ASN1_Object { public: void encode_into(class DER_Encoder&) const override; @@ -73,7 +73,7 @@ class BOTAN_DLL OID final : public ASN1_Object * @param oid the OID to add the new component to * @param new_comp the new component to add */ -OID BOTAN_DLL operator+(const OID& oid, uint32_t new_comp); +OID BOTAN_PUBLIC_API(2,0) operator+(const OID& oid, uint32_t new_comp); /** * Compare two OIDs. @@ -81,7 +81,7 @@ OID BOTAN_DLL operator+(const OID& oid, uint32_t new_comp); * @param b the second OID * @return true if a is not equal to b */ -bool BOTAN_DLL operator!=(const OID& a, const OID& b); +bool BOTAN_PUBLIC_API(2,0) operator!=(const OID& a, const OID& b); /** * Compare two OIDs. @@ -89,7 +89,7 @@ bool BOTAN_DLL operator!=(const OID& a, const OID& b); * @param b the second OID * @return true if a is lexicographically smaller than b */ -bool BOTAN_DLL operator<(const OID& a, const OID& b); +bool BOTAN_PUBLIC_API(2,0) operator<(const OID& a, const OID& b); } diff --git a/src/lib/asn1/asn1_str.h b/src/lib/asn1/asn1_str.h index 1d75ec519..42db68f4a 100644 --- a/src/lib/asn1/asn1_str.h +++ b/src/lib/asn1/asn1_str.h @@ -15,7 +15,7 @@ namespace Botan { /** * Simple String */ -class BOTAN_DLL ASN1_String final : public ASN1_Object +class BOTAN_PUBLIC_API(2,0) ASN1_String final : public ASN1_Object { public: void encode_into(class DER_Encoder&) const override; diff --git a/src/lib/asn1/asn1_time.h b/src/lib/asn1/asn1_time.h index 99047e475..4e47e5079 100644 --- a/src/lib/asn1/asn1_time.h +++ b/src/lib/asn1/asn1_time.h @@ -16,7 +16,7 @@ namespace Botan { /** * X.509 Time */ -class BOTAN_DLL X509_Time final : public ASN1_Object +class BOTAN_PUBLIC_API(2,0) X509_Time final : public ASN1_Object { public: /// DER encode a X509_Time @@ -65,12 +65,12 @@ class BOTAN_DLL X509_Time final : public ASN1_Object /* * Comparison Operations */ -bool BOTAN_DLL operator==(const X509_Time&, const X509_Time&); -bool BOTAN_DLL operator!=(const X509_Time&, const X509_Time&); -bool BOTAN_DLL operator<=(const X509_Time&, const X509_Time&); -bool BOTAN_DLL operator>=(const X509_Time&, const X509_Time&); -bool BOTAN_DLL operator<(const X509_Time&, const X509_Time&); -bool BOTAN_DLL operator>(const X509_Time&, const X509_Time&); +bool BOTAN_PUBLIC_API(2,0) operator==(const X509_Time&, const X509_Time&); +bool BOTAN_PUBLIC_API(2,0) operator!=(const X509_Time&, const X509_Time&); +bool BOTAN_PUBLIC_API(2,0) operator<=(const X509_Time&, const X509_Time&); +bool BOTAN_PUBLIC_API(2,0) operator>=(const X509_Time&, const X509_Time&); +bool BOTAN_PUBLIC_API(2,0) operator<(const X509_Time&, const X509_Time&); +bool BOTAN_PUBLIC_API(2,0) operator>(const X509_Time&, const X509_Time&); } diff --git a/src/lib/asn1/ber_dec.h b/src/lib/asn1/ber_dec.h index 6320ab9fc..77eb6a1a8 100644 --- a/src/lib/asn1/ber_dec.h +++ b/src/lib/asn1/ber_dec.h @@ -16,7 +16,7 @@ namespace Botan { /** * BER Decoding Object */ -class BOTAN_DLL BER_Decoder +class BOTAN_PUBLIC_API(2,0) BER_Decoder { public: BER_Object get_next_object(); diff --git a/src/lib/asn1/der_enc.h b/src/lib/asn1/der_enc.h index 22a8741c6..fcfe63154 100644 --- a/src/lib/asn1/der_enc.h +++ b/src/lib/asn1/der_enc.h @@ -19,7 +19,7 @@ class ASN1_Object; /** * General DER Encoding Object */ -class BOTAN_DLL DER_Encoder +class BOTAN_PUBLIC_API(2,0) DER_Encoder { public: secure_vector get_contents(); diff --git a/src/lib/asn1/oids.h b/src/lib/asn1/oids.h index 16b87dfc3..7e1dc7c8f 100644 --- a/src/lib/asn1/oids.h +++ b/src/lib/asn1/oids.h @@ -19,7 +19,7 @@ namespace OIDS { * @param oid the OID to look up * @return name associated with this OID */ -BOTAN_DLL std::string lookup(const OID& oid); +BOTAN_PUBLIC_API(2,0) std::string lookup(const OID& oid); /** * Find the OID to a name. The lookup will be performed in the @@ -27,7 +27,7 @@ BOTAN_DLL std::string lookup(const OID& oid); * @param name the name to resolve * @return OID associated with the specified name */ -BOTAN_DLL OID lookup(const std::string& name); +BOTAN_PUBLIC_API(2,0) OID lookup(const std::string& name); /** * See if an OID exists in the internal table. diff --git a/src/lib/asn1/x509_dn.h b/src/lib/asn1/x509_dn.h index 8add8d64c..164c2b64c 100644 --- a/src/lib/asn1/x509_dn.h +++ b/src/lib/asn1/x509_dn.h @@ -19,7 +19,7 @@ namespace Botan { /** * Distinguished Name */ -class BOTAN_DLL X509_DN final : public ASN1_Object +class BOTAN_PUBLIC_API(2,0) X509_DN final : public ASN1_Object { public: void encode_into(class DER_Encoder&) const override; @@ -47,12 +47,12 @@ class BOTAN_DLL X509_DN final : public ASN1_Object std::vector m_dn_bits; }; -bool BOTAN_DLL operator==(const X509_DN&, const X509_DN&); -bool BOTAN_DLL operator!=(const X509_DN&, const X509_DN&); -bool BOTAN_DLL operator<(const X509_DN&, const X509_DN&); +bool BOTAN_PUBLIC_API(2,0) operator==(const X509_DN&, const X509_DN&); +bool BOTAN_PUBLIC_API(2,0) operator!=(const X509_DN&, const X509_DN&); +bool BOTAN_PUBLIC_API(2,0) operator<(const X509_DN&, const X509_DN&); -BOTAN_DLL std::ostream& operator<<(std::ostream& out, const X509_DN& dn); -BOTAN_DLL std::istream& operator>>(std::istream& in, X509_DN& dn); +BOTAN_PUBLIC_API(2,0) std::ostream& operator<<(std::ostream& out, const X509_DN& dn); +BOTAN_PUBLIC_API(2,0) std::istream& operator>>(std::istream& in, X509_DN& dn); } -- cgit v1.2.3