/* Generated by the protocol buffer compiler.  DO NOT EDIT! */
/* Generated from: device_mode.proto */

#ifndef PROTOBUF_C_device_5fmode_2eproto__INCLUDED
#define PROTOBUF_C_device_5fmode_2eproto__INCLUDED

#include <protobuf-c/protobuf-c.h>

PROTOBUF_C__BEGIN_DECLS

#if PROTOBUF_C_VERSION_NUMBER < 1003000
# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
#elif 1005000 < PROTOBUF_C_MIN_COMPILER_VERSION
# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
#endif


typedef struct Logi__Device__Proto__TransitionToDeviceModeRequest Logi__Device__Proto__TransitionToDeviceModeRequest;
typedef struct Logi__Device__Proto__TransitionToDeviceModeResponse Logi__Device__Proto__TransitionToDeviceModeResponse;
typedef struct Logi__Device__Proto__SetDeprovisionRequest Logi__Device__Proto__SetDeprovisionRequest;
typedef struct Logi__Device__Proto__SetDeprovisionResponse Logi__Device__Proto__SetDeprovisionResponse;
typedef struct Logi__Device__Proto__SendCertificateDataRequest Logi__Device__Proto__SendCertificateDataRequest;
typedef struct Logi__Device__Proto__SendCertificateDataResponse Logi__Device__Proto__SendCertificateDataResponse;


/* --- enums --- */

/*
 **
 * The certificate type
 */
typedef enum _Logi__Device__Proto__SendCertificateDataRequest__CertType {
  /*
   **
   * Reserved. Do not use.
   */
  LOGI__DEVICE__PROTO__SEND_CERTIFICATE_DATA_REQUEST__CERT_TYPE__RESERVED = 0,
  /*
   **
   * Root CA
   */
  LOGI__DEVICE__PROTO__SEND_CERTIFICATE_DATA_REQUEST__CERT_TYPE__ROOT_CA = 1,
  /*
   **
   * 802.1x cert
   */
  LOGI__DEVICE__PROTO__SEND_CERTIFICATE_DATA_REQUEST__CERT_TYPE__NET_CONFIG = 2
    PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(LOGI__DEVICE__PROTO__SEND_CERTIFICATE_DATA_REQUEST__CERT_TYPE)
} Logi__Device__Proto__SendCertificateDataRequest__CertType;

/* --- messages --- */

/*
 **
 * Behavior change as of 1/28/2021 EE
 *   Kong sync-agent should not deprovision when this message is
 *   received.  If would just start forwarding events to PC when message is
 *   received.
 * (Legacy)
 * Request to transition to device mode
 * Kong could be provisioned in Host mode.  This message
 * will ask Kong to deprovisioned/remove host mode provisioning
 * data.
 * This is to be included in UsbMsg
 * EXPECTED RESPONSE
 * TransitionToDeviceModeResponse
 */
struct  Logi__Device__Proto__TransitionToDeviceModeRequest
{
  ProtobufCMessage base;
  /*
   **
   * Unused. Reserved for future use.
   */
  protobuf_c_boolean reserved;
  /*
   **
   * The sender of request =>
   * Possible values:
   *  0 - PC (default)
   *  1 - COS device
   */
  int32_t sender;
};
#define LOGI__DEVICE__PROTO__TRANSITION_TO_DEVICE_MODE_REQUEST__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&logi__device__proto__transition_to_device_mode_request__descriptor) \
, 0, 0 }


/*
 **
 * Request to transition to device mode response
 */
struct  Logi__Device__Proto__TransitionToDeviceModeResponse
{
  ProtobufCMessage base;
  /*
   **
   * boolean value to indicate Kong was able to transition to
   * device mode.  If Kong is not provisioned, should just respond
   * with true value.
   * set to false if error was encountered during transition, and Kong
   * wasn't able to transition (is this possible?)
   */
  protobuf_c_boolean success;
  /*
   **
   * the error in integer if success was false
   */
  int32_t error;
  /*
   **
   * the error description
   */
  char *error_description;
};
#define LOGI__DEVICE__PROTO__TRANSITION_TO_DEVICE_MODE_RESPONSE__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&logi__device__proto__transition_to_device_mode_response__descriptor) \
, 0, 0, (char *)protobuf_c_empty_string }


