You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I add a new api /newAddress to the Controller.java, and this API makes use of WalletUtils.generateFullNewWalletFile(), then I realize that my RESTful server have to access the keystore directory, which means my RESTful server has to run on the full node, am I correct?
@RequestMapping(value = "/newAddress")
StringnewAccount() throwsException {
// wallet file is named like `UTC--2018-03-16T05-09-05.79000000Z--3ae52004fd3e16c3b70b92ca0a9b382c786bf27e.json`StringwalletFileName = WalletUtils.generateFullNewWalletFile(getEncryptPassphrase(),
newFile(getKeystoreDir()));
// in which `3ae52004fd3e16c3b70b92ca0a9b382c786bf27e` is addressString[] fetchAddress = walletFileName.split("--");
Stringaddress = "0x" + fetchAddress[fetchAddress.length-1].split("\\.")[0];
returnaddress;
}
The text was updated successfully, but these errors were encountered:
If I add a new api
/newAddress
to theController.java
, and this API makes use ofWalletUtils.generateFullNewWalletFile()
, then I realize that my RESTful server have to access the keystore directory, which means my RESTful server has to run on the full node, am I correct?The text was updated successfully, but these errors were encountered: