// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: proto/securemessage.proto

#ifndef GOOGLE_PROTOBUF_INCLUDED_proto_2fsecuremessage_2eproto
#define GOOGLE_PROTOBUF_INCLUDED_proto_2fsecuremessage_2eproto

#include <limits>
#include <string>

#include <google/protobuf/port_def.inc>
#if PROTOBUF_VERSION < 3019000
#error This file was generated by a newer version of protoc which is
#error incompatible with your Protocol Buffer headers. Please update
#error your headers.
#endif
#if 3019004 < PROTOBUF_MIN_PROTOC_VERSION
#error This file was generated by an older version of protoc which is
#error incompatible with your Protocol Buffer headers. Please
#error regenerate this file with a newer version of protoc.
#endif

#include <google/protobuf/port_undef.inc>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/arena.h>
#include <google/protobuf/arenastring.h>
#include <google/protobuf/generated_message_table_driven.h>
#include <google/protobuf/generated_message_util.h>
#include <google/protobuf/metadata_lite.h>
#include <google/protobuf/message_lite.h>
#include <google/protobuf/repeated_field.h>  // IWYU pragma: export
#include <google/protobuf/extension_set.h>  // IWYU pragma: export
#include <google/protobuf/generated_enum_util.h>
// @@protoc_insertion_point(includes)
#include <google/protobuf/port_def.inc>
#define PROTOBUF_INTERNAL_EXPORT_proto_2fsecuremessage_2eproto
PROTOBUF_NAMESPACE_OPEN
namespace internal {
class AnyMetadata;
}  // namespace internal
PROTOBUF_NAMESPACE_CLOSE

