-
Notifications
You must be signed in to change notification settings - Fork 49
Expand file tree
/
Copy pathfourq_qubic.h
More file actions
18 lines (16 loc) · 852 Bytes
/
fourq_qubic.h
File metadata and controls
18 lines (16 loc) · 852 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#pragma once
typedef unsigned long long felm_t[2]; // Datatype for representing 128-bit field elements
typedef felm_t f2elm_t[2]; // Datatype for representing quadratic extension field elements
typedef struct
{ // Point representation in affine coordinates
f2elm_t x;
f2elm_t y;
} point_affine;
typedef point_affine point_t[1];
extern "C" {
void ecc_mul_fixed(unsigned long long* k, point_t Q);
void encode(point_t P, unsigned char* Pencoded);
void sign(const unsigned char* subSeed, const unsigned char* publicKey, const unsigned char* messageDigest, unsigned char* signature);
void signWithNonceK(const unsigned char* input, const unsigned char* publicKey, const unsigned char* messageDigest, unsigned char* signature);
bool verify(const unsigned char* publicKey, const unsigned char* messageDigest, const unsigned char* signature);
}