now share own pubkey

This commit is contained in:
Kevin Froman 2018-04-03 14:39:58 -05:00
parent e061e516ee
commit 28fd4f4858
No known key found for this signature in database
GPG Key ID: 0D414D0FE405B63B
2 changed files with 7 additions and 4 deletions

View File

@ -352,15 +352,17 @@ class Core:
''' '''
conn = sqlite3.connect(self.peerDB) conn = sqlite3.connect(self.peerDB)
c = conn.cursor() c = conn.cursor()
payload = ""
if randomOrder: if randomOrder:
peers = c.execute('SELECT * FROM peers ORDER BY RANDOM();') payload = 'SELECT * FROM peers ORDER BY RANDOM();'
else: else:
peers = c.execute('SELECT * FROM peers;') payload = 'SELECT * FROM peers;'
peerList = [] peerList = []
for i in peers: for i in c.execute(payload):
print('lol - ' + i[2])
peerList.append(i[2]) peerList.append(i[2])
peerList.append(self._crypto.pubKey)
conn.close() conn.close()
return peerList return peerList
def getPeerInfo(self, peer, info): def getPeerInfo(self, peer, info):

View File

@ -39,6 +39,7 @@ class OnionrUtils:
def sendPM(self, user, message): def sendPM(self, user, message):
'''High level function to encrypt a message to a peer and insert it as a block''' '''High level function to encrypt a message to a peer and insert it as a block'''
return return
def incrementAddressSuccess(self, address): def incrementAddressSuccess(self, address):