print'(For broadcast message) Doing proof of work...'
#self.emit(SIGNAL("updateSentItemStatusByAckdata(PyQt_PyObject,PyQt_PyObject)"),ackdata,'Doing work necessary to send broadcast...')
shared.UISignalQueue.put(('updateSentItemStatusByAckdata',(ackdata,'Doing work necessary to send broadcast...')))
@ -2984,8 +2984,8 @@ class singleWorker(threading.Thread):
payload+=pubEncryptionKey[1:]
#If the receiver of our message is in our address book, subscriptions list, or whitelist then we will allow them to do the network-minimum proof of work. Let us check to see if the receiver is in any of those lists.
ifrequiredAverageProofOfWorkNonceTrialsPerByte< networkDefaultProofOfWorkNonceTrialsPerByte:#We still have to meet a minimum POW difficulty regardless of what they say is allowed in order to get our message to propagate through the network.
ifrequiredAverageProofOfWorkNonceTrialsPerByte<shared.networkDefaultProofOfWorkNonceTrialsPerByte:#We still have to meet a minimum POW difficulty regardless of what they say is allowed in order to get our message to propagate through the network.
print'(For msg message) Doing proof of work. Total required difficulty:',float(requiredAverageProofOfWorkNonceTrialsPerByte)/networkDefaultProofOfWorkNonceTrialsPerByte,'Required small message difficulty:',float(requiredPayloadLengthExtraBytes)/networkDefaultPayloadLengthExtraBytes
print'(For msg message) Doing proof of work. Total required difficulty:',float(requiredAverageProofOfWorkNonceTrialsPerByte)/shared.networkDefaultProofOfWorkNonceTrialsPerByte,'Required small message difficulty:',float(requiredPayloadLengthExtraBytes)/shared.networkDefaultPayloadLengthExtraBytes
shared.printLock.release()
powStartTime=time.time()
initialHash=hashlib.sha512(payload).digest()
@ -3105,7 +3105,7 @@ class singleWorker(threading.Thread):
#self.emit(SIGNAL("updateSentItemStatusByHash(PyQt_PyObject,PyQt_PyObject)"),ripe,'Doing work necessary to request public key.')
shared.UISignalQueue.put(('updateSentItemStatusByHash',(ripe,'Doing work necessary to request public key.')))
print'Doing proof-of-work necessary to send getpubkey message.'
@ -3697,13 +3697,9 @@ successfullyDecryptMessageTimings = [] #A list of the amounts of time it took to
apiAddressGeneratorReturnQueue=Queue.Queue()#The address generator thread uses this queue to get information back to the API thread.
alreadyAttemptedConnectionsListResetTime=int(time.time())#used to clear out the alreadyAttemptedConnectionsList periodically so that we will retry connecting to hosts to which we have already tried to connect.
#These constants are not at the top because if changed they will cause particularly unexpected behavior: You won't be able to either send or receive messages because the proof of work you do (or demand) won't match that done or demanded by others. Don't change them!
networkDefaultProofOfWorkNonceTrialsPerByte=320#The amount of work that should be performed (and demanded) per byte of the payload. Double this number to double the work.
networkDefaultPayloadLengthExtraBytes=14000#To make sending short messages a little more difficult, this value is added to the payload length for use in calculating the proof of work target.
@ -1764,7 +1764,7 @@ class settingsDialog(QtGui.QDialog):
self.ui.checkBoxStartOnLogon.setDisabled(True)
self.ui.checkBoxMinimizeToTray.setDisabled(True)
self.ui.checkBoxStartInTray.setDisabled(True)
self.ui.labelSettingsNote.setText('Options have been disabled because they either arn\'t applicable or because they haven\'t yet been implimented for your operating system.')
self.ui.labelSettingsNote.setText('Options have been disabled because they either aren\'t applicable or because they haven\'t yet been implimented for your operating system.')
appdata=''#holds the location of the application data storage directory
statusIconColor='red'
#If changed, these values will cause particularly unexpected behavior: You won't be able to either send or receive messages because the proof of work you do (or demand) won't match that done or demanded by others. Don't change them!
networkDefaultProofOfWorkNonceTrialsPerByte=320#The amount of work that should be performed (and demanded) per byte of the payload. Double this number to double the work.
networkDefaultPayloadLengthExtraBytes=14000#To make sending short messages a little more difficult, this value is added to the payload length for use in calculating the proof of work target.