* removed randomized block insert times for now

* listconn has a new alias
This commit is contained in:
Kevin Froman 2018-12-22 15:48:05 -06:00
parent 1dd471b91e
commit 8c79cd9583
2 changed files with 3 additions and 2 deletions

View File

@ -260,7 +260,7 @@ class Core:
return return
conn = sqlite3.connect(self.blockDB, timeout=10) conn = sqlite3.connect(self.blockDB, timeout=10)
c = conn.cursor() c = conn.cursor()
currentTime = self._utils.getEpoch() currentTime = self._utils.getEpoch() + self._crypto.secrets.randbelow(301)
if selfInsert or dataSaved: if selfInsert or dataSaved:
selfInsert = 1 selfInsert = 1
else: else:
@ -763,7 +763,7 @@ class Core:
metadata['meta'] = jsonMeta metadata['meta'] = jsonMeta
metadata['sig'] = signature metadata['sig'] = signature
metadata['signer'] = signer metadata['signer'] = signer
metadata['time'] = self._utils.getRoundedEpoch() + self._crypto.secrets.randbelow(301) metadata['time'] = self._utils.getRoundedEpoch()
# ensure expire is integer and of sane length # ensure expire is integer and of sane length
if type(expire) is not type(None): if type(expire) is not type(None):

View File

@ -181,6 +181,7 @@ class Onionr:
'getfile': self.getFile, 'getfile': self.getFile,
'listconn': self.listConn, 'listconn': self.listConn,
'list-conn': self.listConn,
'import-blocks': self.onionrUtils.importNewBlocks, 'import-blocks': self.onionrUtils.importNewBlocks,
'importblocks': self.onionrUtils.importNewBlocks, 'importblocks': self.onionrUtils.importNewBlocks,