There is technically a way to already check the version of a peer. Every component of Timekoin already broadcast its version number and name in the headers; if you have the web server logging your HTTP traffic, you can see the version in the headers.
Example, this is from my dev machine web logs.
Code: Select all
18.104.22.168 - - [01/Feb/2016:04:02:03 -0600] "GET /timekoin/transclerk.php?action=history_hash HTTP/1.0" 200 32 "-" "Timekoin Server (Transclerk) v3.61"
22.214.171.124 - - [01/Feb/2016:04:02:03 -0600] "GET /timekoin/queueclerk.php?action=transaction&number=5efd0fabcef635451a5c2203e5bc7d78 HTTP/1.0" 200 1475 "-" "Timekoin Server (Queueclerk) v3.61"
126.96.36.199 - - [01/Feb/2016:04:02:03 -0600] "GET /timekoin/queueclerk.php?action=transaction&number=1c58b03d38e6321814f38cb6fd532bfd HTTP/1.0" 200 1475 "-" "Timekoin Server (Queueclerk) v3.61"
188.8.131.52 - - [01/Feb/2016:04:02:03 -0600] "GET /timekoin/peerlist.php?action=join HTTP/1.0" 200 2 "-" "Timekoin Server (Peerlist) v3.61"
Now, having peers poll each other for version and display it in the peer list for example would not take much coding. But you do come back to the issue, if everyone is running v4.0 for example and some security fix means all other peers are incompatible, what would you do with peers that are coded to lie about the version? Like, someone just modifies their v3.61 to say v4.0. I know that is a silly example, but if we start doing a version lock, we have to think about all possible ways to abuse it as well.
Your point about how it can be abused is a very good one. We definitely don't want it to be easily tampered with when a server node broadcasts that they are version 3.5 for example. This information should not be modifiable, and should be tamper proof, IMHO.
Can the transaction encryption protocols be applied to the broadcast of the server version? Encrypt it with the 1536 RSA thingie, then use the SHA 256 to hash that encryption to make sure this server info is not tampered with? I think moving forward, knowing the state of the network accurately
will be very critical to a constantly evolving network like Timekoin. I know that if this approach is taken, it might mean that there will be more space being taken up on the database. Perhaps make it such that this broadcast is only done once every 24 hours to reduce the database size strain on the network?
I know this would be crazy because it also means that when we click on the Peerlist tab, we would need to de-crypt all the provided server version numbers, and to do it constantly depending on how often the peer list tab refreshes. It is not an elegant solution, but it is one that came to mind.
After all, we have modern CPUs that can encrypt-decrypt with relative ease. I feel that we should use this feature as necessary beyond just securing transactions to make TK more secure, and ultimately more compelling as a cryptocurrency, as a whole.