/*
 **
 *  Added 1/28/2021 EE
 *  Request to deprovision Kong
 *  This request is sent by PC sync-agent when PC
 *   is provisioned.
 *  Kong sync-agent should deprovision (if provisioned)
 * EXPECTED RESPONSE
 * SetDeprovisionResponse
 */
struct  Logi__Device__Proto__SetDeprovisionRequest
{
  ProtobufCMessage base;
  /*
   **
   * Unused. Reserved for future use.
   */
  protobuf_c_boolean reserved;
};
#define LOGI__DEVICE__PROTO__SET_DEPROVISION_REQUEST__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&logi__device__proto__set_deprovision_request__descriptor) \
, 0 }


/*
 **
 * Response to deprovision request
 */
struct  Logi__Device__Proto__SetDeprovisionResponse
{
  ProtobufCMessage base;
  /*
   **
   * boolean value to indicate Kong was able to deprovision Kong.
   * If Kong is not provisioned, should just respond
   * with true value.
   * set to false if error was encountered during deprovisioning.
   */
  protobuf_c_boolean success;
  /*
   **
   * the error in integer if success was false
   */
  int32_t error;
  /*
   **
   * the error description
   */
  char *error_description;
};
#define LOGI__DEVICE__PROTO__SET_DEPROVISION_RESPONSE__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&logi__device__proto__set_deprovision_response__descriptor) \
, 0, 0, (char *)protobuf_c_empty_string }


/*
 **
 *  Added 3/22/2021 EE
 *  For sending a certificate as data.  There are currently
 *   2 known certificate that will be transferred - Root CA, and 802.1x cert.
 *  Upon receipt, sync-agent should  verify using the supplied hash
 *   and write the data to the file system.
 * EXPECTED RESPONSE
 * SendCertificateDataResponse
 */
struct  Logi__Device__Proto__SendCertificateDataRequest
{
  ProtobufCMessage base;
  /*
   **
   * (REQUIRED)
   * The certificate type
   */
  Logi__Device__Proto__SendCertificateDataRequest__CertType cert_type;
  /*
   **
   * (REQUIRED)
   * the certificate file name
   */
  char *file_name;
  /*
   **
   * (REQUIRED)
   * the certificate data
   */
  ProtobufCBinaryData cert_data;
  /*
   **
   * (REQUIRED)
   * the certificate md5 hash
   */
  char *md5;
};
#define LOGI__DEVICE__PROTO__SEND_CERTIFICATE_DATA_REQUEST__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&logi__device__proto__send_certificate_data_request__descriptor) \
, LOGI__DEVICE__PROTO__SEND_CERTIFICATE_DATA_REQUEST__CERT_TYPE__RESERVED, (char *)protobuf_c_empty_string, {0,NULL}, (char *)protobuf_c_empty_string }


/*
 **
 * Response to SendCertificateData Request
 */
struct  Logi__Device__Proto__SendCertificateDataResponse
{
  ProtobufCMessage base;
  /*
   **
   * (REQUIRED)
   * boolean value to indicate data was received, hash verified .
   * set to false if error was encountered during transfer and verification.
   */
  protobuf_c_boolean success;
  /*
   **
   * (OPTIONAL)
   * the error in integer if success was false
   */
  int32_t error;
  /*
   **
   * (OPTIONAL)
   * the error description if there are errors
   */
  char *error_description;
};
#define LOGI__DEVICE__PROTO__SEND_CERTIFICATE_DATA_RESPONSE__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&logi__device__proto__send_certificate_data_response__descriptor) \
, 0, 0, (char *)protobuf_c_empty_string }


/* Logi__Device__Proto__TransitionToDeviceModeRequest methods */
void   logi__device__proto__transition_to_device_mode_request__init
                     (Logi__Device__Proto__TransitionToDeviceModeRequest         *message);
size_t logi__device__proto__transition_to_device_mode_request__get_packed_size
                     (const Logi__Device__Proto__TransitionToDeviceModeRequest   *message);
size_t logi__device__proto__transition_to_device_mode_request__pack
                     (const Logi__Device__Proto__TransitionToDeviceModeRequest   *message,
                      uint8_t             *out);
size_t logi__device__proto__transition_to_device_mode_request__pack_to_buffer
                     (const Logi__Device__Proto__TransitionToDeviceModeRequest   *message,
                      ProtobufCBuffer     *buffer);
Logi__Device__Proto__TransitionToDeviceModeRequest *
       logi__device__proto__transition_to_device_mode_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   logi__device__proto__transition_to_device_mode_request__free_unpacked
                     (Logi__Device__Proto__TransitionToDeviceModeRequest *message,
                      ProtobufCAllocator *allocator);
/* Logi__Device__Proto__TransitionToDeviceModeResponse methods */
void   logi__device__proto__transition_to_device_mode_response__init
                     (Logi__Device__Proto__TransitionToDeviceModeResponse         *message);
size_t logi__device__proto__transition_to_device_mode_response__get_packed_size
                     (const Logi__Device__Proto__TransitionToDeviceModeResponse   *message);
size_t logi__device__proto__transition_to_device_mode_response__pack
                     (const Logi__Device__Proto__TransitionToDeviceModeResponse   *message,
                      uint8_t             *out);
size_t logi__device__proto__transition_to_device_mode_response__pack_to_buffer
                     (const Logi__Device__Proto__TransitionToDeviceModeResponse   *message,
                      ProtobufCBuffer     *buffer);
Logi__Device__Proto__TransitionToDeviceModeResponse *
       logi__device__proto__transition_to_device_mode_response__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   logi__device__proto__transition_to_device_mode_response__free_unpacked
                     (Logi__Device__Proto__TransitionToDeviceModeResponse *message,
                      ProtobufCAllocator *allocator);
/* Logi__Device__Proto__SetDeprovisionRequest methods */
void   logi__device__proto__set_deprovision_request__init
                     (Logi__Device__Proto__SetDeprovisionRequest         *message);
size_t logi__device__proto__set_deprovision_request__get_packed_size
                     (const Logi__Device__Proto__SetDeprovisionRequest   *message);
size_t logi__device__proto__set_deprovision_request__pack
                     (const Logi__Device__Proto__SetDeprovisionRequest   *message,
                      uint8_t             *out);
size_t logi__device__proto__set_deprovision_request__pack_to_buffer
                     (const Logi__Device__Proto__SetDeprovisionRequest   *message,
                      ProtobufCBuffer     *buffer);
Logi__Device__Proto__SetDeprovisionRequest *
       logi__device__proto__set_deprovision_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   logi__device__proto__set_deprovision_request__free_unpacked
                     (Logi__Device__Proto__SetDeprovisionRequest *message,
                      ProtobufCAllocator *allocator);
/* Logi__Device__Proto__SetDeprovisionResponse methods */
void   logi__device__proto__set_deprovision_response__init
                     (Logi__Device__Proto__SetDeprovisionResponse         *message);
size_t logi__device__proto__set_deprovision_response__get_packed_size
                     (const Logi__Device__Proto__SetDeprovisionResponse   *message);
size_t logi__device__proto__set_deprovision_response__pack
                     (const Logi__Device__Proto__SetDeprovisionResponse   *message,
                      uint8_t             *out);
size_t logi__device__proto__set_deprovision_response__pack_to_buffer
                     (const Logi__Device__Proto__SetDeprovisionResponse   *message,
                      ProtobufCBuffer     *buffer);
Logi__Device__Proto__SetDeprovisionResponse *
       logi__device__proto__set_deprovision_response__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   logi__device__proto__set_deprovision_response__free_unpacked
                     (Logi__Device__Proto__SetDeprovisionResponse *message,
                      ProtobufCAllocator *allocator);
