Browse Source

Revert walletpassphrase change

etomic
jl777 8 years ago
parent
commit
c091a58ffe
  1. 4
      iguana/SuperNET_keys.c
  2. 3
      iguana/iguana_rpc.c
  3. 3
      iguana/iguana_wallet.c
  4. 3
      iguana/main.c

4
iguana/SuperNET_keys.c

@ -22,8 +22,6 @@
#include "../includes/curve25519.h"
#include "../includes/cJSON.h"
extern int32_t EncryptWallet;
/*
if ( 0 )
{
@ -377,7 +375,7 @@ char *SuperNET_keysinit(struct supernet_info *myinfo,char *argjsonstr)
SuperNET_parsemyinfo(myinfo,msgjson);
free_json(msgjson);
}
else if ( EncryptWallet != 0 )
else
{
if ( bits256_nonz(myinfo->persistent_priv) == 0 )
{

3
iguana/iguana_rpc.c

@ -31,7 +31,8 @@ char *sglue(GLUEARGS,char *agent,char *method)
//printf("userpass.(%s)\n",userpass);
jaddstr(json,"agent",agent);
jaddstr(json,"method",method);
jaddstr(json,"coin",coin->symbol);
if ( coin != 0 )
jaddstr(json,"coin",coin->symbol);
if ( userpass != 0 )
jaddstr(json,"userpass",userpass);
if ( coin != 0 && coin->FULLNODE >= 0 && coin->chain->userpass[0] != 0 )

3
iguana/iguana_wallet.c

@ -15,7 +15,6 @@
#include "iguana777.h"
#include "exchanges/bitcoin.h"
extern int32_t EncryptWallet;
void scrubfree(char *sensitivestr)
{
@ -1393,7 +1392,6 @@ THREE_STRINGS(bitcoinrpc,encryptwallet,passphrase,password,permanentfile)
strcpy(myinfo->password,password);
if ( permanentfile != 0 )
strcpy(myinfo->permanentfile,permanentfile);
EncryptWallet = 1;
retstr = SuperNET_login(IGUANA_CALLARGS,myinfo->handle,myinfo->secret,myinfo->permanentfile,myinfo->password);
//myinfo->expiration = (uint32_t)time(NULL) + 3600*24;
struct iguana_waddress waddr; struct iguana_waccount *wacct;
@ -1436,7 +1434,6 @@ THREE_STRINGS(bitcoinrpc,encryptwallet,passphrase,password,permanentfile)
//iguana_walletinitcheck(myinfo,coin);
myinfo->dirty = (uint32_t)time(NULL);
myinfo->expiration = 0;
EncryptWallet = 0;
return(retstr);
}

3
iguana/main.c

@ -24,7 +24,6 @@
#include "../pnacl_main.h"
#include "iguana777.h"
int32_t EncryptWallet;
struct iguana_jsonitem { struct queueitem DL; struct supernet_info *myinfo; uint32_t fallback,expired,allocsize; char *retjsonstr; char remoteaddr[64]; uint16_t port; char jsonstr[]; };
@ -1587,7 +1586,7 @@ FOUR_STRINGS(SuperNET,login,handle,password,permanentfile,passphrase)
free(myinfo->decryptstr);
myinfo->decryptstr = 0;
}
if ( passphrase != 0 && passphrase[0] != 0 && EncryptWallet != 0 )
if ( passphrase != 0 && passphrase[0] != 0 )
{
SuperNET_setkeys(myinfo,passphrase,(int32_t)strlen(passphrase),1);
if ( myinfo->decryptstr != 0 && (argjson= cJSON_Parse(myinfo->decryptstr)) != 0 )

Loading…
Cancel
Save