Sign in
plan9port
/
plan9
/
32c6e78c6c4c13b63d8dc30aa395cfcc6e686c0a
/
.
/
src
/
libsec
/
port
/
rsaencrypt.c
blob: ade686dce055be5a04c49a50cbaf3bb4d4e5441b [
file
] [
log
] [
blame
]
#include
"os.h"
#include
<mp.h>
#include
<libsec.h>
mpint
*
rsaencrypt
(
RSApub
*
rsa
,
mpint
*
in
,
mpint
*
out
)
{
if
(
out
==
nil
)
out
=
mpnew
(
0
);
mpexp
(
in
,
rsa
->
ek
,
rsa
->
n
,
out
);
return
out
;
}