/* Logi__Device__Proto__SendCertificateDataRequest methods */
void   logi__device__proto__send_certificate_data_request__init
                     (Logi__Device__Proto__SendCertificateDataRequest         *message);
size_t logi__device__proto__send_certificate_data_request__get_packed_size
                     (const Logi__Device__Proto__SendCertificateDataRequest   *message);
size_t logi__device__proto__send_certificate_data_request__pack
                     (const Logi__Device__Proto__SendCertificateDataRequest   *message,
                      uint8_t             *out);
size_t logi__device__proto__send_certificate_data_request__pack_to_buffer
                     (const Logi__Device__Proto__SendCertificateDataRequest   *message,
                      ProtobufCBuffer     *buffer);
Logi__Device__Proto__SendCertificateDataRequest *
       logi__device__proto__send_certificate_data_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   logi__device__proto__send_certificate_data_request__free_unpacked
                     (Logi__Device__Proto__SendCertificateDataRequest *message,
                      ProtobufCAllocator *allocator);
/* Logi__Device__Proto__SendCertificateDataResponse methods */
void   logi__device__proto__send_certificate_data_response__init
                     (Logi__Device__Proto__SendCertificateDataResponse         *message);
size_t logi__device__proto__send_certificate_data_response__get_packed_size
                     (const Logi__Device__Proto__SendCertificateDataResponse   *message);
size_t logi__device__proto__send_certificate_data_response__pack
                     (const Logi__Device__Proto__SendCertificateDataResponse   *message,
                      uint8_t             *out);
size_t logi__device__proto__send_certificate_data_response__pack_to_buffer
                     (const Logi__Device__Proto__SendCertificateDataResponse   *message,
                      ProtobufCBuffer     *buffer);
Logi__Device__Proto__SendCertificateDataResponse *
       logi__device__proto__send_certificate_data_response__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   logi__device__proto__send_certificate_data_response__free_unpacked
                     (Logi__Device__Proto__SendCertificateDataResponse *message,
                      ProtobufCAllocator *allocator);
/* --- per-message closures --- */

typedef void (*Logi__Device__Proto__TransitionToDeviceModeRequest_Closure)
                 (const Logi__Device__Proto__TransitionToDeviceModeRequest *message,
                  void *closure_data);
typedef void (*Logi__Device__Proto__TransitionToDeviceModeResponse_Closure)
                 (const Logi__Device__Proto__TransitionToDeviceModeResponse *message,
                  void *closure_data);
typedef void (*Logi__Device__Proto__SetDeprovisionRequest_Closure)
                 (const Logi__Device__Proto__SetDeprovisionRequest *message,
                  void *closure_data);
typedef void (*Logi__Device__Proto__SetDeprovisionResponse_Closure)
                 (const Logi__Device__Proto__SetDeprovisionResponse *message,
                  void *closure_data);
typedef void (*Logi__Device__Proto__SendCertificateDataRequest_Closure)
                 (const Logi__Device__Proto__SendCertificateDataRequest *message,
                  void *closure_data);
typedef void (*Logi__Device__Proto__SendCertificateDataResponse_Closure)
                 (const Logi__Device__Proto__SendCertificateDataResponse *message,
                  void *closure_data);

/* --- services --- */


/* --- descriptors --- */

extern const ProtobufCMessageDescriptor logi__device__proto__transition_to_device_mode_request__descriptor;
extern const ProtobufCMessageDescriptor logi__device__proto__transition_to_device_mode_response__descriptor;
extern const ProtobufCMessageDescriptor logi__device__proto__set_deprovision_request__descriptor;
extern const ProtobufCMessageDescriptor logi__device__proto__set_deprovision_response__descriptor;
extern const ProtobufCMessageDescriptor logi__device__proto__send_certificate_data_request__descriptor;
extern const ProtobufCEnumDescriptor    logi__device__proto__send_certificate_data_request__cert_type__descriptor;
extern const ProtobufCMessageDescriptor logi__device__proto__send_certificate_data_response__descriptor;

PROTOBUF_C__END_DECLS


#endif  /* PROTOBUF_C_device_5fmode_2eproto__INCLUDED */
