GRPC Core  4.0.0
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Fields
grpc_metadata_credentials_plugin Struct Reference

grpc_metadata_credentials plugin is an API user provided structure used to create grpc_credentials objects that can be set on a channel (composed) or a call. More...

#include <grpc_security.h>

Data Fields

void(* get_metadata )(void *state, grpc_auth_metadata_context context, grpc_credentials_plugin_metadata_cb cb, void *user_data)
 The implementation of this method has to be non-blocking. More...
 
void(* destroy )(void *state)
 Destroys the plugin state. More...
 
void * state
 State that will be set as the first parameter of the methods above. More...
 
const char * type
 Type of credentials that this plugin is implementing. More...
 

Detailed Description

grpc_metadata_credentials plugin is an API user provided structure used to create grpc_credentials objects that can be set on a channel (composed) or a call.

See grpc_credentials_metadata_create_from_plugin below. The grpc client stack will call the get_metadata method of the plugin for every call in scope for the credentials created from it.

Field Documentation

void(* grpc_metadata_credentials_plugin::destroy)(void *state)

Destroys the plugin state.

void(* grpc_metadata_credentials_plugin::get_metadata)(void *state, grpc_auth_metadata_context context, grpc_credentials_plugin_metadata_cb cb, void *user_data)

The implementation of this method has to be non-blocking.

  • context is the information that can be used by the plugin to create auth metadata.
  • cb is the callback that needs to be called when the metadata is ready.
  • user_data needs to be passed as the first parameter of the callback.
void* grpc_metadata_credentials_plugin::state

State that will be set as the first parameter of the methods above.

const char* grpc_metadata_credentials_plugin::type

Type of credentials that this plugin is implementing.


The documentation for this struct was generated from the following file: