13ff40c12SJohn Marino /* 23ff40c12SJohn Marino * PKCS #1 (RSA Encryption) 33ff40c12SJohn Marino * Copyright (c) 2006-2009, Jouni Malinen <j@w1.fi> 43ff40c12SJohn Marino * 53ff40c12SJohn Marino * This software may be distributed under the terms of the BSD license. 63ff40c12SJohn Marino * See README for more details. 73ff40c12SJohn Marino */ 83ff40c12SJohn Marino 93ff40c12SJohn Marino #ifndef PKCS1_H 103ff40c12SJohn Marino #define PKCS1_H 113ff40c12SJohn Marino 12*a1157835SDaniel Fojt struct crypto_public_key; 13*a1157835SDaniel Fojt struct asn1_oid; 14*a1157835SDaniel Fojt 153ff40c12SJohn Marino int pkcs1_encrypt(int block_type, struct crypto_rsa_key *key, 163ff40c12SJohn Marino int use_private, const u8 *in, size_t inlen, 173ff40c12SJohn Marino u8 *out, size_t *outlen); 183ff40c12SJohn Marino int pkcs1_v15_private_key_decrypt(struct crypto_rsa_key *key, 193ff40c12SJohn Marino const u8 *in, size_t inlen, 203ff40c12SJohn Marino u8 *out, size_t *outlen); 213ff40c12SJohn Marino int pkcs1_decrypt_public_key(struct crypto_rsa_key *key, 223ff40c12SJohn Marino const u8 *crypt, size_t crypt_len, 233ff40c12SJohn Marino u8 *plain, size_t *plain_len); 24*a1157835SDaniel Fojt int pkcs1_v15_sig_ver(struct crypto_public_key *pk, 25*a1157835SDaniel Fojt const u8 *s, size_t s_len, 26*a1157835SDaniel Fojt const struct asn1_oid *hash_alg, 27*a1157835SDaniel Fojt const u8 *hash, size_t hash_len); 283ff40c12SJohn Marino 293ff40c12SJohn Marino #endif /* PKCS1_H */ 30