News for hackers. Stuff that matters.
Re:Project Oak by Google by xyst on Wednesday August 14, 2024 @01:18PM (#41248354)
A bit surprised that it’s written in rust, rather than Go. I suppose rust can take advantage of more low level apis, plus no overhead of garbage collection.

edit: love that the community is not silo’d into a proprietary chat platform as well:

> We welcome contributors! To join our community, we recommend joining the mailing list.

- https://github.com/project-oak/oak?tab=readme-ov-file#gettin...

I really wish more open source projects used mailing lists.

1) decentralized means of communication

2) able to join these communities from any type of environment (ie, corporate hell hole) without much friction. With discord, slack (especially at fortune 500s). It usually involved a whole process of approvals to get the damn thing installed and punch a hole through the firewall to get access to the service.

No, using a personal email and device for what I consider contributing from a work aspect (ie, submitting patch to OSS to solve specific problem with project) is not acceptable.

Re:Project Oak by Google by jb1991 on Wednesday August 14, 2024 @01:29PM (#41248456)
> A bit surprised that it’s written in rust, rather than Go. I suppose rust can take advantage of more low level apis, plus no overhead of garbage collection.

It’s security-focused technology. Rust has huge advantages over Go in this area.

Re:Project Oak by Google by filleokus on Wednesday August 14, 2024 @01:36PM (#41248541)
> Rust has huge advantages over Go in this area.

Could you name some advantages? I would agree Rust has huge advantages compared to C/C++, and Rust also has a much bigger presence in the "security space". But I would say that's more because of Rust's lack of GC, smaller footprint which works in embedded systems etc.

I guess you could say that Rust's type system being more expressive might eliminate certain classes of bugs, which have security implications. But "huge advantages"?

(Honestly I'm not flame baiting, I'm genuinely curious if my worldview is wrong)

Re:Project Oak by Google by Ygg2 on Wednesday August 14, 2024 @07:27PM (#41251689)
> But "huge advantages"?

They don't call null/nil the billion dollar mistake for nothing.

Re:Project Oak by Google by Myrmornis on Thursday August 15, 2024 @09:18AM (#41255689)
I think lack of union/sum types, i.e. lack of compiler exhaustivity checks on cases is pretty relevant here. For security applications the goal is maximum stringency w.r.t. correctness so I think “huge advantage “ isn’t an exaggeration regarding sum types. It’s not like “have you checked all cases” is an unimportant question when trying to prove correctness.
Re:Project Oak by Google by dijit on Wednesday August 14, 2024 @01:38PM (#41248562)
does it really? aside from a handful of crates and the default std hashmap i being slow but cryptographically sound: I would not have assumed so.

Go usage inside Google is actually quite low, people talk a lot about Go being a google project but in reality its a project made by some people who work at Google.

When I last checked it was a bronze supported language (with C++, Python and Java being Gold).

Re:Project Oak by Google by ycombinatrix on Wednesday August 14, 2024 @03:19PM (#41249564)
Python has first class support at Google? Didn't they just fire their entire Python team?
Re:Project Oak by Google by sulam on Thursday August 15, 2024 @10:11AM (#41256304)
Roughly, yes, but they didn’t stop doing the work. It was moved to another set of people.
Re:Project Oak by Google by deskr on Wednesday August 14, 2024 @02:12PM (#41248929)
What advantages are those?
Re:Project Oak by Google by morning-coffee on Wednesday August 14, 2024 @02:43PM (#41249224)
Rust's compiler can prevent data races, for example. (It forbids mutation in the presence of aliasing, which is the root of it.)
Re:Project Oak by Google by dijit on Wednesday August 14, 2024 @03:00PM (#41249383)
should be mentioned that Go has optional flags already built in to the compiler for detection of data races.
Re:Project Oak by Google by jb1991 on Wednesday August 14, 2024 @03:34PM (#41249683)
the race detector ( -race ) only detects races that actually occur. If they don't happen, then it doesn't detect them.
Re:Project Oak by Google by ycombinatrix on Wednesday August 14, 2024 @03:20PM (#41249573)
should we also mention that C has optional tooling for memory safety?
Re:Project Oak by Google by summerlight on Wednesday August 14, 2024 @02:18PM (#41248972)
I think using Go is not a popular decision in the Android ecosystem, especially for those system programming stuffs. It's very likely that the project needs tight client side integration, so they probably wanted to use a language which has a wider support especially in the case of possible iOS support.
Re:Project Oak by Google by topspin on Wednesday August 14, 2024 @05:11PM (#41250546)
The hardware features used for this are Intel and AMD CPU extensions: they're writing a microvm to run inside special "enclave" virtual machines. Go is a fine language but it's not really intended for this sort of work. Rust is a natural fit for this work: you can write low level drivers and also ensure a number of safety properties.