ebrick2.h
来自「比较新的功能强大的rsa算法源代码,方便使用.」· C头文件 代码 · 共 39 行
H
39 行
/*
* MIRACL C++ Header file ebrick2.h
*
* AUTHOR : M. Scott
*
* PURPOSE : Definition of class EBrick2
* Brickell et al's method for fast exponentiation with
* precomputation - elliptic curve version GF(2^m)
* NOTE : Must be used in conjunction with big.cpp
*
* Copyright (c) 2000 Shamus Software Ltd.
*/
#ifndef EBRICK2_H
#define EBRICK2_H
#include "big.h"
class EBrick2
{
BOOL created;
ebrick2 B;
public:
EBrick2(Big x,Big y,Big a2,Big a6,int m,int a,int b,int c,int window,int nb)
{ebrick2_init(&B,x.getbig(),y.getbig(),a2.getbig(),a6.getbig(),m,a,b,c,window,nb);
created=TRUE;}
EBrick2(ebrick2 *b) {B=*b; created=FALSE;} /* set structure */
ebrick2 *get(void) {return &B;} /* get address of structure */
int mul(Big &e,Big &x,Big &y) {int d=mul2_brick(&B,e.getbig(),x.getbig(),y.getbig()); return d;}
~EBrick2() {if (created) ebrick2_end(&B);}
};
#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?