linux/net/sunrpc/auth_gss/gss_rpc_xdr.h

/* SPDX-License-Identifier: GPL-2.0+ */
/*
 * GSS Proxy upcall module
 *
 *  Copyright (C) 2012 Simo Sorce <[email protected]>
 */

#ifndef _LINUX_GSS_RPC_XDR_H
#define _LINUX_GSS_RPC_XDR_H

#include <linux/sunrpc/xdr.h>
#include <linux/sunrpc/clnt.h>
#include <linux/sunrpc/xprtsock.h>

#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
#define RPCDBG_FACILITY
#endif

#define LUCID_OPTION
#define LUCID_VALUE
#define CREDS_OPTION
#define CREDS_VALUE

gssx_buffer;
utf8string;
gssx_OID;

enum gssx_cred_usage {};

struct gssx_option {};

struct gssx_option_array {};

struct gssx_status {};

struct gssx_call_ctx {};

struct gssx_name_attr {};

struct gssx_name_attr_array {};

struct gssx_name {};
gssx_name;

struct gssx_cred_element {};

struct gssx_cred_element_array {};

struct gssx_cred {};

struct gssx_ctx {};

struct gssx_cb {};


/* This structure is not defined in the protocol.
 * It is used in the kernel to carry around a big buffer
 * as a set of pages */
struct gssp_in_token {};

struct gssx_arg_accept_sec_context {};

struct gssx_res_accept_sec_context {};



#define gssx_enc_indicate_mechs
#define gssx_dec_indicate_mechs
#define gssx_enc_get_call_context
#define gssx_dec_get_call_context
#define gssx_enc_import_and_canon_name
#define gssx_dec_import_and_canon_name
#define gssx_enc_export_cred
#define gssx_dec_export_cred
#define gssx_enc_import_cred
#define gssx_dec_import_cred
#define gssx_enc_acquire_cred
#define gssx_dec_acquire_cred
#define gssx_enc_store_cred
#define gssx_dec_store_cred
#define gssx_enc_init_sec_context
#define gssx_dec_init_sec_context
void gssx_enc_accept_sec_context(struct rpc_rqst *req,
				 struct xdr_stream *xdr,
				 const void *data);
int gssx_dec_accept_sec_context(struct rpc_rqst *rqstp,
				struct xdr_stream *xdr,
				void *data);
#define gssx_enc_release_handle
#define gssx_dec_release_handle
#define gssx_enc_get_mic
#define gssx_dec_get_mic
#define gssx_enc_verify
#define gssx_dec_verify
#define gssx_enc_wrap
#define gssx_dec_wrap
#define gssx_enc_unwrap
#define gssx_dec_unwrap
#define gssx_enc_wrap_size_limit
#define gssx_dec_wrap_size_limit

/* non implemented calls are set to 0 size */
#define GSSX_ARG_indicate_mechs_sz
#define GSSX_RES_indicate_mechs_sz
#define GSSX_ARG_get_call_context_sz
#define GSSX_RES_get_call_context_sz
#define GSSX_ARG_import_and_canon_name_sz
#define GSSX_RES_import_and_canon_name_sz
#define GSSX_ARG_export_cred_sz
#define GSSX_RES_export_cred_sz
#define GSSX_ARG_import_cred_sz
#define GSSX_RES_import_cred_sz
#define GSSX_ARG_acquire_cred_sz
#define GSSX_RES_acquire_cred_sz
#define GSSX_ARG_store_cred_sz
#define GSSX_RES_store_cred_sz
#define GSSX_ARG_init_sec_context_sz
#define GSSX_RES_init_sec_context_sz

#define GSSX_default_in_call_ctx_sz
#define GSSX_default_in_ctx_hndl_sz
#define GSSX_default_in_cred_sz
#define GSSX_default_in_token_sz
#define GSSX_default_in_cb_sz
#define GSSX_ARG_accept_sec_context_sz

/* somewhat arbitrary numbers but large enough (we ignore some of the data
 * sent down, but it is part of the protocol so we need enough space to take
 * it in) */
#define GSSX_default_status_sz
#define GSSX_max_output_handle_sz
#define GSSX_max_oid_sz
#define GSSX_max_princ_sz
#define GSSX_default_ctx_sz
#define GSSX_max_output_token_sz
/* grouplist not included; we allocate separate pages for that: */
#define GSSX_max_creds_sz
#define GSSX_RES_accept_sec_context_sz

#define GSSX_ARG_release_handle_sz
#define GSSX_RES_release_handle_sz
#define GSSX_ARG_get_mic_sz
#define GSSX_RES_get_mic_sz
#define GSSX_ARG_verify_sz
#define GSSX_RES_verify_sz
#define GSSX_ARG_wrap_sz
#define GSSX_RES_wrap_sz
#define GSSX_ARG_unwrap_sz
#define GSSX_RES_unwrap_sz
#define GSSX_ARG_wrap_size_limit_sz
#define GSSX_RES_wrap_size_limit_sz

#endif /* _LINUX_GSS_RPC_XDR_H */