Annotation of 43BSDReno/contrib/isode-beta/h/quipu/attrvalue.h, revision 1.1.1.1

1.1       root        1: /* attrvalue.h - */
                      2: 
                      3: /*
                      4:  * $Header: /f/osi/h/quipu/RCS/attrvalue.h,v 7.0 89/11/23 21:56:22 mrose Rel $
                      5:  *
                      6:  *
                      7:  *
                      8:  * $Log:       attrvalue.h,v $
                      9:  * Revision 7.0  89/11/23  21:56:22  mrose
                     10:  * Release 6.0
                     11:  * 
                     12:  */
                     13: 
                     14: /*
                     15:  *                               NOTICE
                     16:  *
                     17:  *    Acquisition, use, and distribution of this module and related
                     18:  *    materials are subject to the restrictions of a license agreement.
                     19:  *    Consult the Preface in the User's Manual for the full terms of
                     20:  *    this agreement.
                     21:  *
                     22:  */
                     23: 
                     24: 
                     25: #ifndef ATTRVALUE
                     26: #define ATTRVALUE
                     27: #include "quipu/name.h"
                     28: 
                     29: typedef struct avseqcomp {      /* attribute may have multiple values   */
                     30:                                /* respresents SET OF AttributeValue    */
                     31:     attrVal            avseq_av;
                     32:     struct avseqcomp    *avseq_next;
                     33: } avseqcomp, *AV_Sequence;
                     34: 
                     35: #define NULLAV ((AV_Sequence) 0)
                     36: #define avs_comp_alloc()        (AV_Sequence) smalloc(sizeof(avseqcomp))
                     37: 
                     38: #define avs_cmp_comp(x,y)        AttrV_cmp (&x->avseq_av ,&y->avseq_av)
                     39: AV_Sequence  avs_comp_new ();
                     40: AV_Sequence  avs_comp_cpy ();
                     41: AV_Sequence  avs_cpy ();
                     42: AV_Sequence  avs_merge ();
                     43: AV_Sequence  str2avs ();
                     44: 
                     45: typedef struct attrcomp {       /* A sequence of attributes             */
                     46:                                /* represents Attribute                 */
                     47:                                /* and SET OF Attribute                 */
                     48:     attrType           attr_type;
                     49:     AV_Sequence         attr_value;
                     50:     struct attrcomp     *attr_link;
                     51:                                /* ACL is NOT for use by DUA            */
                     52:                                /* this must be done by use of ACL      */
                     53:                                /* attribute                            */
                     54:     struct acl_info     *attr_acl;
                     55: } attrcomp, *Attr_Sequence;
                     56: 
                     57: #define NULLATTR ((Attr_Sequence) 0)
                     58: #define as_comp_alloc()          (Attr_Sequence) smalloc(sizeof(attrcomp))
                     59: #define as_comp_cmp(x,y)      (((oid_cmp (&x->attr_type ,&y->attr_type) == OK) && (avs_cmp (x->attr_value ,y->attr_value) == OK)) ? OK : NOTOK)
                     60: 
                     61: Attr_Sequence  as_comp_new ();
                     62: Attr_Sequence  as_comp_cpy ();
                     63: Attr_Sequence  as_cpy ();
                     64: Attr_Sequence  as_find_type ();
                     65: Attr_Sequence  as_merge ();
                     66: Attr_Sequence  str2as();
                     67: 
                     68: 
                     69:                                /* ACL is defined here as it is         */
                     70:                                /* referenced.   it is only used by     */
                     71:                                /* DSA                                  */
                     72:                                /* represents ACLInfo defined by INCA   */
                     73: struct acl_info {
                     74:     u_char  acl_categories;
                     75: #define ACL_NONE        0
                     76: #define ACL_DETECT      1
                     77: #define ACL_COMPARE     2
                     78: #define ACL_READ        3
                     79: #define ACL_ADD         4
                     80: #define ACL_WRITE       5
                     81:     u_char  acl_selector_type;
                     82: #define ACL_ENTRY       0
                     83: #define ACL_OTHER       1
                     84: #define ACL_PREFIX      2
                     85: #define ACL_GROUP       3
                     86:     struct dn_seq       *acl_name;    /* prefix and group only         */
                     87:     struct acl_info     *acl_next;
                     88: };
                     89: 
                     90: #define NULLACL_INFO (struct acl_info *) NULL
                     91: #define acl_info_alloc()        (struct acl_info *) smalloc (sizeof  (struct acl_info))
                     92: #define acl_info_fill(w,x,y,z)    w -> acl_categories = x ;  \
                     93:                                  w -> acl_selector_type = y; \
                     94:                                  w -> acl_name = z;
                     95: struct acl_info *acl_info_new ();
                     96: struct acl_info *acl_info_cpy();
                     97: struct acl_info *acl_default();
                     98: struct acl_info *acl_dflt();
                     99: 
                    100: struct mailbox {
                    101:        char *  mtype;
                    102:        char *  mbox;
                    103: };
                    104: 
                    105: struct fax {
                    106:     char    *number;
                    107:     PE     bits;
                    108: };
                    109: 
                    110: struct postaddr {
                    111:        char addrtype;   /* 1 == T61, 2 == Printstr */
                    112:        char * addrcomp;
                    113:        struct postaddr * pa_next;
                    114: };
                    115: 
                    116: struct telex {
                    117:        char * telexnumber;
                    118:        char * countrycode;
                    119:        char * answerback;
                    120: };
                    121: 
                    122: struct teletex {
                    123:        char    *terminal;
                    124:        char    *graphic;
                    125:        char    *control;
                    126:        char    *page;
                    127:        char    *misc;
                    128:        char    *t_private;
                    129: };
                    130: 
                    131: struct pref_deliv {
                    132:        int     deliv;
                    133:        struct pref_deliv * pd_next;
                    134: };
                    135: 
                    136: 
                    137: struct Guide {
                    138:        OID objectClass;
                    139:        struct Criteria * criteria;
                    140: };
                    141: 
                    142: struct Criteria {
                    143:     u_char     offset;
                    144: #define        Criteria_type   1
                    145: #define        Criteria_and    2
                    146: #define        Criteria_or     3
                    147: #define        Criteria_not    4
                    148: 
                    149:     union {
                    150:             struct CriteriaItem *type;
                    151:             struct and_or_set {
                    152:                     struct Criteria *and_or_comp;
                    153:                     struct and_or_set *and_or_next;
                    154:             } *and_or;
                    155:             struct Criteria *not;
                    156:     }       un;
                    157: };
                    158: 
                    159: struct CriteriaItem {
                    160:     u_char  offset;
                    161: #define        choice_equality         1
                    162: #define        choice_substrings       2
                    163: #define        choice_greaterOrEqual   3
                    164: #define        choice_lessOrEqual      4
                    165: #define        choice_approximateMatch 5
                    166:     AttributeType attrib;
                    167: };
                    168: 
                    169: 
                    170: /* Upper bounds */
                    171: #define UB_POSTAL_LINE         6
                    172: #define UB_POSTAL_STRING       30
                    173: #define UB_TELETEX_TERMINAL_ID         1024
                    174: #define UB_TELEPHONE_NUMBER    32
                    175: #define UB_TELEX_NUMBER                14
                    176: #define UB_ANSWERBACK          8
                    177: #define UB_COUNTRY_CODE                4
                    178: #endif

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.