Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
sgxwallet
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
董子豪
sgxwallet
Commits
c6dfc661
Unverified
Commit
c6dfc661
authored
Aug 13, 2020
by
kladko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SKALE-3067-cleanup-sgx
parent
ec9ff9f4
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
1 addition
and
374 deletions
+1
-374
BLSPrivateKeyShareSGX.cpp
BLSPrivateKeyShareSGX.cpp
+1
-1
secure_enclave.edl
secure_enclave/secure_enclave.edl
+0
-111
testw.cpp
testw.cpp
+0
-262
No files found.
BLSPrivateKeyShareSGX.cpp
View file @
c6dfc661
...
@@ -151,7 +151,7 @@ std::string BLSPrivateKeyShareSGX::signWithHelperSGXstr(
...
@@ -151,7 +151,7 @@ std::string BLSPrivateKeyShareSGX::signWithHelperSGXstr(
cerr
<<
"Key is "
+
*
encryptedKeyHex
<<
endl
;
cerr
<<
"Key is "
+
*
encryptedKeyHex
<<
endl
;
sgx_status_t
status
=
sgx_status_t
status
=
trustedBlsSignMessage
(
eid
,
&
errStatus
,
errMsg
,
encryptedKey
,
trustedBlsSignMessage
AES
(
eid
,
&
errStatus
,
errMsg
,
encryptedKey
,
encryptedKeyHex
->
size
()
/
2
,
xStrArg
,
yStrArg
,
signature
);
encryptedKeyHex
->
size
()
/
2
,
xStrArg
,
yStrArg
,
signature
);
printf
(
"sig is: %s
\n
"
,
signature
);
printf
(
"sig is: %s
\n
"
,
signature
);
...
...
secure_enclave/secure_enclave.edl
View file @
c6dfc661
...
@@ -11,103 +11,6 @@ enclave {
...
@@ -11,103 +11,6 @@ enclave {
public void trustedEnclaveInit(uint32_t _logLevel);
public void trustedEnclaveInit(uint32_t _logLevel);
public void trustedGenerateEcdsaKey (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[out, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
[out] uint32_t *enc_len,
[out, count = SMALL_BUF_SIZE] char * pub_key_x,
[out, count = SMALL_BUF_SIZE] char * pub_key_y);
public void trustedGetPublicEcdsaKey (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
uint32_t dec_len,
[out, count = SMALL_BUF_SIZE] char * pub_key_x,
[out, count = SMALL_BUF_SIZE] char * pub_key_y);
public void trustedEncryptKey (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = SMALL_BUF_SIZE] const char* key,
[out, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
[out] uint32_t *enc_len);
public void trustedDecryptKey (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
uint32_t enc_len,
[out, count = SMALL_BUF_SIZE] char* key );
public void trustedBlsSignMessage (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
uint32_t enc_len,
[in, string] char* hashX ,
[in, string] char* hashY ,
[out, count = SMALL_BUF_SIZE] char* signature);
public void trustedGenDkgSecret (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[out, count = 3050] uint8_t* encrypted_dkg_secret,
[out] uint32_t * enc_len,
size_t _t);
public void trustedDecryptDkgSecret (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = 3050] uint8_t* encrypted_dkg_secret,
[out, count = 2490] uint8_t* decrypted_dkg_secret,
[out] uint32_t* dec_len);
public void trustedGetSecretShares (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = 3050] uint8_t* encrypted_dkg_secret,
[out] uint32_t* dec_len,
[out, count = 2490] char* secret_shares,
unsigned _t,
unsigned _n);
public void trustedGetPublicShares (
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = 3050] uint8_t* encrypted_dkg_secret,
uint32_t enc_len,
[out, count = 10000] char* public_shares,
unsigned _t,
unsigned _n);
public void trustedEcdsaSign(
[out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
uint32_t enc_len,
[in, string] unsigned char* hash,
[out, count = SMALL_BUF_SIZE] char* sig_r,
[out, count = SMALL_BUF_SIZE] char* sig_s,
[out] uint8_t* sig_v,
int base);
public void trustedSetEncryptedDkgPoly( [out] int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = 3050] uint8_t* encrypted_poly);
public void trustedGetEncryptedSecretShare(
[out]int *errStatus,
[out, count = SMALL_BUF_SIZE] char *err_string,
[out, count = SMALL_BUF_SIZE] uint8_t *encrypted_skey,
[out] uint32_t* dec_len,
[out, count = 193] char* result_str,
[out, count = 320] char* s_shareG2,
[in, string] char* pub_keyB,
uint8_t _t,
uint8_t _n,
uint8_t ind);
public void trustedDkgVerify(
public void trustedDkgVerify(
[out] int *errStatus,
[out] int *errStatus,
...
@@ -120,21 +23,7 @@ enclave {
...
@@ -120,21 +23,7 @@ enclave {
int _ind,
int _ind,
[out] int* result);
[out] int* result);
public void trustedCreateBlsKey(
[out]int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, string] const char* s_shares,
[in, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
uint64_t key_len,
[out, count = SMALL_BUF_SIZE] uint8_t * encr_bls_key,
[out] uint32_t *enc_bls_key_len);
public void trustedGetBlsPubKey(
[out]int *errStatus,
[out, count = SMALL_BUF_SIZE] char* err_string,
[in, count = SMALL_BUF_SIZE] uint8_t* encrypted_key,
uint64_t key_len,
[out, count = 320] char* bls_pub_key);
public void trustedComplaintResponse(
public void trustedComplaintResponse(
[out] int *errStatus,
[out] int *errStatus,
...
...
testw.cpp
View file @
c6dfc661
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment