|
@ -887,7 +887,7 @@ uint8_t *SuperNET_ciphercalc(void **ptrp,int32_t *cipherlenp,bits256 *privkeyp,b |
|
|
cJSON *SuperNET_rosettajson(struct supernet_info *myinfo,bits256 privkey,int32_t showprivs) |
|
|
cJSON *SuperNET_rosettajson(struct supernet_info *myinfo,bits256 privkey,int32_t showprivs) |
|
|
{ |
|
|
{ |
|
|
uint8_t rmd160[20],pub[33]; uint64_t nxt64bits; bits256 pubkey; |
|
|
uint8_t rmd160[20],pub[33]; uint64_t nxt64bits; bits256 pubkey; |
|
|
char str2[41],wifbuf[64],addr[64],str[128],coinwif[16]; cJSON *retjson; struct iguana_info *coin,*tmp; |
|
|
char str2[41],wifbuf[64],pbuf[65],addr[64],str[128],coinwif[16]; cJSON *retjson; struct iguana_info *coin,*tmp; |
|
|
pubkey = acct777_pubkey(privkey); |
|
|
pubkey = acct777_pubkey(privkey); |
|
|
nxt64bits = acct777_nxt64bits(pubkey); |
|
|
nxt64bits = acct777_nxt64bits(pubkey); |
|
|
retjson = cJSON_CreateObject(); |
|
|
retjson = cJSON_CreateObject(); |
|
@ -900,6 +900,8 @@ cJSON *SuperNET_rosettajson(struct supernet_info *myinfo,bits256 privkey,int32_t |
|
|
jaddstr(retjson,"btcpubkey",str); |
|
|
jaddstr(retjson,"btcpubkey",str); |
|
|
calc_OP_HASH160(str2,rmd160,str); |
|
|
calc_OP_HASH160(str2,rmd160,str); |
|
|
jaddstr(retjson,"rmd160",str2); |
|
|
jaddstr(retjson,"rmd160",str2); |
|
|
|
|
|
if ( showprivs != 0 ) |
|
|
|
|
|
jaddstr(retjson,"privkey",bits256_str(pbuf,privkey)); |
|
|
HASH_ITER(hh,myinfo->allcoins,coin,tmp) |
|
|
HASH_ITER(hh,myinfo->allcoins,coin,tmp) |
|
|
{ |
|
|
{ |
|
|
if ( coin != 0 && coin->symbol[0] != 0 ) |
|
|
if ( coin != 0 && coin->symbol[0] != 0 ) |
|
|