Skip to content
HomeVideosBooksBlogs
AllTop postsTopics
Podcasts
HistoryListsWatch laterLiked videosFollowing

The videos, books, blogs and podcasts Hacker News keeps recommending, all in one place.

VideosBooksBlogsPodcastsAboutPrivacySettings

Data from Hacker News, HackerTube, HackerBooks, HackerBlogs and Open Library. Credits · Not affiliated with Y Combinator.

HomeVideosBooksBlogsPodcasts
Ctrl K

    Alex Gaynor

    alexgaynor.net · Personal blog · on HN since 2010

    Alex Gaynor, a security and Python engineer, writes about memory safety, C and C++ risks, and cryptography.

    Visit blogRSSHN submissions
    SecurityLanguages & CompilersProgramming
    What HN says

    HN cites him on why modern C++ does not prevent memory unsafety, with an uninitialized std::optional example, and recommends his intro to memory unsafety.

    Stats for nerds
    120HN people shared it
    126linked in comments
    3.7Kstory points
    Jun 2026last shared
    2012people per year2026

    Top posts on HN

    1. 1
      About Python 3
      1 person · 564 points · first shared 2013 · 345 comments on HN
    2. 2
      Modern C++ Won't Save Us
      12 people · 523 points · first shared 2019 · 388 comments on HN
    3. 3
      I Hope Twitter Goes Away
      3 people · 395 points · first shared 2014 · 238 comments on HN
    4. 4
      So you want to write a fast Python?
      2 people · 263 points · first shared 2011 · 67 comments on HN
    5. 5
      Why software ends up complex
      2 people · 188 points · first shared 2020 · 168 comments on HN
    6. 6
      PyPy is the Future of Python
      1 person · 172 points · first shared 2010 · 42 comments on HN
    7. 7
      Buffers on the Edge: Python and Rust
      3 people · 171 points · first shared 2022 · 51 comments on HN
    8. 8
      Django and Python 3
      2 people · 110 points · first shared 2011 · 17 comments on HN
    9. 9
      Notes on fuzzing ImageMagick and GraphicsMagick
      2 people · 100 points · first shared 2019 · 10 comments on HN
    10. 10
      My experience with the computer language shootout
      4 people · 95 points · first shared 2011 · 59 comments on HN

    What HN people wrote when they linked it

    • illumenMay 2014

      Currently python 3 packages ported are at about 10.9% according to pypi. This isn't including separate source downloads, so I guess the number would be higher by a few percentage points.

      There was a post by Alex Gaynor in January [0] about downloads for python 3 being at 2.4%. But that was before python 3.4 came out, and before some major libraries were finally ported like Twisted. Twisted not being ported was one of the main blockers for python 3 in the last Ubuntu release [1]. Once more distros improve their python 3 support, things will get exponentially better for python 3. Continuous integration servers inflate numbers because they re-download things, and there is the CDN which makes all these numbers highly inaccurate.

      Lots of things have been ported since January, like pycurl, pyOpenSSL, bugzilla [2], etc. Because of the big pushes by Debian, Ubuntu, Fedora, Mozilla, and Gnome [3] communities amongst many others. Things have improved greatly in a few months.

      Distros, and apps like Sublime Text 3 moving to python 3, along with some of the major missing pieces will help uptake significantly. Almost all packages in Fedora come with python 3 packages now. But the key to increasing python 3 adoption is Apple, and python 3 on OS X. Many of the python packages that come with OS X are now ported to python 3 (Twisted, cups, pyobjc, etc) ... but who knows what they have planned? I guess we'll see June-ish.

      [0]…

    • geofftJul 2021

      Agreed about the inability to write C, but the part about C++ is simply not true.

      I don't know about "better" in the general sense, but for the specific use case of the Linux kernel, Linus has identified some entirely reasonable objections (though aggressively worded) to C++: https://lkml.org/lkml/2004/1/20/20

      - the whole C++ exception handling thing is fundamentally broken. It's
      _especially_ broken for kernels.
      - any compiler or language that likes to hide things like memory
      allocations behind your back just isn't a good choice for a kernel.
      - you can write object-oriented code (useful for filesystems etc) in C,
      _without_ the crap that is C++.

      Those objections do not apply to Rust, which avoids exception handling, avoids implicit allocations, and has a much smaller OO system that resembles what the kernel does for filesystems. Those objections continue to apply to C++.

      There are good, principled reasons to accept Rust and continue to reject C++.

      (There are also good reasons to believe that C++ doesn't solve any of the problems with human inability to write correct C, meaning that it wouldn't be worth the cost of adding a new language: https://alexgaynor.net/2019/apr/21/modern-c++-wont-save-us/)

    • logicprogJan 2024

      Both. On the one hand, what Rust essentially forces you to do is just to program according to proper RAII principles that an experienced C++ programmer would already know and should already be using (especially once polonius lands), it's just better at checking failure to do so than any sanitizer or linter could ever be, so it's a way to avoid having to deal with annoying, hard to track down memory bugs. And in fact, the greater confidence static lifetime guarantees give you allows you to do things like using move semantics more where C++ programmers would have to use copies out of defensive programming. That's predominantly why I personally use it, as far as memory safety goes. On the other hand, [around 60-70% of serious security bugs have been proven to be caused by memory safety across many different projects](https://alexgaynor.net/2020/may/27/science-on-memory-unsafety-and-security/) so if you do care about security in what you're doing, it's a boon there too.

    • fijalOct 2012

      This is a full writeup: http://alexgaynor.net/2011/apr/03/my-experience-computer-language-shootout/

      You're correct, I got my facts wrong. We were allowed to use ctypes for gmpy, but not for something else. We weren't allowed to submit a ctypes-using and array-using benchmark that didn't work on CPython due to a CPython bug.

      the end result of us trying to be slightly better was that we ended up being kicked and a few other people ended up being kicked as well, though they weren't really guilty.

      Overall the experience was that the results are not "fair" and are guarded by arbitrary rules that are not really written anywhere. One of those rules is that an arbitrary (typically most popular, but not necesarilly so) implementation is only allowed. This makes it much less trustworthy that it can actually be.

    • ianm218Jun 2026

      Hmm my reasoning was that in order to have Nginx work in Rust you want to expose scripting so having a decent Lua in Rust is key to not call out to C for that. And then Valkey/ Redis is a lot simpler than nginx so it was a good way to learn how some of this works.

      And I'd disagree on no one wants - Lua is quite helpful since it is easily used in WASM. There has been some interest from people in the Bevy community - a game engine in Rust - since you can't have Lua scripting in browser games easily with the C version.

      But anyway if people want it or not memory safety might become much more important so I think it is a good area to explore. Some people think large C codebases are inherently unsecurable https://alexgaynor.net/2020/may/27/science-on-memory-unsafety-and-security/

    • akiarieApr 2024

      It's because we're dealing with an extreme example in which a program's safety depends on the resolution of an open problem.

      If the program's safety depends on the semantics of C and how they've been used in a function, it will be possible to deal with all the conditions upon which a program could be unsafe (in the sense of the standard safety vulnerabilities – like those listed here [0]). Doing so would lead to denouement, so that the annotation to the main function would be empty (meaning none of those bugs can occur).

      Programs that might be unsafe should not be verifiable.

      [0]: https://alexgaynor.net/2020/may/27/science-on-memory-unsafety-and-security/

    Related

    Ian Bickingblog.ianbicking.org107 people

    Firefox Was Always Enough

    Ian Bicking
    Personal · last shared 2026
    Brett Cannonsayspy.blogspot.com31 people

    A core Python committer's (very shallow) thoughts on Dart

    Brett Cannon
    Personal · last shared 2022
    Tom Forbestomforb.es18 people

    Infosys leaked FullAdminAccess AWS keys on PyPI for over a year

    Tom Forbes
    Personal · last shared 2025
    Andrew Godwinaeracode.org68 people

    Hello, This Is London Rising: 3D Printing Maps from LIDAR Data

    Andrew Godwin
    Personal · last shared 2025
    Scattered Thoughtsscattered-thoughts.net186 people

    Against SQL

    Scattered Thoughts
    Personal · last shared 2026
    Noncombatantnoncombatant.org42 people

    Downloading Software Safely Is Nearly Impossible

    Noncombatant
    Personal · last shared 2025
    Martin Aldersonmartinalderson.com38 people

    Are OpenAI and Anthropic losing money on inference?

    Martin Alderson
    Personal · last shared 2026
    Nibble Stewnibblestew.blogspot.com74 people

    Apple of 2019 is the Linux of 2000

    Nibble Stew
    Personal · last shared 2026