Browse Source

LTCwif to encrypt wallet output

etomic
jl777 8 years ago
parent
commit
03e8a5a185
  1. 5
      iguana/iguana_wallet.c
  2. 3
      iguana/kmd_lookup.h
  3. 2
      iguana/tests/statstest

5
iguana/iguana_wallet.c

@ -1431,6 +1431,11 @@ THREE_STRINGS(bitcoinrpc,encryptwallet,passphrase,password,permanentfile)
bitcoin_priv2wif(wifstr,waddr.privkey,coin->chain->wiftype);
jaddstr(retjson,"KMDwif",wifstr);
}
if ( (coin= iguana_coinfind("LTC")) != 0 )
{
bitcoin_priv2wif(wifstr,waddr.privkey,coin->chain->wiftype);
jaddstr(retjson,"LTCwif",wifstr);
}
if ( need_BTC != 0 )
{
bitcoin_priv2wif(wifstr,waddr.privkey,128);

3
iguana/kmd_lookup.h

@ -704,6 +704,7 @@ int32_t _kmd_bitcoinscan(struct iguana_info *coin)
{
ptr->fpos = ftell(coin->kmd_txidfp);
fwrite(tx,1,sizeof(*tx) + tx->numvouts*sizeof(*tx->vouts),coin->kmd_txidfp);
fflush(coin->kmd_txidfp);
}
}
else
@ -712,6 +713,7 @@ int32_t _kmd_bitcoinscan(struct iguana_info *coin)
{
fwrite(&txid,1,sizeof(txid),coin->kmd_spendfp);
fwrite(&numvins,1,sizeof(numvins),coin->kmd_spendfp);
fflush(coin->kmd_spendfp);
}
for (j=0; j<numvins; j++)
{
@ -730,6 +732,7 @@ int32_t _kmd_bitcoinscan(struct iguana_info *coin)
{
fwrite(&spenttxid,1,sizeof(spenttxid),coin->kmd_spendfp);
fwrite(&spentvout,1,sizeof(spentvout),coin->kmd_spendfp);
fflush(coin->kmd_spendfp);
}
}
}

2
iguana/tests/statstest

@ -1,3 +1,3 @@
#!/bin/bash
curl --url "http://127.0.0.1:7779" --data "{\"method\":\"bitmap\",\"endtimestamp\":0,\"source\":\"KMD\",\"dest\":\"BTC\",\"numdates\":30}"
#curl --url "http://127.0.0.1:7779" --data "{\"method\":\"bitmap\",\"endtimestamp\":0,\"source\":\"KMD\",\"dest\":\"BTC\",\"numdates\":30}"
curl --url "http://78.46.193.199:7779" --data "{\"method\":\"bitmap\",\"endtimestamp\":0,\"source\":\"KMD\",\"dest\":\"BTC\",\"numdates\":30}"

Loading…
Cancel
Save