1# Generated by h2py from stdin 2 3# Included from sys/ioccom.h 4IOCPARM_SHIFT = 13 5IOCPARM_MASK = ((1 << IOCPARM_SHIFT) - 1) 6def IOCPARM_LEN(x): return (((x) >> 16) & IOCPARM_MASK) 7 8def IOCBASECMD(x): return ((x) & ~(IOCPARM_MASK << 16)) 9 10def IOCGROUP(x): return (((x) >> 8) & 0xff) 11 12IOCPARM_MAX = (1 << IOCPARM_SHIFT) 13IOC_VOID = 0x20000000 14IOC_OUT = 0x40000000 15IOC_IN = 0x80000000 16IOC_INOUT = (IOC_IN|IOC_OUT) 17IOC_DIRMASK = (IOC_VOID|IOC_OUT|IOC_IN) 18 19# Included from sys/cdefs.h 20def __has_feature(x): return 0 21 22def __has_include(x): return 0 23 24def __has_builtin(x): return 0 25 26__GNUCLIKE_ASM = 3 27__GNUCLIKE_ASM = 2 28__GNUCLIKE___TYPEOF = 1 29__GNUCLIKE___SECTION = 1 30__GNUCLIKE_CTOR_SECTION_HANDLING = 1 31__GNUCLIKE_BUILTIN_CONSTANT_P = 1 32__GNUCLIKE_BUILTIN_VARARGS = 1 33__GNUCLIKE_BUILTIN_STDARG = 1 34__GNUCLIKE_BUILTIN_VAALIST = 1 35__GNUC_VA_LIST_COMPATIBILITY = 1 36__GNUCLIKE_BUILTIN_NEXT_ARG = 1 37__GNUCLIKE_BUILTIN_MEMCPY = 1 38__CC_SUPPORTS_INLINE = 1 39__CC_SUPPORTS___INLINE = 1 40__CC_SUPPORTS___INLINE__ = 1 41__CC_SUPPORTS___FUNC__ = 1 42__CC_SUPPORTS_WARNING = 1 43__CC_SUPPORTS_VARADIC_XXX = 1 44__CC_SUPPORTS_DYNAMIC_ARRAY_INIT = 1 45def __P(protos): return protos 46 47def __STRING(x): return #x 48 49def __XSTRING(x): return __STRING(x) 50 51def __P(protos): return () 52 53def __STRING(x): return "x" 54 55def __aligned(x): return __attribute__((__aligned__(x))) 56 57def __section(x): return __attribute__((__section__(x))) 58 59def __aligned(x): return __attribute__((__aligned__(x))) 60 61def __section(x): return __attribute__((__section__(x))) 62 63def _Alignas(x): return alignas(x) 64 65def _Alignas(x): return __aligned(x) 66 67def _Alignof(x): return alignof(x) 68 69def _Alignof(x): return __alignof(x) 70 71def __nonnull(x): return __attribute__((__nonnull__(x))) 72 73def __predict_true(exp): return __builtin_expect((exp), 1) 74 75def __predict_false(exp): return __builtin_expect((exp), 0) 76 77def __predict_true(exp): return (exp) 78 79def __predict_false(exp): return (exp) 80 81def __format_arg(fmtarg): return __attribute__((__format_arg__ (fmtarg))) 82 83def __GLOBL(sym): return __GLOBL1(sym) 84 85def __FBSDID(s): return __IDSTRING(__CONCAT(__rcsid_,__LINE__),s) 86 87def __RCSID(s): return __IDSTRING(__CONCAT(__rcsid_,__LINE__),s) 88 89def __RCSID_SOURCE(s): return __IDSTRING(__CONCAT(__rcsid_source_,__LINE__),s) 90 91def __SCCSID(s): return __IDSTRING(__CONCAT(__sccsid_,__LINE__),s) 92 93def __COPYRIGHT(s): return __IDSTRING(__CONCAT(__copyright_,__LINE__),s) 94 95_POSIX_C_SOURCE = 199009 96_POSIX_C_SOURCE = 199209 97__XSI_VISIBLE = 700 98_POSIX_C_SOURCE = 200809 99__XSI_VISIBLE = 600 100_POSIX_C_SOURCE = 200112 101__XSI_VISIBLE = 500 102_POSIX_C_SOURCE = 199506 103_POSIX_C_SOURCE = 198808 104__POSIX_VISIBLE = 200809 105__ISO_C_VISIBLE = 1999 106__POSIX_VISIBLE = 200112 107__ISO_C_VISIBLE = 1999 108__POSIX_VISIBLE = 199506 109__ISO_C_VISIBLE = 1990 110__POSIX_VISIBLE = 199309 111__ISO_C_VISIBLE = 1990 112__POSIX_VISIBLE = 199209 113__ISO_C_VISIBLE = 1990 114__POSIX_VISIBLE = 199009 115__ISO_C_VISIBLE = 1990 116__POSIX_VISIBLE = 198808 117__ISO_C_VISIBLE = 0 118__POSIX_VISIBLE = 0 119__XSI_VISIBLE = 0 120__BSD_VISIBLE = 0 121__ISO_C_VISIBLE = 1990 122__POSIX_VISIBLE = 0 123__XSI_VISIBLE = 0 124__BSD_VISIBLE = 0 125__ISO_C_VISIBLE = 1999 126__POSIX_VISIBLE = 0 127__XSI_VISIBLE = 0 128__BSD_VISIBLE = 0 129__ISO_C_VISIBLE = 2011 130__POSIX_VISIBLE = 200809 131__XSI_VISIBLE = 700 132__BSD_VISIBLE = 1 133__ISO_C_VISIBLE = 2011 134CRYPTO_DRIVERS_INITIAL = 4 135CRYPTO_SW_SESSIONS = 32 136NULL_HASH_LEN = 16 137MD5_HASH_LEN = 16 138SHA1_HASH_LEN = 20 139RIPEMD160_HASH_LEN = 20 140SHA2_256_HASH_LEN = 32 141SHA2_384_HASH_LEN = 48 142SHA2_512_HASH_LEN = 64 143MD5_KPDK_HASH_LEN = 16 144SHA1_KPDK_HASH_LEN = 20 145HASH_MAX_LEN = SHA2_512_HASH_LEN 146NULL_HMAC_BLOCK_LEN = 64 147MD5_HMAC_BLOCK_LEN = 64 148SHA1_HMAC_BLOCK_LEN = 64 149RIPEMD160_HMAC_BLOCK_LEN = 64 150SHA2_256_HMAC_BLOCK_LEN = 64 151SHA2_384_HMAC_BLOCK_LEN = 128 152SHA2_512_HMAC_BLOCK_LEN = 128 153HMAC_MAX_BLOCK_LEN = SHA2_512_HMAC_BLOCK_LEN 154HMAC_IPAD_VAL = 0x36 155HMAC_OPAD_VAL = 0x5C 156NULL_BLOCK_LEN = 4 157DES_BLOCK_LEN = 8 158DES3_BLOCK_LEN = 8 159BLOWFISH_BLOCK_LEN = 8 160SKIPJACK_BLOCK_LEN = 8 161CAST128_BLOCK_LEN = 8 162RIJNDAEL128_BLOCK_LEN = 16 163AES_BLOCK_LEN = RIJNDAEL128_BLOCK_LEN 164CAMELLIA_BLOCK_LEN = 16 165EALG_MAX_BLOCK_LEN = AES_BLOCK_LEN 166AALG_MAX_RESULT_LEN = 64 167CRYPTO_ALGORITHM_MIN = 1 168CRYPTO_DES_CBC = 1 169CRYPTO_3DES_CBC = 2 170CRYPTO_BLF_CBC = 3 171CRYPTO_CAST_CBC = 4 172CRYPTO_SKIPJACK_CBC = 5 173CRYPTO_MD5_HMAC = 6 174CRYPTO_SHA1_HMAC = 7 175CRYPTO_RIPEMD160_HMAC = 8 176CRYPTO_MD5_KPDK = 9 177CRYPTO_SHA1_KPDK = 10 178CRYPTO_RIJNDAEL128_CBC = 11 179CRYPTO_AES_CBC = 11 180CRYPTO_ARC4 = 12 181CRYPTO_MD5 = 13 182CRYPTO_SHA1 = 14 183CRYPTO_NULL_HMAC = 15 184CRYPTO_NULL_CBC = 16 185CRYPTO_DEFLATE_COMP = 17 186CRYPTO_SHA2_256_HMAC = 18 187CRYPTO_SHA2_384_HMAC = 19 188CRYPTO_SHA2_512_HMAC = 20 189CRYPTO_CAMELLIA_CBC = 21 190CRYPTO_AES_XTS = 22 191CRYPTO_AES_ICM = 23 192CRYPTO_AES_NIST_GMAC = 24 193CRYPTO_AES_NIST_GCM_16 = 25 194CRYPTO_BLAKE2B = 29 195CRYPTO_BLAKE2S = 30 196CRYPTO_CHACHA20 = 31 197CRYPTO_SHA2_224_HMAC = 32 198CRYPTO_RIPEMD160 = 33 199CRYPTO_SHA2_224 = 34 200CRYPTO_SHA2_256 = 35 201CRYPTO_SHA2_384 = 36 202CRYPTO_SHA2_512 = 37 203CRYPTO_POLY1305 = 38 204CRYPTO_AES_CCM_CBC_MAC = 39 205CRYPTO_AES_CCM_16 = 40 206CRYPTO_ALGORITHM_MAX = 40 207CRYPTO_ALG_FLAG_SUPPORTED = 0x01 208CRYPTO_ALG_FLAG_RNG_ENABLE = 0x02 209CRYPTO_ALG_FLAG_DSA_SHA = 0x04 210CRYPTO_FLAG_HARDWARE = 0x01000000 211CRYPTO_FLAG_SOFTWARE = 0x02000000 212COP_ENCRYPT = 1 213COP_DECRYPT = 2 214COP_F_BATCH = 0x0008 215CRK_MAXPARAM = 8 216CRK_ALGORITM_MIN = 0 217CRK_MOD_EXP = 0 218CRK_MOD_EXP_CRT = 1 219CRK_DSA_SIGN = 2 220CRK_DSA_VERIFY = 3 221CRK_DH_COMPUTE_KEY = 4 222CRK_ALGORITHM_MAX = 4 223CRF_MOD_EXP = (1 << CRK_MOD_EXP) 224CRF_MOD_EXP_CRT = (1 << CRK_MOD_EXP_CRT) 225CRF_DSA_SIGN = (1 << CRK_DSA_SIGN) 226CRF_DSA_VERIFY = (1 << CRK_DSA_VERIFY) 227CRF_DH_COMPUTE_KEY = (1 << CRK_DH_COMPUTE_KEY) 228CRD_F_ENCRYPT = 0x01 229CRD_F_IV_PRESENT = 0x02 230CRD_F_IV_EXPLICIT = 0x04 231CRD_F_DSA_SHA_NEEDED = 0x08 232CRD_F_COMP = 0x0f 233CRD_F_KEY_EXPLICIT = 0x10 234CRYPTO_F_IMBUF = 0x0001 235CRYPTO_F_IOV = 0x0002 236CRYPTO_F_BATCH = 0x0008 237CRYPTO_F_CBIMM = 0x0010 238CRYPTO_F_DONE = 0x0020 239CRYPTO_F_CBIFSYNC = 0x0040 240CRYPTO_BUF_CONTIG = 0x0 241CRYPTO_BUF_IOV = 0x1 242CRYPTO_BUF_MBUF = 0x2 243CRYPTO_OP_DECRYPT = 0x0 244CRYPTO_OP_ENCRYPT = 0x1 245CRYPTO_HINT_MORE = 0x1 246def CRYPTO_SESID2HID(_sid): return (((_sid) >> 32) & 0x00ffffff) 247 248def CRYPTO_SESID2CAPS(_sid): return (((_sid) >> 32) & 0xff000000) 249 250def CRYPTO_SESID2LID(_sid): return (((u_int32_t) (_sid)) & 0xffffffff) 251 252CRYPTOCAP_F_HARDWARE = CRYPTO_FLAG_HARDWARE 253CRYPTOCAP_F_SOFTWARE = CRYPTO_FLAG_SOFTWARE 254CRYPTOCAP_F_SYNC = 0x04000000 255CRYPTO_SYMQ = 0x1 256CRYPTO_ASYMQ = 0x2 257