padding.h revision 726fad2a65f16c200a03969c29cb5c86c2d427db
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * CDDL HEADER START
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * The contents of this file are subject to the terms of the
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * Common Development and Distribution License (the "License").
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * You may not use this file except in compliance with the License.
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * See the License for the specific language governing permissions
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * and limitations under the License.
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * When distributing Covered Code, include this CDDL HEADER in each
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * If applicable, add the following below this CDDL HEADER, with the
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * fields enclosed by brackets "[]" replaced with your own identifying
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * information: Portions Copyright [yyyy] [name of copyright owner]
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * CDDL HEADER END
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh * Values for PKCS#1 method of encoding/decoding.
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh#define CKR_DATA_LEN_RANGE CRYPTO_DATA_LEN_RANGE
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh#define CKR_ENCRYPTED_DATA_INVALID CRYPTO_ENCRYPTED_DATA_INVALID
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh#define CKR_SIGNATURE_INVALID CRYPTO_SIGNATURE_INVALID
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimehint knzero_random_generator(uint8_t *ran_out, size_t ran_len);
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimehvoid kmemset(uint8_t *buf, char pattern, size_t len);
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh#endif /* _KERNEL */
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimehint pkcs1_encode(int method, uint8_t *databuf, size_t datalen, uint8_t *padbuf,
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimehint pkcs1_decode(int method, uint8_t *padbuf, size_t *plen);
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimehint pkcs7_encode(uint8_t *databuf, size_t datalen, uint8_t *padbuf,
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimehint pkcs7_decode(uint8_t *padbuf, size_t *plen);
726fad2a65f16c200a03969c29cb5c86c2d427dbDina K Nimeh#endif /* _PADDING_H */