aboutsummaryrefslogtreecommitdiff
path: root/src/libsec/port/dsaprivtopub.c
blob: e1790cae114d5051d35a9da13d1a354f5e71158b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "os.h"
#include <mp.h>
#include <libsec.h>

DSApub*
dsaprivtopub(DSApriv *priv)
{
	DSApub *pub;

	pub = dsapuballoc();
	pub->p = mpcopy(priv->pub.p);
	pub->q = mpcopy(priv->pub.q);
	pub->alpha = mpcopy(priv->pub.alpha);
	pub->key = mpcopy(priv->pub.key);
	return pub;
}