mp.h revision 189092
1189251Ssam/* $FreeBSD: head/lib/libmp/mp.h 189092 2009-02-26 21:43:15Z ed $ */ 2252726Srpaulo 3252726Srpaulo#ifndef _MP_H_ 4189251Ssam#define _MP_H_ 5252726Srpaulo 6252726Srpaulo#ifndef HEADER_BN_H_ 7189251Ssam#include <openssl/bn.h> 8189251Ssam#endif 9189251Ssam 10189251Ssamtypedef struct _mint { 11189251Ssam BIGNUM *bn; 12189251Ssam} MINT; 13214734Srpaulo 14214734Srpaulovoid mp_gcd(const MINT *, const MINT *, MINT *); 15214734SrpauloMINT *mp_itom(short); 16214734Srpaulovoid mp_madd(const MINT *, const MINT *, MINT *); 17189251Ssamint mp_mcmp(const MINT *, const MINT *); 18214734Srpaulovoid mp_mdiv(const MINT *, const MINT *, MINT *, MINT *); 19214734Srpaulovoid mp_mfree(MINT *); 20189251Ssamvoid mp_min(MINT *); 21189251Ssamvoid mp_mout(const MINT *); 22189251Ssamvoid mp_move(const MINT *, MINT *); 23189251Ssamvoid mp_msqrt(const MINT *, MINT *, MINT *); 24189251Ssamvoid mp_msub(const MINT *, const MINT *, MINT *); 25189251Ssamchar *mp_mtox(const MINT *); 26189251Ssamvoid mp_mult(const MINT *, const MINT *, MINT *); 27189251Ssamvoid mp_pow(const MINT *, const MINT *, const MINT *, MINT *); 28189251Ssamvoid mp_rpow(const MINT *, short, MINT *); 29189251Ssamvoid mp_sdiv(const MINT *, short, MINT *, short *); 30189251SsamMINT *mp_xtom(const char *); 31189251Ssam 32189251Ssam#endif /* !_MP_H_ */ 33189251Ssam