The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/crypto/michael.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /*      $OpenBSD: michael.h,v 1.2 2012/12/05 23:20:15 deraadt Exp $     */
    2 
    3 /*
    4  * Copyright (c) 2005, 2006 Reyk Floeter <reyk@openbsd.org>
    5  *
    6  * Permission to use, copy, modify, and distribute this software for any
    7  * purpose with or without fee is hereby granted, provided that the above
    8  * copyright notice and this permission notice appear in all copies.
    9  *
   10  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
   11  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
   12  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
   13  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
   14  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
   15  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
   16  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
   17  */
   18 
   19 #ifndef _MICHAEL_H_
   20 #define _MICHAEL_H_
   21 
   22 #define MICHAEL_BLOCK_LENGTH            8
   23 #define MICHAEL_RAW_BLOCK_LENGTH        4
   24 #define MICHAEL_DIGEST_LENGTH           8
   25 
   26 typedef struct michael_context {
   27         u_int32_t       michael_key[2];
   28         u_int32_t       michael_l, michael_r;
   29         u_int32_t       michael_state;
   30         u_int           michael_count;
   31 } MICHAEL_CTX;
   32 
   33 __BEGIN_DECLS
   34 void     michael_init(MICHAEL_CTX *);
   35 void     michael_update(MICHAEL_CTX *, const u_int8_t *, u_int)
   36             __attribute__((__bounded__(__buffer__, 2, 3)));
   37 void     michael_final(u_int8_t [MICHAEL_DIGEST_LENGTH], MICHAEL_CTX *)
   38             __attribute__((__bounded__(__minbytes__, 1,
   39             MICHAEL_DIGEST_LENGTH)));
   40 void     michael_key(const u_int8_t *, MICHAEL_CTX *)
   41             __attribute__((__bounded__(__minbytes__, 1,
   42             MICHAEL_BLOCK_LENGTH)));
   43 __END_DECLS
   44 
   45 #endif /* _MICHAEL_H_ */

Cache object: 473e01755df92f8ffe3ed6f68df40edb


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.