X-Git-Url: https://git.distorted.org.uk/~mdw/become/blobdiff_plain/30868bd5a9b2ac3527ac92e63a7fff7c2914339a..b40be44ec9ffc760989b302d85a96f13cb95c1f2:/src/rule.h diff --git a/src/rule.h b/src/rule.h index 59fe406..0594d87 100644 --- a/src/rule.h +++ b/src/rule.h @@ -1,10 +1,10 @@ /* -*-c-*- * - * $Id: rule.h,v 1.4 1997/09/17 10:27:17 mdw Exp $ + * $Id: rule.h,v 1.6 1998/04/23 13:27:31 mdw Exp $ * * Managing rule sets * - * (c) 1997 EBI + * (c) 1998 EBI */ /*----- Licensing notice --------------------------------------------------* @@ -29,7 +29,13 @@ /*----- Revision history --------------------------------------------------* * * $Log: rule.h,v $ - * Revision 1.4 1997/09/17 10:27:17 mdw + * Revision 1.6 1998/04/23 13:27:31 mdw + * Export structure of the rule list, for `bcquery's benefit. + * + * Revision 1.5 1998/01/12 16:46:26 mdw + * Fix copyright date. + * + * Revision 1.4 1997/09/17 10:27:17 mdw * Use rewritten class handler. * * Revision 1.3 1997/08/20 16:22:49 mdw @@ -65,6 +71,18 @@ # include "class.h" #endif +/*----- Type definitions --------------------------------------------------*/ + +/* --- Rule block --- */ + +typedef struct rule { + struct rule *next; /* Next rule in the list */ + class_node *host; /* Hosts this rule applies to */ + class_node *from; /* From users in this class */ + class_node *to; /* To users in this class */ + class_node *cmd; /* To run commands in this class */ +} rule; + /*----- Functions provided ------------------------------------------------*/ /* --- @rule_init@ --- * @@ -89,6 +107,17 @@ extern void rule_init(void); extern void rule_end(void); +/* --- @rule_list@ --- * + * + * Arguments: --- + * + * Returns: The list of rules. + * + * Use: Returns the address of the first node in the rule list. + */ + +extern rule *rule_list(void); + /* --- @rule_add@ --- * * * Arguments: @class_node *host@ = class of hosts this rule applies to