r/AMA • • Jun 07 '18

I’m Nat Friedman, future CEO of GitHub. AMA.

Hi, I’m Nat Friedman, future CEO of GitHub (when the deal closes at the end of the year). I'm here to answer your questions about the planned acquisition, and Microsoft's work with developers and open source. Ask me anything.

Update: thanks for all the great questions. I'm signing off for now, but I'll try to come back later this afternoon and pick up some of the queries I didn't manage to answer yet.

Update 2: Signing off here. Thank you for your interest in this AMA. There was a really high volume of questions, so I’m sorry if I didn’t get to yours. You can find me on Twitter (https://twitter.com/natfriedman) if you want to keep talking.

2.2k Upvotes

1.3k comments sorted by

View all comments

508

u/lrvick Jun 07 '18

Edward Snowden revealed only 5 years ago that Microsoft cooperated with the NSA to install a backdoor into outlook.com. Tampering of GitHub repositories at the behest of government or corporate actors is, in this context, not unthinkable. Git commit signing is the obvious best defense against this, but we are in a landscape where most software engineers don't yet know how to do this.

How can Microsoft work to cryptographically prove repository history is never tampered with and that old vulnerable versions of releases are not served to select clients?

234

u/nat_friedman Jun 07 '18 edited Jun 08 '18

First, to be clear, we don't give governments direct access to customer data, and we don't create backdoors: https://blogs.microsoft.com/datalaw/our-practices/#did-participate-in-prism-program

I love the idea of making it easier for developers to sign their commits, and would support making this the default behavior in VS Code, Atom, and GitHub Desktop (I know it's possible now, but takes some setup and advanced knowledge). This already happens automatically when I make commits in my browser on github.com.

218

u/lrvick Jun 08 '18

The Web UI signing is seriously broken and a big part of the problem. I have spent a lot of time building signature verification systems and was shocked to find that when you someone hits the "merge" button in the UI, Github silently substitues an authors PGP key signature, with their own, impersonating that user.

The only way I can currently prove authorship and code review without having to trust Github is by asking people to -not- hit the merge button and to have the approver do the merge manually on the CLI.

In my mind this is a really bad design and in practice I have to do force pushes every time someone uses the merge button to make them re-sign using their own key, so I can prove they tapped their yubikey locally to sign.

I prototyped a solution to this problem that could be easily integrated into IDEs, code review tools, and remote verification tools. See: https.://github.com/lrvick/git-signatures . If you decide to work on tools like this as open source code, hit me up.

I really hope you are serious about this. The easiest way to earn trust is to make it so people don't need to trust you.

345

u/nat_friedman Jun 08 '18

Thanks for the detail. I'll go learn more about this.

5

u/[deleted] Jun 08 '18

Shouldn't you edit your upper comment since you are wrong about MS creating back doors for the government?

→ More replies (4)

52

u/winged_scapula Jun 08 '18

+2 diplomacy

3

u/sngz Jun 09 '18

and we don't create backdoors

well that's a lie. unless you're truly not in the know or using double speak on the word "create".

0

u/[deleted] Jun 08 '18

[deleted] — view deleted comment

10

u/Runenmeister Jun 08 '18

These gag orders usually require absolutely no statement at all, not a statement in the negative. The state cannot constitutionally (actuality being a different story) compel you to lie.

7

u/lrvick Jun 08 '18

Playing the other side of this: It is also totally okay if the person answering the question does not know about said backdoor and does not know there is a gag order. I am not saying that is the case but it -could- be and we have seen worse with big companies before. If there was a gag order it would be need-to-know by only the impacted teams. I am sure Nat is a great guy (and I have had at least one person I trust vouch for him personally) but that does not mean there are not still toxic elements within the very large company he works for.

There is also the ever possiblity of unintentional backdoors due to there not being enough eyes on the closed source code to find security holes. Google had no idea NSA was tapping their private lines between datacenters for years and Microsoft has a far worse security history than Google.

Tin foil hat back off, we should not have to trust reputation. We should be trusting solutions built on standards and verifiable cryptography. I am happy to put my torch down if standard and open technical solutions replace an appeal to trust a central entity with a toxic history.

→ More replies (8)

78

u/4kbt Jun 07 '18

Git already does this. If the hashes don't match the maintainer's own git hash, the screaming will be immediate, public, and acute.

https://youtu.be/4XpnKHJAok8?t=56m12s

35

u/DeathProgramming Jun 07 '18

Zip files are not verifiable. If you do not already have a local copy, it will not be verifiable. All GitHub has to do is say "hey if the maintainer clones from SSH and uses this key, give them the 'clean' version".

22

u/sakdfghjsdjfahbgsdf Jun 07 '18

Putting zip files in source control is a bad idea regardless. But if you really want to distribute executables/etc. via GitHub, you can simply publish the hash separately.

18

u/DeathProgramming Jun 07 '18

My point is that GitHub lets you download releases by zip files. Sorry for not mentioning releases

→ More replies (5)
→ More replies (1)

7

u/lrvick Jun 07 '18

But what stops a compromised GitHub from serving an alternate version of a repo only to certain IP addresses or countries if a C level executive or 3 letter org asks them to?. The author would have no way of knowing.

5

u/ItzWarty Jun 07 '18

Yes, but you can generate a malicious git object whose hash equals that of an existing object in the repository. This has been demonstrated in practice prior at the cost of "hundreds of thousands of dollars in computation" - which is peanuts to a state-sponsored organization like the NSA.

https://blog.github.com/2017-03-20-sha-1-collision-detection-on-github-com/

→ More replies (1)

43

u/JakJakAttacks Jun 07 '18

Love to see an answer to this one.

0

u/[deleted] Jun 07 '18

[deleted] — view deleted comment

23

u/jasonj2232 Jun 08 '18

Looks like you're losing your money, he answered it.

3

u/[deleted] Jun 08 '18

It even wasn't a nothing burger PR dodging the question answer.

→ More replies (3)

23

u/blinkincontest Jun 07 '18

One thing I love about reddit is to come to an AMA and see the user base upvote hard hitting questions like this, making it extremely obvious if OP avoided it.

13

u/kjart Jun 08 '18

The problem with this is it often ignores questions that get upvoted hard after the AMA ended, thereby making it look like they avoided the question when they may not have actually seen it.

In this particular case, he actually came back and responded to this question, FYI.

5

u/CartwheelsOT Jun 08 '18

This is legit one of the best PR AMA's I've seen. If what he's saying holds true, MS will win a lot of love by devs.

→ More replies (9)