@icedquinn Depends what you mean by "crypto code".. and what use the payload has in the overall system. But yea its something that needs be done all the time. I have had to implement canonical json in cryptocurrency code before, for example.
@icedquinn Yes except as I stated that does not solve the problem that canonical JSON solves.
If give the hash of some previously hashed payload, and the hash of some new payload, if the payloads arent canonical then you cant perform an equality check at all to verify if the payloads are equivelant. With canonical JSON you can.
@icedquinn Yes but your missing the point. you have no way of verifying the two blackboxes are equivelant with that process, it does nothing to address that problem. The same JSON, simply reordered randomly will produce completely different hashes and signatures with no way of knowing they are the same thing.
Thus it isnt solving the underlying problem that would be solved by requiring a specific bit representation, that is, the ability to check for equality.
@icedquinn How does that give you a hash that is directly comparable? You would still wind up with different byte arrays and thus different signatures that are not directly comparable.
@icedquinn I agree thats a shitty spec... IT does expose a very real problem with JSON though, that two equivelant pieces of JSON can hash to very different values.
It is the reason I have often in my projects (where hashed values representing unique JSON is needed) used canonical JSON, which is a standard that fixes that issue. Sadly it isnt well adopted so it generally needs to be used as an internal standard.
@lucifargundam I'm on board!
@thedonnerd enjoy :)
That time the USA accused russia of chemical warfare but it turned out just to be Bee shit...
@1iceloops123 I ate a gigantic chinese meal loaded with carbs... so pretty much the same thing.
@1iceloops123 you and me both.
@Madmonkey Obviously based on your comment.
Old iPhones become faster if you change the region to France
https://www.gizchina.com/2021/08/23/old-iphones-become-faster-if-you-change-the-region-to-france/
@trinsec That one is more common, but i find less interesting.
@Madmonkey
I dont recall ever claiming someone said that. Whats your point?
@bluejay Your axiom is incorrect, therefore your conclusion is also incorrect.
New varients become selected for when vaccines are in wide use in the population. Without vaccines the variants are out competed by the main branch (usually). Any variants that do arise in unpopulated populations must be selected for against the main branch whereas in a vaccinated population this need not be the case, allowing a larger range of variants to be selected for and ultimately arise.
Jeffrey Phillips Freeman
Innovator & Entrepreneur in Machine Learning, Evolutionary Computing & Big Data. Avid SCUBA diver, Open-source developer, HAM radio operator, astrophotographer, and anything nerdy.
Born and raised in Philadelphia, PA, USA, currently living in Utrecht, Netherlands, USA, and Thailand. Was also living in Israel, but left.
Pronouns: Sir / Mister
(Above pronouns are not intended to mock, i will respect any persons pronouns and only wish pronouns to show respect be used with me as well. These are called neopronouns, see an example of the word "frog" used as a neopronoun here: http://tinyurl.com/44hhej89 )
A proud member of the Penobscot Native American tribe, as well as a Mayflower passenger descendant. I sometimes post about my genealogical history.
My stance on various issues:
Education: Free to PhD, tax paid
Abortion: Protected, tax paid, limited time-frame
Welfare: Yes, no one should starve
UBI: No, use welfare
Racism: is real
Guns: Shall not be infringed
LGBT+/minorities: Support
Pronouns: Will respect
Trump: Moron, evil
Biden: Senile, racist
Police: ACAB
Drugs: Fully legal, no prescriptions needed
GPG/PGP Fingerprint: 8B23 64CD 2403 6DCB 7531 01D0 052D DA8E 0506 CBCE