dispatch.h

来自「基于TDI驱动编写的个人防火墙程序。包括驱动模块、应用层规则配置及加载模块。」· C头文件 代码 · 共 46 行

H
46
字号
// -*- mode: C++; tab-width: 4; indent-tabs-mode: nil -*- (for GNU Emacs)
//
// $Id: dispatch.h,v 1.1.1.1 2002/09/24 11:12:16 dev Exp $

#ifndef _dispatch_h_
#define _dispatch_h_

// information about completion routine
struct completion {
	PIO_COMPLETION_ROUTINE	routine;
	PVOID					context;
};

/* 
 * TDI ioctl dispatcher function
 * returns FILTER_xxx
 */
typedef int tdi_ioctl_fn_t(PIRP irp, PIO_STACK_LOCATION irps, struct completion *completion);

// IRP_MJ_CREATE, IRP_MJ_CLEANUP dispatch routines
extern tdi_ioctl_fn_t tdi_create, tdi_cleanup;

// IRP_MJ_INTERNAL_DEVICE_CONTROL ioctl dispatch routines
extern tdi_ioctl_fn_t
	tdi_associate_address,
	tdi_connect,
	tdi_disassociate_address,
	tdi_set_event_handler,
	tdi_send_datagram,
	tdi_receive_datagram;

// helper struct for calling of TDI ioctls
struct tdi_ioctl {
	UCHAR			MinorFunction;
	tdi_ioctl_fn_t	*fn;

#if DBG
	// for debugging
	const char		*desc;
#endif
};

extern struct tdi_ioctl g_tdi_ioctls[];

#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?