// Internal implementation detail -- do not use these members.
struct TableStruct_proto_2fsecuremessage_2eproto {
  static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTableField entries[]
    PROTOBUF_SECTION_VARIABLE(protodesc_cold);
  static const ::PROTOBUF_NAMESPACE_ID::internal::AuxiliaryParseTableField aux[]
    PROTOBUF_SECTION_VARIABLE(protodesc_cold);
  static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTable schema[8]
    PROTOBUF_SECTION_VARIABLE(protodesc_cold);
  static const ::PROTOBUF_NAMESPACE_ID::internal::FieldMetadata field_metadata[];
  static const ::PROTOBUF_NAMESPACE_ID::internal::SerializationTable serialization_table[];
  static const uint32_t offsets[];
};
namespace securemessage {
class DhPublicKey;
struct DhPublicKeyDefaultTypeInternal;
extern DhPublicKeyDefaultTypeInternal _DhPublicKey_default_instance_;
class EcP256PublicKey;
struct EcP256PublicKeyDefaultTypeInternal;
extern EcP256PublicKeyDefaultTypeInternal _EcP256PublicKey_default_instance_;
class GenericPublicKey;
struct GenericPublicKeyDefaultTypeInternal;
extern GenericPublicKeyDefaultTypeInternal _GenericPublicKey_default_instance_;
class Header;
struct HeaderDefaultTypeInternal;
extern HeaderDefaultTypeInternal _Header_default_instance_;
class HeaderAndBody;
struct HeaderAndBodyDefaultTypeInternal;
extern HeaderAndBodyDefaultTypeInternal _HeaderAndBody_default_instance_;
class HeaderAndBodyInternal;
struct HeaderAndBodyInternalDefaultTypeInternal;
extern HeaderAndBodyInternalDefaultTypeInternal _HeaderAndBodyInternal_default_instance_;
class SecureMessage;
struct SecureMessageDefaultTypeInternal;
extern SecureMessageDefaultTypeInternal _SecureMessage_default_instance_;
class SimpleRsaPublicKey;
struct SimpleRsaPublicKeyDefaultTypeInternal;
extern SimpleRsaPublicKeyDefaultTypeInternal _SimpleRsaPublicKey_default_instance_;
}  // namespace securemessage
PROTOBUF_NAMESPACE_OPEN
template<> ::securemessage::DhPublicKey* Arena::CreateMaybeMessage<::securemessage::DhPublicKey>(Arena*);
template<> ::securemessage::EcP256PublicKey* Arena::CreateMaybeMessage<::securemessage::EcP256PublicKey>(Arena*);
template<> ::securemessage::GenericPublicKey* Arena::CreateMaybeMessage<::securemessage::GenericPublicKey>(Arena*);
template<> ::securemessage::Header* Arena::CreateMaybeMessage<::securemessage::Header>(Arena*);
template<> ::securemessage::HeaderAndBody* Arena::CreateMaybeMessage<::securemessage::HeaderAndBody>(Arena*);
template<> ::securemessage::HeaderAndBodyInternal* Arena::CreateMaybeMessage<::securemessage::HeaderAndBodyInternal>(Arena*);
template<> ::securemessage::SecureMessage* Arena::CreateMaybeMessage<::securemessage::SecureMessage>(Arena*);
template<> ::securemessage::SimpleRsaPublicKey* Arena::CreateMaybeMessage<::securemessage::SimpleRsaPublicKey>(Arena*);
PROTOBUF_NAMESPACE_CLOSE
namespace securemessage {

enum SigScheme : int {
  HMAC_SHA256 = 1,
  ECDSA_P256_SHA256 = 2,
  RSA2048_SHA256 = 3
};
bool SigScheme_IsValid(int value);
constexpr SigScheme SigScheme_MIN = HMAC_SHA256;
constexpr SigScheme SigScheme_MAX = RSA2048_SHA256;
constexpr int SigScheme_ARRAYSIZE = SigScheme_MAX + 1;

const std::string& SigScheme_Name(SigScheme value);
template<typename T>
inline const std::string& SigScheme_Name(T enum_t_value) {
  static_assert(::std::is_same<T, SigScheme>::value ||
    ::std::is_integral<T>::value,
    "Incorrect type passed to function SigScheme_Name.");
  return SigScheme_Name(static_cast<SigScheme>(enum_t_value));
}
bool SigScheme_Parse(
    ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SigScheme* value);
enum EncScheme : int {
  NONE = 1,
  AES_256_CBC = 2
};
bool EncScheme_IsValid(int value);
constexpr EncScheme EncScheme_MIN = NONE;
constexpr EncScheme EncScheme_MAX = AES_256_CBC;
constexpr int EncScheme_ARRAYSIZE = EncScheme_MAX + 1;

const std::string& EncScheme_Name(EncScheme value);
template<typename T>
inline const std::string& EncScheme_Name(T enum_t_value) {
  static_assert(::std::is_same<T, EncScheme>::value ||
    ::std::is_integral<T>::value,
    "Incorrect type passed to function EncScheme_Name.");
  return EncScheme_Name(static_cast<EncScheme>(enum_t_value));
}
bool EncScheme_Parse(
    ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, EncScheme* value);
enum PublicKeyType : int {
  EC_P256 = 1,
  RSA2048 = 2,
  DH2048_MODP = 3
};
bool PublicKeyType_IsValid(int value);
constexpr PublicKeyType PublicKeyType_MIN = EC_P256;
constexpr PublicKeyType PublicKeyType_MAX = DH2048_MODP;
constexpr int PublicKeyType_ARRAYSIZE = PublicKeyType_MAX + 1;

const std::string& PublicKeyType_Name(PublicKeyType value);
template<typename T>
inline const std::string& PublicKeyType_Name(T enum_t_value) {
  static_assert(::std::is_same<T, PublicKeyType>::value ||
    ::std::is_integral<T>::value,
    "Incorrect type passed to function PublicKeyType_Name.");
  return PublicKeyType_Name(static_cast<PublicKeyType>(enum_t_value));
}
bool PublicKeyType_Parse(
    ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, PublicKeyType* value);
// ===================================================================

class SecureMessage final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.SecureMessage) */ {
 public:
  inline SecureMessage() : SecureMessage(nullptr) {}
  ~SecureMessage() override;
  explicit constexpr SecureMessage(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  SecureMessage(const SecureMessage& from);
  SecureMessage(SecureMessage&& from) noexcept
    : SecureMessage() {
    *this = ::std::move(from);
  }

  inline SecureMessage& operator=(const SecureMessage& from) {
    CopyFrom(from);
    return *this;
  }
  inline SecureMessage& operator=(SecureMessage&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const SecureMessage& default_instance() {
    return *internal_default_instance();
  }
  static inline const SecureMessage* internal_default_instance() {
    return reinterpret_cast<const SecureMessage*>(
               &_SecureMessage_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    0;

  friend void swap(SecureMessage& a, SecureMessage& b) {
    a.Swap(&b);
  }
  inline void Swap(SecureMessage* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(SecureMessage* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  SecureMessage* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<SecureMessage>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const SecureMessage& from);
  void MergeFrom(const SecureMessage& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(SecureMessage* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.SecureMessage";
  }
  protected:
  explicit SecureMessage(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kHeaderAndBodyFieldNumber = 1,
    kSignatureFieldNumber = 2,
  };
  // required bytes header_and_body = 1;
  bool has_header_and_body() const;
  private:
  bool _internal_has_header_and_body() const;
  public:
  void clear_header_and_body();
  const std::string& header_and_body() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_header_and_body(ArgT0&& arg0, ArgT... args);
  std::string* mutable_header_and_body();
  PROTOBUF_NODISCARD std::string* release_header_and_body();
  void set_allocated_header_and_body(std::string* header_and_body);
  private:
  const std::string& _internal_header_and_body() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_header_and_body(const std::string& value);
  std::string* _internal_mutable_header_and_body();
  public:

  // required bytes signature = 2;
  bool has_signature() const;
  private:
  bool _internal_has_signature() const;
  public:
  void clear_signature();
  const std::string& signature() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_signature(ArgT0&& arg0, ArgT... args);
  std::string* mutable_signature();
  PROTOBUF_NODISCARD std::string* release_signature();
  void set_allocated_signature(std::string* signature);
  private:
  const std::string& _internal_signature() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_signature(const std::string& value);
  std::string* _internal_mutable_signature();
  public:

  // @@protoc_insertion_point(class_scope:securemessage.SecureMessage)
 private:
  class _Internal;

  // helper for ByteSizeLong()
  size_t RequiredFieldsByteSizeFallback() const;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr header_and_body_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr signature_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// -------------------------------------------------------------------

class Header final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.Header) */ {
 public:
  inline Header() : Header(nullptr) {}
  ~Header() override;
  explicit constexpr Header(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  Header(const Header& from);
  Header(Header&& from) noexcept
    : Header() {
    *this = ::std::move(from);
  }

  inline Header& operator=(const Header& from) {
    CopyFrom(from);
    return *this;
  }
  inline Header& operator=(Header&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const Header& default_instance() {
    return *internal_default_instance();
  }
  static inline const Header* internal_default_instance() {
    return reinterpret_cast<const Header*>(
               &_Header_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    1;

  friend void swap(Header& a, Header& b) {
    a.Swap(&b);
  }
  inline void Swap(Header* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(Header* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  Header* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<Header>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const Header& from);
  void MergeFrom(const Header& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(Header* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.Header";
  }
  protected:
  explicit Header(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kVerificationKeyIdFieldNumber = 3,
    kDecryptionKeyIdFieldNumber = 4,
    kIvFieldNumber = 5,
    kPublicMetadataFieldNumber = 6,
    kAssociatedDataLengthFieldNumber = 7,
    kSignatureSchemeFieldNumber = 1,
    kEncryptionSchemeFieldNumber = 2,
  };
  // optional bytes verification_key_id = 3;
  bool has_verification_key_id() const;
  private:
  bool _internal_has_verification_key_id() const;
  public:
  void clear_verification_key_id();
  const std::string& verification_key_id() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_verification_key_id(ArgT0&& arg0, ArgT... args);
  std::string* mutable_verification_key_id();
  PROTOBUF_NODISCARD std::string* release_verification_key_id();
  void set_allocated_verification_key_id(std::string* verification_key_id);
  private:
  const std::string& _internal_verification_key_id() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_verification_key_id(const std::string& value);
  std::string* _internal_mutable_verification_key_id();
  public:

  // optional bytes decryption_key_id = 4;
  bool has_decryption_key_id() const;
  private:
  bool _internal_has_decryption_key_id() const;
  public:
  void clear_decryption_key_id();
  const std::string& decryption_key_id() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_decryption_key_id(ArgT0&& arg0, ArgT... args);
  std::string* mutable_decryption_key_id();
  PROTOBUF_NODISCARD std::string* release_decryption_key_id();
  void set_allocated_decryption_key_id(std::string* decryption_key_id);
  private:
  const std::string& _internal_decryption_key_id() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_decryption_key_id(const std::string& value);
  std::string* _internal_mutable_decryption_key_id();
  public:

  // optional bytes iv = 5;
  bool has_iv() const;
  private:
  bool _internal_has_iv() const;
  public:
  void clear_iv();
  const std::string& iv() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_iv(ArgT0&& arg0, ArgT... args);
  std::string* mutable_iv();
  PROTOBUF_NODISCARD std::string* release_iv();
  void set_allocated_iv(std::string* iv);
  private:
  const std::string& _internal_iv() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_iv(const std::string& value);
  std::string* _internal_mutable_iv();
  public:

  // optional bytes public_metadata = 6;
  bool has_public_metadata() const;
  private:
  bool _internal_has_public_metadata() const;
  public:
  void clear_public_metadata();
  const std::string& public_metadata() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_public_metadata(ArgT0&& arg0, ArgT... args);
  std::string* mutable_public_metadata();
  PROTOBUF_NODISCARD std::string* release_public_metadata();
  void set_allocated_public_metadata(std::string* public_metadata);
  private:
  const std::string& _internal_public_metadata() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_public_metadata(const std::string& value);
  std::string* _internal_mutable_public_metadata();
  public:

  // optional uint32 associated_data_length = 7 [default = 0];
  bool has_associated_data_length() const;
  private:
  bool _internal_has_associated_data_length() const;
  public:
  void clear_associated_data_length();
  uint32_t associated_data_length() const;
  void set_associated_data_length(uint32_t value);
  private:
  uint32_t _internal_associated_data_length() const;
  void _internal_set_associated_data_length(uint32_t value);
  public:

  // required .securemessage.SigScheme signature_scheme = 1;
  bool has_signature_scheme() const;
  private:
  bool _internal_has_signature_scheme() const;
  public:
  void clear_signature_scheme();
  ::securemessage::SigScheme signature_scheme() const;
  void set_signature_scheme(::securemessage::SigScheme value);
  private:
  ::securemessage::SigScheme _internal_signature_scheme() const;
  void _internal_set_signature_scheme(::securemessage::SigScheme value);
  public:

  // required .securemessage.EncScheme encryption_scheme = 2;
  bool has_encryption_scheme() const;
  private:
  bool _internal_has_encryption_scheme() const;
  public:
  void clear_encryption_scheme();
  ::securemessage::EncScheme encryption_scheme() const;
  void set_encryption_scheme(::securemessage::EncScheme value);
  private:
  ::securemessage::EncScheme _internal_encryption_scheme() const;
  void _internal_set_encryption_scheme(::securemessage::EncScheme value);
  public:

  // @@protoc_insertion_point(class_scope:securemessage.Header)
 private:
  class _Internal;

  // helper for ByteSizeLong()
  size_t RequiredFieldsByteSizeFallback() const;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr verification_key_id_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr decryption_key_id_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr iv_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr public_metadata_;
  uint32_t associated_data_length_;
  int signature_scheme_;
  int encryption_scheme_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// -------------------------------------------------------------------

class HeaderAndBody final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.HeaderAndBody) */ {
 public:
  inline HeaderAndBody() : HeaderAndBody(nullptr) {}
  ~HeaderAndBody() override;
  explicit constexpr HeaderAndBody(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  HeaderAndBody(const HeaderAndBody& from);
  HeaderAndBody(HeaderAndBody&& from) noexcept
    : HeaderAndBody() {
    *this = ::std::move(from);
  }

  inline HeaderAndBody& operator=(const HeaderAndBody& from) {
    CopyFrom(from);
    return *this;
  }
  inline HeaderAndBody& operator=(HeaderAndBody&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const HeaderAndBody& default_instance() {
    return *internal_default_instance();
  }
  static inline const HeaderAndBody* internal_default_instance() {
    return reinterpret_cast<const HeaderAndBody*>(
               &_HeaderAndBody_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    2;

  friend void swap(HeaderAndBody& a, HeaderAndBody& b) {
    a.Swap(&b);
  }
  inline void Swap(HeaderAndBody* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(HeaderAndBody* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  HeaderAndBody* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<HeaderAndBody>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const HeaderAndBody& from);
  void MergeFrom(const HeaderAndBody& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(HeaderAndBody* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.HeaderAndBody";
  }
  protected:
  explicit HeaderAndBody(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kBodyFieldNumber = 2,
    kHeaderFieldNumber = 1,
  };
  // required bytes body = 2;
  bool has_body() const;
  private:
  bool _internal_has_body() const;
  public:
  void clear_body();
  const std::string& body() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_body(ArgT0&& arg0, ArgT... args);
  std::string* mutable_body();
  PROTOBUF_NODISCARD std::string* release_body();
  void set_allocated_body(std::string* body);
  private:
  const std::string& _internal_body() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_body(const std::string& value);
  std::string* _internal_mutable_body();
  public:

  // required .securemessage.Header header = 1;
  bool has_header() const;
  private:
  bool _internal_has_header() const;
  public:
  void clear_header();
  const ::securemessage::Header& header() const;
  PROTOBUF_NODISCARD ::securemessage::Header* release_header();
  ::securemessage::Header* mutable_header();
  void set_allocated_header(::securemessage::Header* header);
  private:
  const ::securemessage::Header& _internal_header() const;
  ::securemessage::Header* _internal_mutable_header();
  public:
  void unsafe_arena_set_allocated_header(
      ::securemessage::Header* header);
  ::securemessage::Header* unsafe_arena_release_header();

  // @@protoc_insertion_point(class_scope:securemessage.HeaderAndBody)
 private:
  class _Internal;

  // helper for ByteSizeLong()
  size_t RequiredFieldsByteSizeFallback() const;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr body_;
  ::securemessage::Header* header_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// -------------------------------------------------------------------

class HeaderAndBodyInternal final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.HeaderAndBodyInternal) */ {
 public:
  inline HeaderAndBodyInternal() : HeaderAndBodyInternal(nullptr) {}
  ~HeaderAndBodyInternal() override;
  explicit constexpr HeaderAndBodyInternal(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  HeaderAndBodyInternal(const HeaderAndBodyInternal& from);
  HeaderAndBodyInternal(HeaderAndBodyInternal&& from) noexcept
    : HeaderAndBodyInternal() {
    *this = ::std::move(from);
  }

  inline HeaderAndBodyInternal& operator=(const HeaderAndBodyInternal& from) {
    CopyFrom(from);
    return *this;
  }
  inline HeaderAndBodyInternal& operator=(HeaderAndBodyInternal&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const HeaderAndBodyInternal& default_instance() {
    return *internal_default_instance();
  }
  static inline const HeaderAndBodyInternal* internal_default_instance() {
    return reinterpret_cast<const HeaderAndBodyInternal*>(
               &_HeaderAndBodyInternal_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    3;

  friend void swap(HeaderAndBodyInternal& a, HeaderAndBodyInternal& b) {
    a.Swap(&b);
  }
  inline void Swap(HeaderAndBodyInternal* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(HeaderAndBodyInternal* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  HeaderAndBodyInternal* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<HeaderAndBodyInternal>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const HeaderAndBodyInternal& from);
  void MergeFrom(const HeaderAndBodyInternal& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(HeaderAndBodyInternal* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.HeaderAndBodyInternal";
  }
  protected:
  explicit HeaderAndBodyInternal(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kHeaderFieldNumber = 1,
    kBodyFieldNumber = 2,
  };
  // required bytes header = 1;
  bool has_header() const;
  private:
  bool _internal_has_header() const;
  public:
  void clear_header();
  const std::string& header() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_header(ArgT0&& arg0, ArgT... args);
  std::string* mutable_header();
  PROTOBUF_NODISCARD std::string* release_header();
  void set_allocated_header(std::string* header);
  private:
  const std::string& _internal_header() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_header(const std::string& value);
  std::string* _internal_mutable_header();
  public:

  // required bytes body = 2;
  bool has_body() const;
  private:
  bool _internal_has_body() const;
  public:
  void clear_body();
  const std::string& body() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_body(ArgT0&& arg0, ArgT... args);
  std::string* mutable_body();
  PROTOBUF_NODISCARD std::string* release_body();
  void set_allocated_body(std::string* body);
  private:
  const std::string& _internal_body() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_body(const std::string& value);
  std::string* _internal_mutable_body();
  public:

  // @@protoc_insertion_point(class_scope:securemessage.HeaderAndBodyInternal)
 private:
  class _Internal;

  // helper for ByteSizeLong()
  size_t RequiredFieldsByteSizeFallback() const;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr header_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr body_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// -------------------------------------------------------------------

class EcP256PublicKey final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.EcP256PublicKey) */ {
 public:
  inline EcP256PublicKey() : EcP256PublicKey(nullptr) {}
  ~EcP256PublicKey() override;
  explicit constexpr EcP256PublicKey(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  EcP256PublicKey(const EcP256PublicKey& from);
  EcP256PublicKey(EcP256PublicKey&& from) noexcept
    : EcP256PublicKey() {
    *this = ::std::move(from);
  }

  inline EcP256PublicKey& operator=(const EcP256PublicKey& from) {
    CopyFrom(from);
    return *this;
  }
  inline EcP256PublicKey& operator=(EcP256PublicKey&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const EcP256PublicKey& default_instance() {
    return *internal_default_instance();
  }
  static inline const EcP256PublicKey* internal_default_instance() {
    return reinterpret_cast<const EcP256PublicKey*>(
               &_EcP256PublicKey_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    4;

  friend void swap(EcP256PublicKey& a, EcP256PublicKey& b) {
    a.Swap(&b);
  }
  inline void Swap(EcP256PublicKey* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(EcP256PublicKey* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  EcP256PublicKey* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<EcP256PublicKey>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const EcP256PublicKey& from);
  void MergeFrom(const EcP256PublicKey& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(EcP256PublicKey* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.EcP256PublicKey";
  }
  protected:
  explicit EcP256PublicKey(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kXFieldNumber = 1,
    kYFieldNumber = 2,
  };
  // required bytes x = 1;
  bool has_x() const;
  private:
  bool _internal_has_x() const;
  public:
  void clear_x();
  const std::string& x() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_x(ArgT0&& arg0, ArgT... args);
  std::string* mutable_x();
  PROTOBUF_NODISCARD std::string* release_x();
  void set_allocated_x(std::string* x);
  private:
  const std::string& _internal_x() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_x(const std::string& value);
  std::string* _internal_mutable_x();
  public:

  // required bytes y = 2;
  bool has_y() const;
  private:
  bool _internal_has_y() const;
  public:
  void clear_y();
  const std::string& y() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_y(ArgT0&& arg0, ArgT... args);
  std::string* mutable_y();
  PROTOBUF_NODISCARD std::string* release_y();
  void set_allocated_y(std::string* y);
  private:
  const std::string& _internal_y() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_y(const std::string& value);
  std::string* _internal_mutable_y();
  public:

  // @@protoc_insertion_point(class_scope:securemessage.EcP256PublicKey)
 private:
  class _Internal;

  // helper for ByteSizeLong()
  size_t RequiredFieldsByteSizeFallback() const;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr x_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr y_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// -------------------------------------------------------------------

class SimpleRsaPublicKey final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.SimpleRsaPublicKey) */ {
 public:
  inline SimpleRsaPublicKey() : SimpleRsaPublicKey(nullptr) {}
  ~SimpleRsaPublicKey() override;
  explicit constexpr SimpleRsaPublicKey(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  SimpleRsaPublicKey(const SimpleRsaPublicKey& from);
  SimpleRsaPublicKey(SimpleRsaPublicKey&& from) noexcept
    : SimpleRsaPublicKey() {
    *this = ::std::move(from);
  }

  inline SimpleRsaPublicKey& operator=(const SimpleRsaPublicKey& from) {
    CopyFrom(from);
    return *this;
  }
  inline SimpleRsaPublicKey& operator=(SimpleRsaPublicKey&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const SimpleRsaPublicKey& default_instance() {
    return *internal_default_instance();
  }
  static inline const SimpleRsaPublicKey* internal_default_instance() {
    return reinterpret_cast<const SimpleRsaPublicKey*>(
               &_SimpleRsaPublicKey_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    5;

  friend void swap(SimpleRsaPublicKey& a, SimpleRsaPublicKey& b) {
    a.Swap(&b);
  }
  inline void Swap(SimpleRsaPublicKey* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(SimpleRsaPublicKey* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  SimpleRsaPublicKey* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<SimpleRsaPublicKey>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const SimpleRsaPublicKey& from);
  void MergeFrom(const SimpleRsaPublicKey& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(SimpleRsaPublicKey* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.SimpleRsaPublicKey";
  }
  protected:
  explicit SimpleRsaPublicKey(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kNFieldNumber = 1,
    kEFieldNumber = 2,
  };
  // required bytes n = 1;
  bool has_n() const;
  private:
  bool _internal_has_n() const;
  public:
  void clear_n();
  const std::string& n() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_n(ArgT0&& arg0, ArgT... args);
  std::string* mutable_n();
  PROTOBUF_NODISCARD std::string* release_n();
  void set_allocated_n(std::string* n);
  private:
  const std::string& _internal_n() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_n(const std::string& value);
  std::string* _internal_mutable_n();
  public:

  // optional int32 e = 2 [default = 65537];
  bool has_e() const;
  private:
  bool _internal_has_e() const;
  public:
  void clear_e();
  int32_t e() const;
  void set_e(int32_t value);
  private:
  int32_t _internal_e() const;
  void _internal_set_e(int32_t value);
  public:

  // @@protoc_insertion_point(class_scope:securemessage.SimpleRsaPublicKey)
 private:
  class _Internal;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr n_;
  int32_t e_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// -------------------------------------------------------------------

class DhPublicKey final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.DhPublicKey) */ {
 public:
  inline DhPublicKey() : DhPublicKey(nullptr) {}
  ~DhPublicKey() override;
  explicit constexpr DhPublicKey(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  DhPublicKey(const DhPublicKey& from);
  DhPublicKey(DhPublicKey&& from) noexcept
    : DhPublicKey() {
    *this = ::std::move(from);
  }

  inline DhPublicKey& operator=(const DhPublicKey& from) {
    CopyFrom(from);
    return *this;
  }
  inline DhPublicKey& operator=(DhPublicKey&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const DhPublicKey& default_instance() {
    return *internal_default_instance();
  }
  static inline const DhPublicKey* internal_default_instance() {
    return reinterpret_cast<const DhPublicKey*>(
               &_DhPublicKey_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    6;

  friend void swap(DhPublicKey& a, DhPublicKey& b) {
    a.Swap(&b);
  }
  inline void Swap(DhPublicKey* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(DhPublicKey* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  DhPublicKey* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<DhPublicKey>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const DhPublicKey& from);
  void MergeFrom(const DhPublicKey& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(DhPublicKey* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.DhPublicKey";
  }
  protected:
  explicit DhPublicKey(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kYFieldNumber = 1,
  };
  // required bytes y = 1;
  bool has_y() const;
  private:
  bool _internal_has_y() const;
  public:
  void clear_y();
  const std::string& y() const;
  template <typename ArgT0 = const std::string&, typename... ArgT>
  void set_y(ArgT0&& arg0, ArgT... args);
  std::string* mutable_y();
  PROTOBUF_NODISCARD std::string* release_y();
  void set_allocated_y(std::string* y);
  private:
  const std::string& _internal_y() const;
  inline PROTOBUF_ALWAYS_INLINE void _internal_set_y(const std::string& value);
  std::string* _internal_mutable_y();
  public:

  // @@protoc_insertion_point(class_scope:securemessage.DhPublicKey)
 private:
  class _Internal;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr y_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// -------------------------------------------------------------------

class GenericPublicKey final :
    public ::PROTOBUF_NAMESPACE_ID::MessageLite /* @@protoc_insertion_point(class_definition:securemessage.GenericPublicKey) */ {
 public:
  inline GenericPublicKey() : GenericPublicKey(nullptr) {}
  ~GenericPublicKey() override;
  explicit constexpr GenericPublicKey(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);

  GenericPublicKey(const GenericPublicKey& from);
  GenericPublicKey(GenericPublicKey&& from) noexcept
    : GenericPublicKey() {
    *this = ::std::move(from);
  }

  inline GenericPublicKey& operator=(const GenericPublicKey& from) {
    CopyFrom(from);
    return *this;
  }
  inline GenericPublicKey& operator=(GenericPublicKey&& from) noexcept {
    if (this == &from) return *this;
    if (GetOwningArena() == from.GetOwningArena()
  #ifdef PROTOBUF_FORCE_COPY_IN_MOVE
        && GetOwningArena() != nullptr
  #endif  // !PROTOBUF_FORCE_COPY_IN_MOVE
    ) {
      InternalSwap(&from);
    } else {
      CopyFrom(from);
    }
    return *this;
  }

  inline const std::string& unknown_fields() const {
    return _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString);
  }
  inline std::string* mutable_unknown_fields() {
    return _internal_metadata_.mutable_unknown_fields<std::string>();
  }

  static const GenericPublicKey& default_instance() {
    return *internal_default_instance();
  }
  static inline const GenericPublicKey* internal_default_instance() {
    return reinterpret_cast<const GenericPublicKey*>(
               &_GenericPublicKey_default_instance_);
  }
  static constexpr int kIndexInFileMessages =
    7;

  friend void swap(GenericPublicKey& a, GenericPublicKey& b) {
    a.Swap(&b);
  }
  inline void Swap(GenericPublicKey* other) {
    if (other == this) return;
  #ifdef PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() != nullptr &&
        GetOwningArena() == other->GetOwningArena()) {
   #else  // PROTOBUF_FORCE_COPY_IN_SWAP
    if (GetOwningArena() == other->GetOwningArena()) {
  #endif  // !PROTOBUF_FORCE_COPY_IN_SWAP
      InternalSwap(other);
    } else {
      ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
    }
  }
  void UnsafeArenaSwap(GenericPublicKey* other) {
    if (other == this) return;
    GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena());
    InternalSwap(other);
  }

  // implements Message ----------------------------------------------

  GenericPublicKey* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final {
    return CreateMaybeMessage<GenericPublicKey>(arena);
  }
  void CheckTypeAndMergeFrom(const ::PROTOBUF_NAMESPACE_ID::MessageLite& from)  final;
  void CopyFrom(const GenericPublicKey& from);
  void MergeFrom(const GenericPublicKey& from);
  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
  bool IsInitialized() const final;

  size_t ByteSizeLong() const final;
  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
  uint8_t* _InternalSerialize(
      uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
  int GetCachedSize() const final { return _cached_size_.Get(); }

  private:
  void SharedCtor();
  void SharedDtor();
  void SetCachedSize(int size) const;
  void InternalSwap(GenericPublicKey* other);

  private:
  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
    return "securemessage.GenericPublicKey";
  }
  protected:
  explicit GenericPublicKey(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                       bool is_message_owned = false);
  private:
  static void ArenaDtor(void* object);
  inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
  public:

  std::string GetTypeName() const final;

  // nested types ----------------------------------------------------

  // accessors -------------------------------------------------------

  enum : int {
    kEcP256PublicKeyFieldNumber = 2,
    kRsa2048PublicKeyFieldNumber = 3,
    kDh2048PublicKeyFieldNumber = 4,
    kTypeFieldNumber = 1,
  };
  // optional .securemessage.EcP256PublicKey ec_p256_public_key = 2;
  bool has_ec_p256_public_key() const;
  private:
  bool _internal_has_ec_p256_public_key() const;
  public:
  void clear_ec_p256_public_key();
  const ::securemessage::EcP256PublicKey& ec_p256_public_key() const;
  PROTOBUF_NODISCARD ::securemessage::EcP256PublicKey* release_ec_p256_public_key();
  ::securemessage::EcP256PublicKey* mutable_ec_p256_public_key();
  void set_allocated_ec_p256_public_key(::securemessage::EcP256PublicKey* ec_p256_public_key);
  private:
  const ::securemessage::EcP256PublicKey& _internal_ec_p256_public_key() const;
  ::securemessage::EcP256PublicKey* _internal_mutable_ec_p256_public_key();
  public:
  void unsafe_arena_set_allocated_ec_p256_public_key(
      ::securemessage::EcP256PublicKey* ec_p256_public_key);
  ::securemessage::EcP256PublicKey* unsafe_arena_release_ec_p256_public_key();

  // optional .securemessage.SimpleRsaPublicKey rsa2048_public_key = 3;
  bool has_rsa2048_public_key() const;
  private:
  bool _internal_has_rsa2048_public_key() const;
  public:
  void clear_rsa2048_public_key();
  const ::securemessage::SimpleRsaPublicKey& rsa2048_public_key() const;
  PROTOBUF_NODISCARD ::securemessage::SimpleRsaPublicKey* release_rsa2048_public_key();
  ::securemessage::SimpleRsaPublicKey* mutable_rsa2048_public_key();
  void set_allocated_rsa2048_public_key(::securemessage::SimpleRsaPublicKey* rsa2048_public_key);
  private:
  const ::securemessage::SimpleRsaPublicKey& _internal_rsa2048_public_key() const;
  ::securemessage::SimpleRsaPublicKey* _internal_mutable_rsa2048_public_key();
  public:
  void unsafe_arena_set_allocated_rsa2048_public_key(
      ::securemessage::SimpleRsaPublicKey* rsa2048_public_key);
  ::securemessage::SimpleRsaPublicKey* unsafe_arena_release_rsa2048_public_key();

  // optional .securemessage.DhPublicKey dh2048_public_key = 4;
  bool has_dh2048_public_key() const;
  private:
  bool _internal_has_dh2048_public_key() const;
  public:
  void clear_dh2048_public_key();
  const ::securemessage::DhPublicKey& dh2048_public_key() const;
  PROTOBUF_NODISCARD ::securemessage::DhPublicKey* release_dh2048_public_key();
  ::securemessage::DhPublicKey* mutable_dh2048_public_key();
  void set_allocated_dh2048_public_key(::securemessage::DhPublicKey* dh2048_public_key);
  private:
  const ::securemessage::DhPublicKey& _internal_dh2048_public_key() const;
  ::securemessage::DhPublicKey* _internal_mutable_dh2048_public_key();
  public:
  void unsafe_arena_set_allocated_dh2048_public_key(
      ::securemessage::DhPublicKey* dh2048_public_key);
  ::securemessage::DhPublicKey* unsafe_arena_release_dh2048_public_key();

  // required .securemessage.PublicKeyType type = 1;
  bool has_type() const;
  private:
  bool _internal_has_type() const;
  public:
  void clear_type();
  ::securemessage::PublicKeyType type() const;
  void set_type(::securemessage::PublicKeyType value);
  private:
  ::securemessage::PublicKeyType _internal_type() const;
  void _internal_set_type(::securemessage::PublicKeyType value);
  public:

  // @@protoc_insertion_point(class_scope:securemessage.GenericPublicKey)
 private:
  class _Internal;

  template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
  typedef void InternalArenaConstructable_;
  typedef void DestructorSkippable_;
  ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
  ::securemessage::EcP256PublicKey* ec_p256_public_key_;
  ::securemessage::SimpleRsaPublicKey* rsa2048_public_key_;
  ::securemessage::DhPublicKey* dh2048_public_key_;
  int type_;
  friend struct ::TableStruct_proto_2fsecuremessage_2eproto;
};
// ===================================================================


// ===================================================================

#ifdef __GNUC__
  #pragma GCC diagnostic push
  #pragma GCC diagnostic ignored "-Wstrict-aliasing"
#endif  // __GNUC__
// SecureMessage

// required bytes header_and_body = 1;
inline bool SecureMessage::_internal_has_header_and_body() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  return value;
}
inline bool SecureMessage::has_header_and_body() const {
  return _internal_has_header_and_body();
}
inline void SecureMessage::clear_header_and_body() {
  header_and_body_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000001u;
}
inline const std::string& SecureMessage::header_and_body() const {
  // @@protoc_insertion_point(field_get:securemessage.SecureMessage.header_and_body)
  return _internal_header_and_body();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void SecureMessage::set_header_and_body(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000001u;
 header_and_body_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.SecureMessage.header_and_body)
}
inline std::string* SecureMessage::mutable_header_and_body() {
  std::string* _s = _internal_mutable_header_and_body();
  // @@protoc_insertion_point(field_mutable:securemessage.SecureMessage.header_and_body)
  return _s;
}
inline const std::string& SecureMessage::_internal_header_and_body() const {
  return header_and_body_.Get();
}
inline void SecureMessage::_internal_set_header_and_body(const std::string& value) {
  _has_bits_[0] |= 0x00000001u;
  header_and_body_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* SecureMessage::_internal_mutable_header_and_body() {
  _has_bits_[0] |= 0x00000001u;
  return header_and_body_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* SecureMessage::release_header_and_body() {
  // @@protoc_insertion_point(field_release:securemessage.SecureMessage.header_and_body)
  if (!_internal_has_header_and_body()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000001u;
  auto* p = header_and_body_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (header_and_body_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    header_and_body_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void SecureMessage::set_allocated_header_and_body(std::string* header_and_body) {
  if (header_and_body != nullptr) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  header_and_body_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), header_and_body,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (header_and_body_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    header_and_body_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.SecureMessage.header_and_body)
}

// required bytes signature = 2;
inline bool SecureMessage::_internal_has_signature() const {
  bool value = (_has_bits_[0] & 0x00000002u) != 0;
  return value;
}
inline bool SecureMessage::has_signature() const {
  return _internal_has_signature();
}
inline void SecureMessage::clear_signature() {
  signature_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000002u;
}
inline const std::string& SecureMessage::signature() const {
  // @@protoc_insertion_point(field_get:securemessage.SecureMessage.signature)
  return _internal_signature();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void SecureMessage::set_signature(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000002u;
 signature_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.SecureMessage.signature)
}
inline std::string* SecureMessage::mutable_signature() {
  std::string* _s = _internal_mutable_signature();
  // @@protoc_insertion_point(field_mutable:securemessage.SecureMessage.signature)
  return _s;
}
inline const std::string& SecureMessage::_internal_signature() const {
  return signature_.Get();
}
inline void SecureMessage::_internal_set_signature(const std::string& value) {
  _has_bits_[0] |= 0x00000002u;
  signature_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* SecureMessage::_internal_mutable_signature() {
  _has_bits_[0] |= 0x00000002u;
  return signature_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* SecureMessage::release_signature() {
  // @@protoc_insertion_point(field_release:securemessage.SecureMessage.signature)
  if (!_internal_has_signature()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000002u;
  auto* p = signature_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (signature_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    signature_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void SecureMessage::set_allocated_signature(std::string* signature) {
  if (signature != nullptr) {
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  signature_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), signature,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (signature_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    signature_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.SecureMessage.signature)
}

// -------------------------------------------------------------------

// Header

// required .securemessage.SigScheme signature_scheme = 1;
inline bool Header::_internal_has_signature_scheme() const {
  bool value = (_has_bits_[0] & 0x00000020u) != 0;
  return value;
}
inline bool Header::has_signature_scheme() const {
  return _internal_has_signature_scheme();
}
inline void Header::clear_signature_scheme() {
  signature_scheme_ = 1;
  _has_bits_[0] &= ~0x00000020u;
}
inline ::securemessage::SigScheme Header::_internal_signature_scheme() const {
  return static_cast< ::securemessage::SigScheme >(signature_scheme_);
}
inline ::securemessage::SigScheme Header::signature_scheme() const {
  // @@protoc_insertion_point(field_get:securemessage.Header.signature_scheme)
  return _internal_signature_scheme();
}
inline void Header::_internal_set_signature_scheme(::securemessage::SigScheme value) {
  assert(::securemessage::SigScheme_IsValid(value));
  _has_bits_[0] |= 0x00000020u;
  signature_scheme_ = value;
}
inline void Header::set_signature_scheme(::securemessage::SigScheme value) {
  _internal_set_signature_scheme(value);
  // @@protoc_insertion_point(field_set:securemessage.Header.signature_scheme)
}

// required .securemessage.EncScheme encryption_scheme = 2;
inline bool Header::_internal_has_encryption_scheme() const {
  bool value = (_has_bits_[0] & 0x00000040u) != 0;
  return value;
}
inline bool Header::has_encryption_scheme() const {
  return _internal_has_encryption_scheme();
}
inline void Header::clear_encryption_scheme() {
  encryption_scheme_ = 1;
  _has_bits_[0] &= ~0x00000040u;
}
inline ::securemessage::EncScheme Header::_internal_encryption_scheme() const {
  return static_cast< ::securemessage::EncScheme >(encryption_scheme_);
}
inline ::securemessage::EncScheme Header::encryption_scheme() const {
  // @@protoc_insertion_point(field_get:securemessage.Header.encryption_scheme)
  return _internal_encryption_scheme();
}
inline void Header::_internal_set_encryption_scheme(::securemessage::EncScheme value) {
  assert(::securemessage::EncScheme_IsValid(value));
  _has_bits_[0] |= 0x00000040u;
  encryption_scheme_ = value;
}
inline void Header::set_encryption_scheme(::securemessage::EncScheme value) {
  _internal_set_encryption_scheme(value);
  // @@protoc_insertion_point(field_set:securemessage.Header.encryption_scheme)
}

// optional bytes verification_key_id = 3;
inline bool Header::_internal_has_verification_key_id() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  return value;
}
inline bool Header::has_verification_key_id() const {
  return _internal_has_verification_key_id();
}
inline void Header::clear_verification_key_id() {
  verification_key_id_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000001u;
}
inline const std::string& Header::verification_key_id() const {
  // @@protoc_insertion_point(field_get:securemessage.Header.verification_key_id)
  return _internal_verification_key_id();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void Header::set_verification_key_id(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000001u;
 verification_key_id_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.Header.verification_key_id)
}
inline std::string* Header::mutable_verification_key_id() {
  std::string* _s = _internal_mutable_verification_key_id();
  // @@protoc_insertion_point(field_mutable:securemessage.Header.verification_key_id)
  return _s;
}
inline const std::string& Header::_internal_verification_key_id() const {
  return verification_key_id_.Get();
}
inline void Header::_internal_set_verification_key_id(const std::string& value) {
  _has_bits_[0] |= 0x00000001u;
  verification_key_id_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* Header::_internal_mutable_verification_key_id() {
  _has_bits_[0] |= 0x00000001u;
  return verification_key_id_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* Header::release_verification_key_id() {
  // @@protoc_insertion_point(field_release:securemessage.Header.verification_key_id)
  if (!_internal_has_verification_key_id()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000001u;
  auto* p = verification_key_id_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (verification_key_id_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    verification_key_id_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void Header::set_allocated_verification_key_id(std::string* verification_key_id) {
  if (verification_key_id != nullptr) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  verification_key_id_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), verification_key_id,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (verification_key_id_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    verification_key_id_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.Header.verification_key_id)
}

// optional bytes decryption_key_id = 4;
inline bool Header::_internal_has_decryption_key_id() const {
  bool value = (_has_bits_[0] & 0x00000002u) != 0;
  return value;
}
inline bool Header::has_decryption_key_id() const {
  return _internal_has_decryption_key_id();
}
inline void Header::clear_decryption_key_id() {
  decryption_key_id_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000002u;
}
inline const std::string& Header::decryption_key_id() const {
  // @@protoc_insertion_point(field_get:securemessage.Header.decryption_key_id)
  return _internal_decryption_key_id();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void Header::set_decryption_key_id(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000002u;
 decryption_key_id_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.Header.decryption_key_id)
}
inline std::string* Header::mutable_decryption_key_id() {
  std::string* _s = _internal_mutable_decryption_key_id();
  // @@protoc_insertion_point(field_mutable:securemessage.Header.decryption_key_id)
  return _s;
}
inline const std::string& Header::_internal_decryption_key_id() const {
  return decryption_key_id_.Get();
}
inline void Header::_internal_set_decryption_key_id(const std::string& value) {
  _has_bits_[0] |= 0x00000002u;
  decryption_key_id_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* Header::_internal_mutable_decryption_key_id() {
  _has_bits_[0] |= 0x00000002u;
  return decryption_key_id_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* Header::release_decryption_key_id() {
  // @@protoc_insertion_point(field_release:securemessage.Header.decryption_key_id)
  if (!_internal_has_decryption_key_id()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000002u;
  auto* p = decryption_key_id_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (decryption_key_id_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    decryption_key_id_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void Header::set_allocated_decryption_key_id(std::string* decryption_key_id) {
  if (decryption_key_id != nullptr) {
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  decryption_key_id_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), decryption_key_id,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (decryption_key_id_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    decryption_key_id_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.Header.decryption_key_id)
}

// optional bytes iv = 5;
inline bool Header::_internal_has_iv() const {
  bool value = (_has_bits_[0] & 0x00000004u) != 0;
  return value;
}
inline bool Header::has_iv() const {
  return _internal_has_iv();
}
inline void Header::clear_iv() {
  iv_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000004u;
}
inline const std::string& Header::iv() const {
  // @@protoc_insertion_point(field_get:securemessage.Header.iv)
  return _internal_iv();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void Header::set_iv(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000004u;
 iv_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.Header.iv)
}
inline std::string* Header::mutable_iv() {
  std::string* _s = _internal_mutable_iv();
  // @@protoc_insertion_point(field_mutable:securemessage.Header.iv)
  return _s;
}
inline const std::string& Header::_internal_iv() const {
  return iv_.Get();
}
inline void Header::_internal_set_iv(const std::string& value) {
  _has_bits_[0] |= 0x00000004u;
  iv_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* Header::_internal_mutable_iv() {
  _has_bits_[0] |= 0x00000004u;
  return iv_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* Header::release_iv() {
  // @@protoc_insertion_point(field_release:securemessage.Header.iv)
  if (!_internal_has_iv()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000004u;
  auto* p = iv_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (iv_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    iv_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void Header::set_allocated_iv(std::string* iv) {
  if (iv != nullptr) {
    _has_bits_[0] |= 0x00000004u;
  } else {
    _has_bits_[0] &= ~0x00000004u;
  }
  iv_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), iv,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (iv_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    iv_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.Header.iv)
}

// optional bytes public_metadata = 6;
inline bool Header::_internal_has_public_metadata() const {
  bool value = (_has_bits_[0] & 0x00000008u) != 0;
  return value;
}
inline bool Header::has_public_metadata() const {
  return _internal_has_public_metadata();
}
inline void Header::clear_public_metadata() {
  public_metadata_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000008u;
}
inline const std::string& Header::public_metadata() const {
  // @@protoc_insertion_point(field_get:securemessage.Header.public_metadata)
  return _internal_public_metadata();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void Header::set_public_metadata(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000008u;
 public_metadata_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.Header.public_metadata)
}
inline std::string* Header::mutable_public_metadata() {
  std::string* _s = _internal_mutable_public_metadata();
  // @@protoc_insertion_point(field_mutable:securemessage.Header.public_metadata)
  return _s;
}
inline const std::string& Header::_internal_public_metadata() const {
  return public_metadata_.Get();
}
inline void Header::_internal_set_public_metadata(const std::string& value) {
  _has_bits_[0] |= 0x00000008u;
  public_metadata_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* Header::_internal_mutable_public_metadata() {
  _has_bits_[0] |= 0x00000008u;
  return public_metadata_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* Header::release_public_metadata() {
  // @@protoc_insertion_point(field_release:securemessage.Header.public_metadata)
  if (!_internal_has_public_metadata()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000008u;
  auto* p = public_metadata_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (public_metadata_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    public_metadata_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void Header::set_allocated_public_metadata(std::string* public_metadata) {
  if (public_metadata != nullptr) {
    _has_bits_[0] |= 0x00000008u;
  } else {
    _has_bits_[0] &= ~0x00000008u;
  }
  public_metadata_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), public_metadata,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (public_metadata_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    public_metadata_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.Header.public_metadata)
}

// optional uint32 associated_data_length = 7 [default = 0];
inline bool Header::_internal_has_associated_data_length() const {
  bool value = (_has_bits_[0] & 0x00000010u) != 0;
  return value;
}
inline bool Header::has_associated_data_length() const {
  return _internal_has_associated_data_length();
}
inline void Header::clear_associated_data_length() {
  associated_data_length_ = 0u;
  _has_bits_[0] &= ~0x00000010u;
}
inline uint32_t Header::_internal_associated_data_length() const {
  return associated_data_length_;
}
inline uint32_t Header::associated_data_length() const {
  // @@protoc_insertion_point(field_get:securemessage.Header.associated_data_length)
  return _internal_associated_data_length();
}
inline void Header::_internal_set_associated_data_length(uint32_t value) {
  _has_bits_[0] |= 0x00000010u;
  associated_data_length_ = value;
}
inline void Header::set_associated_data_length(uint32_t value) {
  _internal_set_associated_data_length(value);
  // @@protoc_insertion_point(field_set:securemessage.Header.associated_data_length)
}

// -------------------------------------------------------------------

// HeaderAndBody

// required .securemessage.Header header = 1;
inline bool HeaderAndBody::_internal_has_header() const {
  bool value = (_has_bits_[0] & 0x00000002u) != 0;
  PROTOBUF_ASSUME(!value || header_ != nullptr);
  return value;
}
inline bool HeaderAndBody::has_header() const {
  return _internal_has_header();
}
inline void HeaderAndBody::clear_header() {
  if (header_ != nullptr) header_->Clear();
  _has_bits_[0] &= ~0x00000002u;
}
inline const ::securemessage::Header& HeaderAndBody::_internal_header() const {
  const ::securemessage::Header* p = header_;
  return p != nullptr ? *p : reinterpret_cast<const ::securemessage::Header&>(
      ::securemessage::_Header_default_instance_);
}
inline const ::securemessage::Header& HeaderAndBody::header() const {
  // @@protoc_insertion_point(field_get:securemessage.HeaderAndBody.header)
  return _internal_header();
}
inline void HeaderAndBody::unsafe_arena_set_allocated_header(
    ::securemessage::Header* header) {
  if (GetArenaForAllocation() == nullptr) {
    delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(header_);
  }
  header_ = header;
  if (header) {
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  // @@protoc_insertion_point(field_unsafe_arena_set_allocated:securemessage.HeaderAndBody.header)
}
inline ::securemessage::Header* HeaderAndBody::release_header() {
  _has_bits_[0] &= ~0x00000002u;
  ::securemessage::Header* temp = header_;
  header_ = nullptr;
#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE
  auto* old =  reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp);
  temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  if (GetArenaForAllocation() == nullptr) { delete old; }
#else  // PROTOBUF_FORCE_COPY_IN_RELEASE
  if (GetArenaForAllocation() != nullptr) {
    temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  }
#endif  // !PROTOBUF_FORCE_COPY_IN_RELEASE
  return temp;
}
inline ::securemessage::Header* HeaderAndBody::unsafe_arena_release_header() {
  // @@protoc_insertion_point(field_release:securemessage.HeaderAndBody.header)
  _has_bits_[0] &= ~0x00000002u;
  ::securemessage::Header* temp = header_;
  header_ = nullptr;
  return temp;
}
inline ::securemessage::Header* HeaderAndBody::_internal_mutable_header() {
  _has_bits_[0] |= 0x00000002u;
  if (header_ == nullptr) {
    auto* p = CreateMaybeMessage<::securemessage::Header>(GetArenaForAllocation());
    header_ = p;
  }
  return header_;
}
inline ::securemessage::Header* HeaderAndBody::mutable_header() {
  ::securemessage::Header* _msg = _internal_mutable_header();
  // @@protoc_insertion_point(field_mutable:securemessage.HeaderAndBody.header)
  return _msg;
}
inline void HeaderAndBody::set_allocated_header(::securemessage::Header* header) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  if (message_arena == nullptr) {
    delete header_;
  }
  if (header) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
        ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper<::securemessage::Header>::GetOwningArena(header);
    if (message_arena != submessage_arena) {
      header = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, header, submessage_arena);
    }
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  header_ = header;
  // @@protoc_insertion_point(field_set_allocated:securemessage.HeaderAndBody.header)
}

// required bytes body = 2;
inline bool HeaderAndBody::_internal_has_body() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  return value;
}
inline bool HeaderAndBody::has_body() const {
  return _internal_has_body();
}
inline void HeaderAndBody::clear_body() {
  body_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000001u;
}
inline const std::string& HeaderAndBody::body() const {
  // @@protoc_insertion_point(field_get:securemessage.HeaderAndBody.body)
  return _internal_body();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void HeaderAndBody::set_body(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000001u;
 body_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.HeaderAndBody.body)
}
inline std::string* HeaderAndBody::mutable_body() {
  std::string* _s = _internal_mutable_body();
  // @@protoc_insertion_point(field_mutable:securemessage.HeaderAndBody.body)
  return _s;
}
inline const std::string& HeaderAndBody::_internal_body() const {
  return body_.Get();
}
inline void HeaderAndBody::_internal_set_body(const std::string& value) {
  _has_bits_[0] |= 0x00000001u;
  body_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* HeaderAndBody::_internal_mutable_body() {
  _has_bits_[0] |= 0x00000001u;
  return body_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* HeaderAndBody::release_body() {
  // @@protoc_insertion_point(field_release:securemessage.HeaderAndBody.body)
  if (!_internal_has_body()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000001u;
  auto* p = body_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (body_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    body_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void HeaderAndBody::set_allocated_body(std::string* body) {
  if (body != nullptr) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  body_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), body,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (body_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    body_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.HeaderAndBody.body)
}

// -------------------------------------------------------------------

// HeaderAndBodyInternal

// required bytes header = 1;
inline bool HeaderAndBodyInternal::_internal_has_header() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  return value;
}
inline bool HeaderAndBodyInternal::has_header() const {
  return _internal_has_header();
}
inline void HeaderAndBodyInternal::clear_header() {
  header_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000001u;
}
inline const std::string& HeaderAndBodyInternal::header() const {
  // @@protoc_insertion_point(field_get:securemessage.HeaderAndBodyInternal.header)
  return _internal_header();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void HeaderAndBodyInternal::set_header(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000001u;
 header_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.HeaderAndBodyInternal.header)
}
inline std::string* HeaderAndBodyInternal::mutable_header() {
  std::string* _s = _internal_mutable_header();
  // @@protoc_insertion_point(field_mutable:securemessage.HeaderAndBodyInternal.header)
  return _s;
}
inline const std::string& HeaderAndBodyInternal::_internal_header() const {
  return header_.Get();
}
inline void HeaderAndBodyInternal::_internal_set_header(const std::string& value) {
  _has_bits_[0] |= 0x00000001u;
  header_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* HeaderAndBodyInternal::_internal_mutable_header() {
  _has_bits_[0] |= 0x00000001u;
  return header_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* HeaderAndBodyInternal::release_header() {
  // @@protoc_insertion_point(field_release:securemessage.HeaderAndBodyInternal.header)
  if (!_internal_has_header()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000001u;
  auto* p = header_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (header_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    header_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void HeaderAndBodyInternal::set_allocated_header(std::string* header) {
  if (header != nullptr) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  header_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), header,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (header_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    header_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.HeaderAndBodyInternal.header)
}

// required bytes body = 2;
inline bool HeaderAndBodyInternal::_internal_has_body() const {
  bool value = (_has_bits_[0] & 0x00000002u) != 0;
  return value;
}
inline bool HeaderAndBodyInternal::has_body() const {
  return _internal_has_body();
}
inline void HeaderAndBodyInternal::clear_body() {
  body_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000002u;
}
inline const std::string& HeaderAndBodyInternal::body() const {
  // @@protoc_insertion_point(field_get:securemessage.HeaderAndBodyInternal.body)
  return _internal_body();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void HeaderAndBodyInternal::set_body(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000002u;
 body_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.HeaderAndBodyInternal.body)
}
inline std::string* HeaderAndBodyInternal::mutable_body() {
  std::string* _s = _internal_mutable_body();
  // @@protoc_insertion_point(field_mutable:securemessage.HeaderAndBodyInternal.body)
  return _s;
}
inline const std::string& HeaderAndBodyInternal::_internal_body() const {
  return body_.Get();
}
inline void HeaderAndBodyInternal::_internal_set_body(const std::string& value) {
  _has_bits_[0] |= 0x00000002u;
  body_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* HeaderAndBodyInternal::_internal_mutable_body() {
  _has_bits_[0] |= 0x00000002u;
  return body_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* HeaderAndBodyInternal::release_body() {
  // @@protoc_insertion_point(field_release:securemessage.HeaderAndBodyInternal.body)
  if (!_internal_has_body()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000002u;
  auto* p = body_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (body_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    body_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void HeaderAndBodyInternal::set_allocated_body(std::string* body) {
  if (body != nullptr) {
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  body_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), body,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (body_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    body_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.HeaderAndBodyInternal.body)
}

// -------------------------------------------------------------------

// EcP256PublicKey

// required bytes x = 1;
inline bool EcP256PublicKey::_internal_has_x() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  return value;
}
inline bool EcP256PublicKey::has_x() const {
  return _internal_has_x();
}
inline void EcP256PublicKey::clear_x() {
  x_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000001u;
}
inline const std::string& EcP256PublicKey::x() const {
  // @@protoc_insertion_point(field_get:securemessage.EcP256PublicKey.x)
  return _internal_x();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void EcP256PublicKey::set_x(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000001u;
 x_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.EcP256PublicKey.x)
}
inline std::string* EcP256PublicKey::mutable_x() {
  std::string* _s = _internal_mutable_x();
  // @@protoc_insertion_point(field_mutable:securemessage.EcP256PublicKey.x)
  return _s;
}
inline const std::string& EcP256PublicKey::_internal_x() const {
  return x_.Get();
}
inline void EcP256PublicKey::_internal_set_x(const std::string& value) {
  _has_bits_[0] |= 0x00000001u;
  x_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* EcP256PublicKey::_internal_mutable_x() {
  _has_bits_[0] |= 0x00000001u;
  return x_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* EcP256PublicKey::release_x() {
  // @@protoc_insertion_point(field_release:securemessage.EcP256PublicKey.x)
  if (!_internal_has_x()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000001u;
  auto* p = x_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (x_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    x_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void EcP256PublicKey::set_allocated_x(std::string* x) {
  if (x != nullptr) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  x_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), x,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (x_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    x_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.EcP256PublicKey.x)
}

// required bytes y = 2;
inline bool EcP256PublicKey::_internal_has_y() const {
  bool value = (_has_bits_[0] & 0x00000002u) != 0;
  return value;
}
inline bool EcP256PublicKey::has_y() const {
  return _internal_has_y();
}
inline void EcP256PublicKey::clear_y() {
  y_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000002u;
}
inline const std::string& EcP256PublicKey::y() const {
  // @@protoc_insertion_point(field_get:securemessage.EcP256PublicKey.y)
  return _internal_y();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void EcP256PublicKey::set_y(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000002u;
 y_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.EcP256PublicKey.y)
}
inline std::string* EcP256PublicKey::mutable_y() {
  std::string* _s = _internal_mutable_y();
  // @@protoc_insertion_point(field_mutable:securemessage.EcP256PublicKey.y)
  return _s;
}
inline const std::string& EcP256PublicKey::_internal_y() const {
  return y_.Get();
}
inline void EcP256PublicKey::_internal_set_y(const std::string& value) {
  _has_bits_[0] |= 0x00000002u;
  y_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* EcP256PublicKey::_internal_mutable_y() {
  _has_bits_[0] |= 0x00000002u;
  return y_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* EcP256PublicKey::release_y() {
  // @@protoc_insertion_point(field_release:securemessage.EcP256PublicKey.y)
  if (!_internal_has_y()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000002u;
  auto* p = y_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (y_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    y_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void EcP256PublicKey::set_allocated_y(std::string* y) {
  if (y != nullptr) {
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  y_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), y,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (y_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    y_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.EcP256PublicKey.y)
}

// -------------------------------------------------------------------

// SimpleRsaPublicKey

// required bytes n = 1;
inline bool SimpleRsaPublicKey::_internal_has_n() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  return value;
}
inline bool SimpleRsaPublicKey::has_n() const {
  return _internal_has_n();
}
inline void SimpleRsaPublicKey::clear_n() {
  n_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000001u;
}
inline const std::string& SimpleRsaPublicKey::n() const {
  // @@protoc_insertion_point(field_get:securemessage.SimpleRsaPublicKey.n)
  return _internal_n();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void SimpleRsaPublicKey::set_n(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000001u;
 n_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.SimpleRsaPublicKey.n)
}
inline std::string* SimpleRsaPublicKey::mutable_n() {
  std::string* _s = _internal_mutable_n();
  // @@protoc_insertion_point(field_mutable:securemessage.SimpleRsaPublicKey.n)
  return _s;
}
inline const std::string& SimpleRsaPublicKey::_internal_n() const {
  return n_.Get();
}
inline void SimpleRsaPublicKey::_internal_set_n(const std::string& value) {
  _has_bits_[0] |= 0x00000001u;
  n_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* SimpleRsaPublicKey::_internal_mutable_n() {
  _has_bits_[0] |= 0x00000001u;
  return n_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* SimpleRsaPublicKey::release_n() {
  // @@protoc_insertion_point(field_release:securemessage.SimpleRsaPublicKey.n)
  if (!_internal_has_n()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000001u;
  auto* p = n_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (n_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    n_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void SimpleRsaPublicKey::set_allocated_n(std::string* n) {
  if (n != nullptr) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  n_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), n,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (n_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    n_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.SimpleRsaPublicKey.n)
}

// optional int32 e = 2 [default = 65537];
inline bool SimpleRsaPublicKey::_internal_has_e() const {
  bool value = (_has_bits_[0] & 0x00000002u) != 0;
  return value;
}
inline bool SimpleRsaPublicKey::has_e() const {
  return _internal_has_e();
}
inline void SimpleRsaPublicKey::clear_e() {
  e_ = 65537;
  _has_bits_[0] &= ~0x00000002u;
}
inline int32_t SimpleRsaPublicKey::_internal_e() const {
  return e_;
}
inline int32_t SimpleRsaPublicKey::e() const {
  // @@protoc_insertion_point(field_get:securemessage.SimpleRsaPublicKey.e)
  return _internal_e();
}
inline void SimpleRsaPublicKey::_internal_set_e(int32_t value) {
  _has_bits_[0] |= 0x00000002u;
  e_ = value;
}
inline void SimpleRsaPublicKey::set_e(int32_t value) {
  _internal_set_e(value);
  // @@protoc_insertion_point(field_set:securemessage.SimpleRsaPublicKey.e)
}

// -------------------------------------------------------------------

// DhPublicKey

// required bytes y = 1;
inline bool DhPublicKey::_internal_has_y() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  return value;
}
inline bool DhPublicKey::has_y() const {
  return _internal_has_y();
}
inline void DhPublicKey::clear_y() {
  y_.ClearToEmpty();
  _has_bits_[0] &= ~0x00000001u;
}
inline const std::string& DhPublicKey::y() const {
  // @@protoc_insertion_point(field_get:securemessage.DhPublicKey.y)
  return _internal_y();
}
template <typename ArgT0, typename... ArgT>
inline PROTOBUF_ALWAYS_INLINE
void DhPublicKey::set_y(ArgT0&& arg0, ArgT... args) {
 _has_bits_[0] |= 0x00000001u;
 y_.SetBytes(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, static_cast<ArgT0 &&>(arg0), args..., GetArenaForAllocation());
  // @@protoc_insertion_point(field_set:securemessage.DhPublicKey.y)
}
inline std::string* DhPublicKey::mutable_y() {
  std::string* _s = _internal_mutable_y();
  // @@protoc_insertion_point(field_mutable:securemessage.DhPublicKey.y)
  return _s;
}
inline const std::string& DhPublicKey::_internal_y() const {
  return y_.Get();
}
inline void DhPublicKey::_internal_set_y(const std::string& value) {
  _has_bits_[0] |= 0x00000001u;
  y_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArenaForAllocation());
}
inline std::string* DhPublicKey::_internal_mutable_y() {
  _has_bits_[0] |= 0x00000001u;
  return y_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArenaForAllocation());
}
inline std::string* DhPublicKey::release_y() {
  // @@protoc_insertion_point(field_release:securemessage.DhPublicKey.y)
  if (!_internal_has_y()) {
    return nullptr;
  }
  _has_bits_[0] &= ~0x00000001u;
  auto* p = y_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (y_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    y_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  return p;
}
inline void DhPublicKey::set_allocated_y(std::string* y) {
  if (y != nullptr) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  y_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), y,
      GetArenaForAllocation());
#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (y_.IsDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited())) {
    y_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), "", GetArenaForAllocation());
  }
#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  // @@protoc_insertion_point(field_set_allocated:securemessage.DhPublicKey.y)
}

// -------------------------------------------------------------------

// GenericPublicKey

// required .securemessage.PublicKeyType type = 1;
inline bool GenericPublicKey::_internal_has_type() const {
  bool value = (_has_bits_[0] & 0x00000008u) != 0;
  return value;
}
inline bool GenericPublicKey::has_type() const {
  return _internal_has_type();
}
inline void GenericPublicKey::clear_type() {
  type_ = 1;
  _has_bits_[0] &= ~0x00000008u;
}
inline ::securemessage::PublicKeyType GenericPublicKey::_internal_type() const {
  return static_cast< ::securemessage::PublicKeyType >(type_);
}
inline ::securemessage::PublicKeyType GenericPublicKey::type() const {
  // @@protoc_insertion_point(field_get:securemessage.GenericPublicKey.type)
  return _internal_type();
}
inline void GenericPublicKey::_internal_set_type(::securemessage::PublicKeyType value) {
  assert(::securemessage::PublicKeyType_IsValid(value));
  _has_bits_[0] |= 0x00000008u;
  type_ = value;
}
inline void GenericPublicKey::set_type(::securemessage::PublicKeyType value) {
  _internal_set_type(value);
  // @@protoc_insertion_point(field_set:securemessage.GenericPublicKey.type)
}

// optional .securemessage.EcP256PublicKey ec_p256_public_key = 2;
inline bool GenericPublicKey::_internal_has_ec_p256_public_key() const {
  bool value = (_has_bits_[0] & 0x00000001u) != 0;
  PROTOBUF_ASSUME(!value || ec_p256_public_key_ != nullptr);
  return value;
}
inline bool GenericPublicKey::has_ec_p256_public_key() const {
  return _internal_has_ec_p256_public_key();
}
inline void GenericPublicKey::clear_ec_p256_public_key() {
  if (ec_p256_public_key_ != nullptr) ec_p256_public_key_->Clear();
  _has_bits_[0] &= ~0x00000001u;
}
inline const ::securemessage::EcP256PublicKey& GenericPublicKey::_internal_ec_p256_public_key() const {
  const ::securemessage::EcP256PublicKey* p = ec_p256_public_key_;
  return p != nullptr ? *p : reinterpret_cast<const ::securemessage::EcP256PublicKey&>(
      ::securemessage::_EcP256PublicKey_default_instance_);
}
inline const ::securemessage::EcP256PublicKey& GenericPublicKey::ec_p256_public_key() const {
  // @@protoc_insertion_point(field_get:securemessage.GenericPublicKey.ec_p256_public_key)
  return _internal_ec_p256_public_key();
}
inline void GenericPublicKey::unsafe_arena_set_allocated_ec_p256_public_key(
    ::securemessage::EcP256PublicKey* ec_p256_public_key) {
  if (GetArenaForAllocation() == nullptr) {
    delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(ec_p256_public_key_);
  }
  ec_p256_public_key_ = ec_p256_public_key;
  if (ec_p256_public_key) {
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  // @@protoc_insertion_point(field_unsafe_arena_set_allocated:securemessage.GenericPublicKey.ec_p256_public_key)
}
inline ::securemessage::EcP256PublicKey* GenericPublicKey::release_ec_p256_public_key() {
  _has_bits_[0] &= ~0x00000001u;
  ::securemessage::EcP256PublicKey* temp = ec_p256_public_key_;
  ec_p256_public_key_ = nullptr;
#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE
  auto* old =  reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp);
  temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  if (GetArenaForAllocation() == nullptr) { delete old; }
#else  // PROTOBUF_FORCE_COPY_IN_RELEASE
  if (GetArenaForAllocation() != nullptr) {
    temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  }
#endif  // !PROTOBUF_FORCE_COPY_IN_RELEASE
  return temp;
}
inline ::securemessage::EcP256PublicKey* GenericPublicKey::unsafe_arena_release_ec_p256_public_key() {
  // @@protoc_insertion_point(field_release:securemessage.GenericPublicKey.ec_p256_public_key)
  _has_bits_[0] &= ~0x00000001u;
  ::securemessage::EcP256PublicKey* temp = ec_p256_public_key_;
  ec_p256_public_key_ = nullptr;
  return temp;
}
inline ::securemessage::EcP256PublicKey* GenericPublicKey::_internal_mutable_ec_p256_public_key() {
  _has_bits_[0] |= 0x00000001u;
  if (ec_p256_public_key_ == nullptr) {
    auto* p = CreateMaybeMessage<::securemessage::EcP256PublicKey>(GetArenaForAllocation());
    ec_p256_public_key_ = p;
  }
  return ec_p256_public_key_;
}
inline ::securemessage::EcP256PublicKey* GenericPublicKey::mutable_ec_p256_public_key() {
  ::securemessage::EcP256PublicKey* _msg = _internal_mutable_ec_p256_public_key();
  // @@protoc_insertion_point(field_mutable:securemessage.GenericPublicKey.ec_p256_public_key)
  return _msg;
}
inline void GenericPublicKey::set_allocated_ec_p256_public_key(::securemessage::EcP256PublicKey* ec_p256_public_key) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  if (message_arena == nullptr) {
    delete ec_p256_public_key_;
  }
  if (ec_p256_public_key) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
        ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper<::securemessage::EcP256PublicKey>::GetOwningArena(ec_p256_public_key);
    if (message_arena != submessage_arena) {
      ec_p256_public_key = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, ec_p256_public_key, submessage_arena);
    }
    _has_bits_[0] |= 0x00000001u;
  } else {
    _has_bits_[0] &= ~0x00000001u;
  }
  ec_p256_public_key_ = ec_p256_public_key;
  // @@protoc_insertion_point(field_set_allocated:securemessage.GenericPublicKey.ec_p256_public_key)
}

// optional .securemessage.SimpleRsaPublicKey rsa2048_public_key = 3;
inline bool GenericPublicKey::_internal_has_rsa2048_public_key() const {
  bool value = (_has_bits_[0] & 0x00000002u) != 0;
  PROTOBUF_ASSUME(!value || rsa2048_public_key_ != nullptr);
  return value;
}
inline bool GenericPublicKey::has_rsa2048_public_key() const {
  return _internal_has_rsa2048_public_key();
}
inline void GenericPublicKey::clear_rsa2048_public_key() {
  if (rsa2048_public_key_ != nullptr) rsa2048_public_key_->Clear();
  _has_bits_[0] &= ~0x00000002u;
}
inline const ::securemessage::SimpleRsaPublicKey& GenericPublicKey::_internal_rsa2048_public_key() const {
  const ::securemessage::SimpleRsaPublicKey* p = rsa2048_public_key_;
  return p != nullptr ? *p : reinterpret_cast<const ::securemessage::SimpleRsaPublicKey&>(
      ::securemessage::_SimpleRsaPublicKey_default_instance_);
}
inline const ::securemessage::SimpleRsaPublicKey& GenericPublicKey::rsa2048_public_key() const {
  // @@protoc_insertion_point(field_get:securemessage.GenericPublicKey.rsa2048_public_key)
  return _internal_rsa2048_public_key();
}
inline void GenericPublicKey::unsafe_arena_set_allocated_rsa2048_public_key(
    ::securemessage::SimpleRsaPublicKey* rsa2048_public_key) {
  if (GetArenaForAllocation() == nullptr) {
    delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(rsa2048_public_key_);
  }
  rsa2048_public_key_ = rsa2048_public_key;
  if (rsa2048_public_key) {
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  // @@protoc_insertion_point(field_unsafe_arena_set_allocated:securemessage.GenericPublicKey.rsa2048_public_key)
}
inline ::securemessage::SimpleRsaPublicKey* GenericPublicKey::release_rsa2048_public_key() {
  _has_bits_[0] &= ~0x00000002u;
  ::securemessage::SimpleRsaPublicKey* temp = rsa2048_public_key_;
  rsa2048_public_key_ = nullptr;
#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE
  auto* old =  reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp);
  temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  if (GetArenaForAllocation() == nullptr) { delete old; }
#else  // PROTOBUF_FORCE_COPY_IN_RELEASE
  if (GetArenaForAllocation() != nullptr) {
    temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  }
#endif  // !PROTOBUF_FORCE_COPY_IN_RELEASE
  return temp;
}
inline ::securemessage::SimpleRsaPublicKey* GenericPublicKey::unsafe_arena_release_rsa2048_public_key() {
  // @@protoc_insertion_point(field_release:securemessage.GenericPublicKey.rsa2048_public_key)
  _has_bits_[0] &= ~0x00000002u;
  ::securemessage::SimpleRsaPublicKey* temp = rsa2048_public_key_;
  rsa2048_public_key_ = nullptr;
  return temp;
}
inline ::securemessage::SimpleRsaPublicKey* GenericPublicKey::_internal_mutable_rsa2048_public_key() {
  _has_bits_[0] |= 0x00000002u;
  if (rsa2048_public_key_ == nullptr) {
    auto* p = CreateMaybeMessage<::securemessage::SimpleRsaPublicKey>(GetArenaForAllocation());
    rsa2048_public_key_ = p;
  }
  return rsa2048_public_key_;
}
inline ::securemessage::SimpleRsaPublicKey* GenericPublicKey::mutable_rsa2048_public_key() {
  ::securemessage::SimpleRsaPublicKey* _msg = _internal_mutable_rsa2048_public_key();
  // @@protoc_insertion_point(field_mutable:securemessage.GenericPublicKey.rsa2048_public_key)
  return _msg;
}
inline void GenericPublicKey::set_allocated_rsa2048_public_key(::securemessage::SimpleRsaPublicKey* rsa2048_public_key) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  if (message_arena == nullptr) {
    delete rsa2048_public_key_;
  }
  if (rsa2048_public_key) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
        ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper<::securemessage::SimpleRsaPublicKey>::GetOwningArena(rsa2048_public_key);
    if (message_arena != submessage_arena) {
      rsa2048_public_key = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, rsa2048_public_key, submessage_arena);
    }
    _has_bits_[0] |= 0x00000002u;
  } else {
    _has_bits_[0] &= ~0x00000002u;
  }
  rsa2048_public_key_ = rsa2048_public_key;
  // @@protoc_insertion_point(field_set_allocated:securemessage.GenericPublicKey.rsa2048_public_key)
}

// optional .securemessage.DhPublicKey dh2048_public_key = 4;
inline bool GenericPublicKey::_internal_has_dh2048_public_key() const {
  bool value = (_has_bits_[0] & 0x00000004u) != 0;
  PROTOBUF_ASSUME(!value || dh2048_public_key_ != nullptr);
  return value;
}
inline bool GenericPublicKey::has_dh2048_public_key() const {
  return _internal_has_dh2048_public_key();
}
inline void GenericPublicKey::clear_dh2048_public_key() {
  if (dh2048_public_key_ != nullptr) dh2048_public_key_->Clear();
  _has_bits_[0] &= ~0x00000004u;
}
inline const ::securemessage::DhPublicKey& GenericPublicKey::_internal_dh2048_public_key() const {
  const ::securemessage::DhPublicKey* p = dh2048_public_key_;
  return p != nullptr ? *p : reinterpret_cast<const ::securemessage::DhPublicKey&>(
      ::securemessage::_DhPublicKey_default_instance_);
}
inline const ::securemessage::DhPublicKey& GenericPublicKey::dh2048_public_key() const {
  // @@protoc_insertion_point(field_get:securemessage.GenericPublicKey.dh2048_public_key)
  return _internal_dh2048_public_key();
}
inline void GenericPublicKey::unsafe_arena_set_allocated_dh2048_public_key(
    ::securemessage::DhPublicKey* dh2048_public_key) {
  if (GetArenaForAllocation() == nullptr) {
    delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(dh2048_public_key_);
  }
  dh2048_public_key_ = dh2048_public_key;
  if (dh2048_public_key) {
    _has_bits_[0] |= 0x00000004u;
  } else {
    _has_bits_[0] &= ~0x00000004u;
  }
  // @@protoc_insertion_point(field_unsafe_arena_set_allocated:securemessage.GenericPublicKey.dh2048_public_key)
}
inline ::securemessage::DhPublicKey* GenericPublicKey::release_dh2048_public_key() {
  _has_bits_[0] &= ~0x00000004u;
  ::securemessage::DhPublicKey* temp = dh2048_public_key_;
  dh2048_public_key_ = nullptr;
#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE
  auto* old =  reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp);
  temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  if (GetArenaForAllocation() == nullptr) { delete old; }
#else  // PROTOBUF_FORCE_COPY_IN_RELEASE
  if (GetArenaForAllocation() != nullptr) {
    temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
  }
#endif  // !PROTOBUF_FORCE_COPY_IN_RELEASE
  return temp;
}
inline ::securemessage::DhPublicKey* GenericPublicKey::unsafe_arena_release_dh2048_public_key() {
  // @@protoc_insertion_point(field_release:securemessage.GenericPublicKey.dh2048_public_key)
  _has_bits_[0] &= ~0x00000004u;
  ::securemessage::DhPublicKey* temp = dh2048_public_key_;
  dh2048_public_key_ = nullptr;
  return temp;
}
inline ::securemessage::DhPublicKey* GenericPublicKey::_internal_mutable_dh2048_public_key() {
  _has_bits_[0] |= 0x00000004u;
  if (dh2048_public_key_ == nullptr) {
    auto* p = CreateMaybeMessage<::securemessage::DhPublicKey>(GetArenaForAllocation());
    dh2048_public_key_ = p;
  }
  return dh2048_public_key_;
}
inline ::securemessage::DhPublicKey* GenericPublicKey::mutable_dh2048_public_key() {
  ::securemessage::DhPublicKey* _msg = _internal_mutable_dh2048_public_key();
  // @@protoc_insertion_point(field_mutable:securemessage.GenericPublicKey.dh2048_public_key)
  return _msg;
}
inline void GenericPublicKey::set_allocated_dh2048_public_key(::securemessage::DhPublicKey* dh2048_public_key) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  if (message_arena == nullptr) {
    delete dh2048_public_key_;
  }
  if (dh2048_public_key) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
        ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper<::securemessage::DhPublicKey>::GetOwningArena(dh2048_public_key);
    if (message_arena != submessage_arena) {
      dh2048_public_key = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, dh2048_public_key, submessage_arena);
    }
    _has_bits_[0] |= 0x00000004u;
  } else {
    _has_bits_[0] &= ~0x00000004u;
  }
  dh2048_public_key_ = dh2048_public_key;
  // @@protoc_insertion_point(field_set_allocated:securemessage.GenericPublicKey.dh2048_public_key)
}

#ifdef __GNUC__
  #pragma GCC diagnostic pop
#endif  // __GNUC__
// -------------------------------------------------------------------

// -------------------------------------------------------------------

// -------------------------------------------------------------------

// -------------------------------------------------------------------

// -------------------------------------------------------------------

// -------------------------------------------------------------------

// -------------------------------------------------------------------


// @@protoc_insertion_point(namespace_scope)

}  // namespace securemessage

PROTOBUF_NAMESPACE_OPEN

template <> struct is_proto_enum< ::securemessage::SigScheme> : ::std::true_type {};
template <> struct is_proto_enum< ::securemessage::EncScheme> : ::std::true_type {};
template <> struct is_proto_enum< ::securemessage::PublicKeyType> : ::std::true_type {};

PROTOBUF_NAMESPACE_CLOSE

// @@protoc_insertion_point(global_scope)

#include <google/protobuf/port_undef.inc>
#endif  // GOOGLE_PROTOBUF_INCLUDED_GOOGLE_PROTOBUF_INCLUDED_proto_2fsecuremessage_2eproto
