110500SHai-May.Chao@Sun.COM /* 210500SHai-May.Chao@Sun.COM * CDDL HEADER START 310500SHai-May.Chao@Sun.COM * 410500SHai-May.Chao@Sun.COM * The contents of this file are subject to the terms of the 510500SHai-May.Chao@Sun.COM * Common Development and Distribution License (the "License"). 610500SHai-May.Chao@Sun.COM * You may not use this file except in compliance with the License. 710500SHai-May.Chao@Sun.COM * 810500SHai-May.Chao@Sun.COM * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 910500SHai-May.Chao@Sun.COM * or http://www.opensolaris.org/os/licensing. 1010500SHai-May.Chao@Sun.COM * See the License for the specific language governing permissions 1110500SHai-May.Chao@Sun.COM * and limitations under the License. 1210500SHai-May.Chao@Sun.COM * 1310500SHai-May.Chao@Sun.COM * When distributing Covered Code, include this CDDL HEADER in each 1410500SHai-May.Chao@Sun.COM * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 1510500SHai-May.Chao@Sun.COM * If applicable, add the following below this CDDL HEADER, with the 1610500SHai-May.Chao@Sun.COM * fields enclosed by brackets "[]" replaced with your own identifying 1710500SHai-May.Chao@Sun.COM * information: Portions Copyright [yyyy] [name of copyright owner] 1810500SHai-May.Chao@Sun.COM * 1910500SHai-May.Chao@Sun.COM * CDDL HEADER END 2010500SHai-May.Chao@Sun.COM */ 21*12573SDina.Nimeh@Sun.COM 2210500SHai-May.Chao@Sun.COM /* 23*12573SDina.Nimeh@Sun.COM * Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved. 2410500SHai-May.Chao@Sun.COM */ 2510500SHai-May.Chao@Sun.COM 2610500SHai-May.Chao@Sun.COM #ifndef _FIPS_POST_H 2710500SHai-May.Chao@Sun.COM #define _FIPS_POST_H 2810500SHai-May.Chao@Sun.COM 2910500SHai-May.Chao@Sun.COM #ifdef __cplusplus 3010500SHai-May.Chao@Sun.COM extern "C" { 3110500SHai-May.Chao@Sun.COM #endif 3210500SHai-May.Chao@Sun.COM 3310500SHai-May.Chao@Sun.COM #define FIPS_KNOWN_HMAC_MESSAGE_LENGTH 64 /* 512-bits */ 3410500SHai-May.Chao@Sun.COM 3510500SHai-May.Chao@Sun.COM #ifdef _KERNEL 3610500SHai-May.Chao@Sun.COM 3710500SHai-May.Chao@Sun.COM #define CK_BYTE uchar_t 3810500SHai-May.Chao@Sun.COM #define CK_ULONG ulong_t 3910500SHai-May.Chao@Sun.COM #define CK_RV int 40*12573SDina.Nimeh@Sun.COM 4110500SHai-May.Chao@Sun.COM #define CKR_OK CRYPTO_SUCCESS 4210500SHai-May.Chao@Sun.COM #define CKR_HOST_MEMORY CRYPTO_HOST_MEMORY 4310500SHai-May.Chao@Sun.COM #define CKR_DEVICE_ERROR CRYPTO_DEVICE_ERROR 4410500SHai-May.Chao@Sun.COM #define CKR_DATA_LEN_RANGE CRYPTO_DATA_LEN_RANGE 4510500SHai-May.Chao@Sun.COM #define CKR_ENCRYPTED_DATA_LEN_RANGE CRYPTO_ENCRYPTED_DATA_LEN_RANGE 4610500SHai-May.Chao@Sun.COM #define CKR_ENCRYPTED_DATA_INVALID CRYPTO_ENCRYPTED_DATA_INVALID 4710500SHai-May.Chao@Sun.COM #define CKR_SIGNATURE_INVALID CRYPTO_SIGNATURE_INVALID 48*12573SDina.Nimeh@Sun.COM #define CKR_SIGNATURE_LEN_RANGE CRYPTO_SIGNATURE_LEN_RANGE 4910500SHai-May.Chao@Sun.COM #define CKR_ARGUMENTS_BAD CRYPTO_ARGUMENTS_BAD 5010500SHai-May.Chao@Sun.COM 5110500SHai-May.Chao@Sun.COM #else 5210500SHai-May.Chao@Sun.COM 5310500SHai-May.Chao@Sun.COM #define FIPS_RNG_XKEY_LENGTH 32 /* 256-bits */ 5410500SHai-May.Chao@Sun.COM #define PAIRWISE_DIGEST_LENGTH 20 /* 160-bits */ 5510500SHai-May.Chao@Sun.COM #define PAIRWISE_MESSAGE_LENGTH 20 /* 160-bits */ 5610500SHai-May.Chao@Sun.COM 5710500SHai-May.Chao@Sun.COM #endif /* _KERNEL */ 5810500SHai-May.Chao@Sun.COM 5910500SHai-May.Chao@Sun.COM #ifdef __cplusplus 6010500SHai-May.Chao@Sun.COM } 6110500SHai-May.Chao@Sun.COM #endif 6210500SHai-May.Chao@Sun.COM 6310500SHai-May.Chao@Sun.COM #endif /* _FIPS_POST_H */ 64