News for hackers. Stuff that matters.
Re:Unhosted - Freedom from web 2.0's monopoly platforms by EGreg on Sunday December 19, 2010 @04:02PM (#2022486)
"Letting the server supply you with arbitrary Javascript code to execute doesn't really get you away from trusting the server."

BINGO! That is the biggest problem with current web technology today. We need to have some kind of mechanism for delivering STATIC content, content that can be verified by independently downloading a hash from somewhere that you trust, and making sure the file is the same. This download has to happen through the browser itself, and not be initiated by javascript.

Re:Unhosted - Freedom from web 2.0's monopoly platforms by JoachimSchipper on Sunday December 19, 2010 @04:38PM (#2022579)
Do you have a proposal? Something like "code signing" for HTML/JS would be doable in theory, but where do you get the keys from? If you re-use the certificate authority infrastructure, you've only complicated things; a web-of-trust may work for some early adopters, but look at PGP's lack of mainstream success to see how that would work out...
Re:Unhosted - Freedom from web 2.0's monopoly platforms by EGreg on Sunday December 19, 2010 @04:53PM (#2022612)
Yes, I have a proposal.

Similar to how we have https:// blabla, and the user agent warns us if the server's certificate is not trusted, we should have httpc:// blabla to indicate constant files. Sites all over the world can download urls from httpc:// and store hashes to them in various formats, and your user agent can trust one or more of these authorities. When downloading, it would compare the hashes against the ones downloaded from these authorities, and if there is even a small deviation, it would give you a warning just like https://

I can see this being used in app stores for the web (curating apps and various versions of apps, like Apple does) and also for secure logins. I would like someone to make guarantees that my password is not being sent in the clear to the server that I am connected to. Currently with web tech it's impossible to be sure you aren't revealing sensitive info to the server. This simple change would make possible a variety of applications that we haven't even thought of, besides these two.

Re:Unhosted - Freedom from web 2.0's monopoly platforms by JoachimSchipper on Monday December 20, 2010 @02:27AM (#2023655)
I don't really see how httpc:// would make HTTPS logins work better. Can you explain?

Some sort of "distributed checksumming" like your first example may be useful for myapp-1.0.0.dmg or jquery-1.4.4.js, but how would you handle upgrades?

Re:Unhosted - Freedom from web 2.0's monopoly platforms by EGreg on Monday December 20, 2010 @09:12AM (#2024308)
distributed checksumming is what I am talking about

upgrades should be done by putting the new version at a DIFFERENT url. As tim berners-lee says, cool uris don't change: http://www.w3.org/Provider/Style/URI

Re:Unhosted - Freedom from web 2.0's monopoly platforms by JoachimSchipper on Monday December 20, 2010 @09:24AM (#2024345)
EGreg - if everyone will have to re-establish trust for each new release, what's the advantage?
Re:Unhosted - Freedom from web 2.0's monopoly platforms by EGreg on Tuesday December 21, 2010 @03:00AM (#2027283)
what is the advantage of magazines having to review every new version of software?

httpc:// would be used for logins and distributing software. People already publish checksums, this would just be an automatic way of verifying every file that the server claims is constant.

Re:Unhosted - Freedom from web 2.0's monopoly platforms by Raphael on Sunday December 19, 2010 @07:42PM (#2022955)
JSON is static content. Open an HTML page you trust and have that load the JSON data you want and use it to populate the DOM, making sure to escape HTML characters so it can't inject script tags and such.
Re:Unhosted - Freedom from web 2.0's monopoly platforms by EGreg on Sunday December 19, 2010 @10:20PM (#2023199)
The point is to be able to guarantee properties of a resource that is delivered to you via the internet. Whether it contains JSON or not, you are trusting the server. With current web technology you don't have an option.