GnuPG Security Advisory for GPGME

(lists.gnupg.org)

264 points | by gdgghhhhh 1 day ago

15 comments

  • uptrails 1 day ago
    Reportedly fixed by Red Hat 5 years ago based on the output from conventional tools, but missed by upstream: https://gitlab.com/redhat/centos-stream/rpms/gpgme/-/blob/c9...
    • gdgghhhhh 1 day ago
    • sandos 1 day ago
      How is this even possible?

      "when it was noticed by a Coverity scan:"

      It was found by static analysis FIVE years ago, but never re-found? That is really odd. I thought people were running every kind of commercial scanning tool on OSS for free most of the time.

      • hannob 1 day ago
        Who are those people you thought would do that?

        Sure, you can get coverity scans for free for open source tools. Most open source maintainers I know aren't eager to hear ideas how they can have more work maintaining their software.

        • nine_k 22 hours ago
          Large orgs that depend on GPG, like Debian and Ubuntu, might have the cycles to spend on fixing an issue like this.
          • xorcist 11 hours ago
            They depend on GPG but GPGME is something else. The latter is a wrapper around GPG mostly intended for email software.

            Is is not even close to being as widely used as GPG itself, packaged and distributed as a separate piece of software, so it's fully understandable if big Linux distributions such as the ones you mention don't as much time on it they they would on, say, GPG itself.

          • capitol_ 14 hours ago
            Moving to sequoia is the sensible thing to do imho.
      • ChuckSneed 21 hours ago
        Frankly, this could have been a problem with Coverity itself (particularly the UX). As someone who has used Coverity in professional setting, keeping tab of issues was hard. Or maybe it was our coverity deployment that sucked.
      • pseudohadamard 20 hours ago
        As a contributor to an OSS project that uses Coverity, yes, we do. The problem is that for a lot of these projects the first time you run any SAST on it you get about 5,000 results. A common approach for commercial users for dealing with this is that you fix all the critical ones and then mark the rest as the baseline and only fix new stuff beyond that point, because you don't have the budget or time to fix all 5,000 issues. For OSS I don't know the approach there, although in our case with security-focused devs with OCD we fixed everything before continuing.
        • collinfunk 18 hours ago
          Likewise, a maintainer of a project that uses Coverity. It is very useful, and I am thankful to them for generously making it available to us for free. But I agree it is a bit noisy with results. E.g., many of the reports will mark code as "dead" when it is used on other platforms.
    • c-hendricks 1 day ago
      Hurray for endless distro forks
      • christophilus 1 day ago
        Rh is kind of the canonical distro, though, as much as there is such a thing. I’m surprised this was never upstreamed.
        • gpvos 1 day ago
          Used to be long ago. Maybe still is somewhat for business use. Debian or Ubuntu has been the most standard distro for many years now.
          • cozzyd 1 day ago
            Depends on your circles...
        • BadBadJellyBean 1 day ago
          RH has a lot of sway but calling it canonical would be a step too far in my opinion.
        • asveikau 1 day ago
          Red hat was the standard suggestion when I started using Linux in 1998. I personally switched to Debian in '99 and it's still my go-to when I'm not using a *BSD.

          When Ubuntu came on the scene it quickly became a dominant choice for normies and non-tinkerers, and I feel like this sort of lifted prominence for debian too.

        • bonzini 12 hours ago
          Yeah it's weird since the fix also didn't make it into either Fedora or RHEL 10.
        • cowlevel 1 day ago
          Debian is the canonical distro.

          Ubuntu is the Canonical distro, but that's unrelated.

          • creatonez 1 day ago
            Debian is vastly further from upstream than Red Hat.
            • cowlevel 9 hours ago
              irrelevant if true
            • LtWorf 21 hours ago
              Do you have stats on the amount and size of patches?
        • throooooo 1 day ago
          No Canonical makes Ubuntu. Jokes aside, Ubuntu and Debian are the most used distros by far.
          • eddythompson80 1 day ago
            In my personal experience, I think both of you are right in different bubbles (for lack of a better word). If you worked in commercial unix-like tech systems since the early 2000s (meaning your company/business was tech focused), you would consider RH to be the canonical distro. There is a reason all the newer distros marketed towards commercial use (Alma, Rocky, Cent, Core, Amazon, Azure) are all Fedora/RH derivatives.

            If you have been mainly OSS or used unix-system in a non-tech business, then you would consider Debian/Ubuntu to be the more canonical distros.

            • cozzyd 1 day ago
              In HEP and academic cluster environments EL is standard. I only use Debian on embedded Linux.
          • nullpoint420 1 day ago
            It's unfortunate because they're definitely not the best, even at the reasons Ubuntu is often cited for being "better."

            IMO, RH is just better at security, integration, and much much more.

            • johnsonjo 1 day ago
              Yeah I use Ubuntu and Fedora and the only thing I don't like about my Fedora desktop is that more desktop software is only available for Ubuntu/Debian rather than Fedora. Probably only simply because Ubuntu is more popular. (I have used alien in the past to some success in this regard to get software running on Fedora that was only built for Ubuntu.)

              More on alien:

              > alien is a program that converts between Red Hat rpm, Debian deb, Stampede slp, Slackware tgz, and Solaris pkg file formats. If you want to use a package from another linux distribution than the one you have installed on your system, you can use alien to convert it to your preferred package format and install it. It also supports LSB packages. [1]

              [1]: (https://manpages.ubuntu.com/manpages/bionic/man1/alien.1p.ht...)

        • noncoml 1 day ago
          [dead]
  • miduil 1 day ago

           This vulnerability was discovered by Johan Carlsson and we were informed by GitLab on 2026-11-12.
           Initially we set 2026-11-25 for a coordinated disclosure;
           due to the new Ruby2Shell bug GitLab had to update earlier
           and thus we also disclosed the GPGME bug on 2026-11-20.
    
    I guess pretty important for GitLab since it supports signed commits, code execution in that path is pretty bad.

    You can find the GitLab Omnibus related patch here: https://gitlab.com/gitlab-org/omnibus-gitlab/-/commit/279ac3...

  • mik1998 1 day ago
    It's a double free bug, not an RCE chain. Are these vulnerability reports intentionally overstated?
    • InsidiousWombat 1 day ago
      Yes, the actual post just implies possibility

      > Exploiting this bug to mount an Remote Code Execution attack (RCE) can't be ruled out.

    • cowlevel 1 day ago
      AI is doing quite well at automating the escalation of small memory bugs (which can usually theoretically cause RCEs) into actual RCE exploits. This bug has a similar nature to php2shell.
      • antonymoose 23 hours ago
        I was too busy putting out the node2shell and others to look at the PHP vulnerability - was that one an easy “get shell” exploit or mostly theoretical one like the Node exploit where an attacker has to know the exact memory layout to else cause a crash…
        • cowlevel 9 hours ago
          Theoretical. It was a use after free. Stealing bitcoin from a live web server took AI two hours.
      • testtestmetest 23 hours ago
        [dead]
    • mhluongo 1 day ago
      Today's LLMs can often escalate to RCE, so it makes sense to assume the worst.
      • xorcist 11 hours ago
        It must mean something to "assume the worst". If you always assume the worst, you also never do it.

        If an RCE exploit can't be ruled out, that's bad, but would be clearly worse in every way if an RCE exploit was public.

        An LLM can aid in designing an actual exploit, but if it's not possible then it's simply not possible. Oftentimes we are lucky and exploits turn out to be impractical or require configurations never found in the wild.

      • slim 1 day ago
        it does not make sense to say RCE for something that does not have an open port on the system
        • rubendev 1 day ago
          If someone opens an encrypted email that came from an attacker using GnuPG and code is executed on his machine as a result, that is still remote code execution.
          • dwattttt 1 day ago
            What is not "remote" code execution under this definition?
            • catlifeonmars 1 day ago
              Have you ever heard of IP over Avian Carrier? It might help expand your definition of “remote”.

              In all seriousness, “remote” in this case means attacker controlled.

              • dwattttt 1 day ago
                Are you suggesting the existence of exploits outside of the definition of "attacker controlled"?

                If not, and all exploits are attacker controlled, it sounds like all exploits are RCE.

                EDIT I guess I have to weaken the last condition since we haven't proved all exploits are "code execution", but we have at least proved all exploits are "remote".

                • fc417fc802 1 day ago
                  The implication you're missing is remote execution of [ arbitrary and attacker provided ] code. An example of an exploit that doesn't qualify as RCE is a web server providing read only access to files it should not.

                  For example, if an attacker can remotely trigger only a specific preexisting program (perhaps sudo rm -rf /) and if the attacker is unable to directly escalate from that to full blown arbitrary code execution then that vulnerability would also not qualify as RCE.

                  In the gnupg case, if an email can contain arbitrary code that gets executed on the target system then you have RCE.

                  • dwattttt 1 day ago
                    And if I leave a USB with a malicious executable in a parking lot, and someone runs it, it sounds like I'll have a remote code execution vulnerability too. Sounds like a very low bar, I guess RCE must be a basic, "everything gets this marker" thing.
                    • fc417fc802 1 day ago
                      Well, yes? That is a long established and very well known social engineering attack that indeed results in RCE pretty much by definition unless various technical countermeasures have been put in place by IT. This is precisely why USB (and most other) ports are physically removed in sensitive environments and why any competent operation will usually have a cryptographically based whitelisting approach when it comes to executing binaries and scripts.

                      The bar is simply "an attacker is able to cause the execution of arbitrary code without being physically present". I'm not clear what it is that you find so bothersome about this exceptionally straightforward criteria.

                      • dwattttt 1 day ago
                        You're calling "trick someone into running an executable" an RCE? I can work with this definition, but like I said, it makes this a very low bar, very valueless definition. Everything is RCE. Which is why it's hard to answer my question "what _isn't_ RCE".
                        • fc417fc802 1 day ago
                          If your threat model includes an employee being tricked into running an arbitrary executable then yes that's RCE. If that's not part of your threat model then it doesn't constitute an RCE vector for you.

                          How common or uncommon a particular class of exploit is has absolutely no bearing on such criteria - these things are entirely functional in nature. The value of such definitions is in clearly delineating different concepts relevant to threat modeling. When an attacker has pwned you and is executing arbitrary code on your system are you going to object that "well ahckchually what you did doesn't qualify by my personal definition because ..."? Or perhaps you'll belittle them for using what you see as a pedestrian attack vector?

                          > Everything is RCE. Which is why it's hard to answer my question "what _isn't_ RCE".

                          You're intentionally being obtuse. I already provided examples. An SQL injection for example does not (at least typically) lead to RCE.

                          • dwattttt 23 hours ago
                            > You're intentionally being obtuse. I already provided examples. An SQL injection for example does not (at least typically) lead to RCE.

                            You've described something that's not "code execution", and I've agreed several times. I'm making fun of the fact that a "local privilege escalation" is turned into a "remote" attack if it's emailed and run/executed/parsed, much like an email signature.

                    • MajesticHobo2 1 day ago
                      The problem with that analogy is that it's not a vulnerability, that's how running executables from a USB stick works. No one expects importing a GPG public key to execute untrusted code.
            • andai 8 hours ago
              Stuxnet exploded the turbines over an air gap.

              If RCE excludes Stuxnet, then maybe we should come up with a phrase that's less wrong.

        • MajesticHobo2 1 day ago
          You wouldn't label popping a shell in Chrome, via a malicious web page, as RCE?
          • SAI_Peregrinus 19 hours ago
            I'd label it as Arbitrary Code Execution, since it requires the target to initiate the interaction. RCEs are ACE vulns where the target responds to an attacker-initiated interaction.
      • kelnos 1 day ago
        No it doesn't. The announcement email is reasonable in that it says a RCE "can't be ruled out", but whoever editorialized the submission title here to "RCE in Gnupg" was clearly going for clickbait.
      • gertop 1 day ago
        It makes sense to assume the worst, then try to achieve it. And only if you achieve it so you tag it as such. You can't announce vulnerabilities to the world based on vibes of what it might do....

        "Yeah this is a classic double free. We can't think of a way to transform it into a RCE or something like that, we've also failed at having LLMs do it so far. but in the current climate it could happen so we humbly ask the tag of most dangerous vulnerability please. Not just this disclaimer. We want 9.9 CVE that says RCE!!"

        This is ridiculous.

    • gdgghhhhh 1 day ago
      Sending somebody a signed message and trigger a double free is a prime example for RCE
      • kuroguro 1 day ago
        RCE might be possible, you still need to overlay something useful in the freed memory and bypass ASLR.
        • Deeg9rie9usi 1 day ago
          The mail says "Exploiting this bug to mount an Remote Code Execution attack (RCE) can't be ruled out.". They didn't write this just for fun. gnupg usually downplays security issues.
          • kuroguro 1 day ago
            I'd say that is as accurate as they can be. Since it's a library and it's a heap bug they have no idea how a particular application will be affected.

            It's still a critical bug, just would not call it a prime example of rce.

          • wavemode 1 day ago
            I mean, the blame is moreso on the title of this HackerNews submission. "RCE can't be ruled out" is not equivalent to "RCE in Gnupg"
          • Sopel 1 day ago
            it can't be ruled out that an RCE exists in other parts of this software either
        • dboreham 1 day ago
          "overlay something useful in the freed memory and bypass ASLR"

          I thought we reached the point a few years ago where the assumed probability this can be done is 100% ?

      • upofadown 11 hours ago
        The attacker would of had to have successfully managed to get the victim to import a malicious key with a super long userID before that. The signed message would just be the trigger.

        The trigger, whatever it was, would have to not just cause the super long userID to be displayed, but would somehow have to affect the target's display code in a meaningful way to do some sort of exploit.

      • gsich 1 day ago
        poc needed.
        • Deeg9rie9usi 1 day ago
          IMHO, these days any kind of UB has to be considered exploitable by an LLM. The times of debating whether something is exploitable or not are over.
          • bigstrat2003 1 day ago
            No, they are not. RCE has a very specific meaning, and watering it down by applying the label to something without an exploit is lying.
          • Deeg9rie9usi 1 day ago
            It's interesting to see how polarizing this comment is, it's being upvoted and downvoted in waves.
          • gsich 1 day ago
            We are having this debate right now. So it's far from over. Without PoC it's unclear if it's RCE or just overhyped bullshit. See PHP or Nginx "RCE" which required specific crafted settings for it to even work. A video is not a "PoC".

            If you believe an LLM can generate an exploit for this - feel free to post one.

            • o_-_o 1 day ago
              I agree PoC's should be a requirement for all this exploits.
              • InsidiousWombat 1 day ago
                at the very least should be criteria for assigning "high", CVE spam is annoying enough as it is
            • pixl97 1 day ago
              Na, for years I've been seeing crap like this "well there is no exploit" and then a year later one is found.

              Quit writing memory free errors in software. Prove your software is safe, not prove that it's not exploitable.

              • gsich 1 day ago
                A year later you hopefully have updated the software, no loss there.
                • pixl97 1 day ago
                  It's more of a "made public" a year later, you have no idea if anyone exploited it in between.

                  At first I thought the whole Linux everything is a CVE was kind of annoying, but over time, especially with automated exploit finding it really has shown to be in front of what was about to happen.

                  • gsich 22 hours ago
                    >At first I thought the whole Linux everything is a CVE was kind of annoying, but over time, especially with automated exploit finding it really has shown to be in front of what was about to happen.

                    I support that, not the CVE part, because that one is annoying paperwork, but the "every bug is a security bug". What I don't support is overhyped panic spreading because something might have an RCE, without proof.

          • userbinator 18 hours ago
            has to be considered exploitable by an LLM

            Then someone should do the needful and ask one to generate an exploit.

            Otherwise it's just a bunch of hot air to stir up paranoia.

            "Put your money where your mouth is", as the saying goes.

    • MajesticHobo2 1 day ago
      It's long-standing practice to assume a worst case of RCE for certain memory corruption classes.
  • wannabe44 1 day ago

        All software using a GPGME version prior to 2.3.0 either as shared
    libary, DLL, or statically linked is affected. Examples of software using GPGME are

       - Gpg4win
       - GnuPG Desktop
       - GnuPG VS-Desktop
       - Most mail clients
       - Many XMPP clients
       - Samba
       - Flatpack
    
    I assume this is in "gpgme" and doesn't affect apt etc? Can someone confirm?
    • usr1106 3 hours ago
      GPGME seems to stand for "GPG made easy" (whatever that might mean).

      I have 2 library packages with such name installed on my Ubuntu laptop. They have been pulled in by podman and by libreoffice.

      This doesn't seem to be the standard package signing mechanism used by many Linux distros. So yes, many people might have it (if the libreoffice path is affected). But standard package installation should not be.

      (Just from my quick analysis. Not an expert in the area and did not dig deeper.)

  • usr1106 1 day ago
    What are practical attack vectors for Linux workstations and servers?

    The masses of internet users don't know what GPG is. I'd caim the majority of software developers don't have a GPG key and never explicitly verify any signature.

    But packages of many distros are verified using GPG. Is the vulnerable component involved or not?

    • kodoman 1 day ago
      > But packages of many distros are verified using GPG. Is the vulnerable component involved or not?

      Debian uses it last time I was on a Debian system And I think all Debian based distros that don't modify apt will essentially use GPG to verify the packages as well.

      I think it's one of the those programs that pop up in a lot of different things. Personally I use it a fair amount and even use the Symmetric encryption features for some files and for personal password management.

      I do think developer are moving away from it thought I agree (and for various reasons that are good).

    • lazka 1 day ago
      Arch Linux uses gpgme to verify downloaded packages (and optionally, package databases) for example.
      • o_-_o 11 hours ago
        Package Updated:

        - Build Date: 2026-11-21 13:29 UTC

        - Signature Date: 2026-11-21 13:31 UTC

        - Last Updated: 2026-11-22 09:13 UTC

    • firesteelrain 1 day ago
      It’s used a lot in commercial for code signing. We use it with Thales HSMs (there are other things in the middle)
      • usr1106 1 day ago
        Are you sure? (I am not) The announcement says gpgme. Is that the same thing used for basic signatures?
    • OJFord 1 day ago
      Potentially package update/installation? A lot of people use gpg without knowing it.

      It's specifically in 'GPGME' though, so more limited scope I think.

      • capitol_ 1 day ago
        A lot of those places have switched out the gnupg PGP implementation with sequoia-openpgp.
      • usr1106 1 day ago
        That was my question. Where is gpgme used? Any "unexpected" places?
        • OJFord 22 hours ago
          I have it installed as a dependency for pacman, podman, and yubikey-touch-detector, among others.

          Without digging into exactly how pacman uses it, I'm wondering if the cautious move is not to update anything before first updating it...

    • gdgghhhhh 1 day ago
      PGP mail?
      • Geezus_42 1 day ago
        Which almost no one uses.
        • gdgghhhhh 1 day ago
          Wrong bubble ;-)
          • Geezus_42 1 day ago
            If only people in a certain bubble use it, then almost no one actually uses it.
            • kodoman 1 day ago
              > no one actually uses it.

              A lot of people use it especially certain high value targets on darknet drug markets who might miss this.

              A lot of projects do still use it for signing projects though many have opted for simpler solutions (or unfortunately no signing).

              I think Debian still uses it (not sure about ubuntu) in apt.

              • Geezus_42 1 day ago
                Darknet drug dealers are still an extreme minority of people. You still have not negated my statement.

                Sure, GPG gets used for signing packages and that COULD potentially lead to a supply chain attack IF this is not quickly patched.

  • dehrmann 1 day ago
    It's becoming clear that humans have no business writing C/C++ without Rust-level tooling around it to prevent these things.
    • sitzkrieg 1 day ago
      SPARK Ada has proven this is solvable for decades. rust brings nothing new to the table.
      • the_why_of_y 8 hours ago
        SPARK Ada does exist since the late 1980s (although not open source for a long time) and does solve a lot of security problems that plague C/C++.

        But for use-after-free, from the beginning, the solution was not to have pointers in the language at all; Ada does have pointers and Ada.Unchecked_Deallocation.

        Obviously dynamic memory allocating does have useful applications, so after Rust 1.0 was released, SPARK Ada added pointers and an explicitly Rust-inspired ownership model.

        "Verification of Programs with Pointers in SPARK", 2020 https://dl.acm.org/doi/10.1007/978-3-030-63406-3_4

        "Proving heap-manipulating programs with SPARK", 2021 https://av.tib.eu/media/53376

        https://alb-lang.org/wiki/SPARK_Ada

        • sitzkrieg 5 hours ago
          the pointer and heap manipulating points are very fair points indeed. i just hate when people act like rust is a totally new concept. (heck not to mention stuff like eiffel!)
      • heavensteeth 13 hours ago
        I doubt I've executed a single Ada program in my life. I see Rust every day.

        Clearly it's bringing something to the table, even if not technical.

        • sitzkrieg 11 hours ago
          shrug, depends on which industry exposure you have. but ill concede w the recent mandates and climate they're moving to rust from ada/spark and c/c++. one could argue if nothing more than the improved popularity and tooling (except compile times god damn)
      • irundebian 9 hours ago
        I think it did. Borrow checking and ownership. The last influenced access types in SPARK. Besides that, Rust probably is better suited for application with threads and dynamic memory allocation.
  • Velocifyer 1 day ago
    This is a reminder that Seqouia-PGP exists, and its 'sq' CLI is way more intuitive.
    • chlorion 20 hours ago
      Not sure why this is downvoted. Sequoia is very nice, and can even emulate gpg with its chameleon mode from what I understand.
      • upofadown 9 hours ago
        It's not really helpful to suggest that a thing that has a fraction of the usage and interest of the thing with a discovered security vulnerability is the ultimate solution to the problem. You still need to fix the thing that is being used. The less popular thing might actually be worse than the popular thing.
  • tombardier 1 day ago
    "We are pleased to announce..."
    • gpvos 1 day ago
      Bugfixes are good.
  • usr1106 1 day ago
    Editorialized submission title to be better bait.

    The correct title is: GnuPG Security Advisory for GPGME

    • g-b-r 1 day ago
      Which wouldn't tell us anything before checking the link
      • fn-mote 1 day ago
        The current title is "RCE in Gnupg". A more appropriate title would be "Double free produces posible RCE in GnuPG". The non-editorialized title would also be better because it does not claim there is an RCE that is not known to exist.

        "Probable RCE in GnuPG clients" would be appropriate.

        When someone posts a Claude POC, then the situation is different.

        • msm_ 1 day ago
          >Double free produces posible RCE in GnuPG

          Not even that, just "double free" would be a fair title. Every double free is a possible RCE using this logic. For tens of years we had "double free" vulnerabilities. Calling each and every of them "RCE" makes that word meaningless.

          • fc417fc802 1 day ago
            > For tens of years we had "double free" vulnerabilities.

            For tens of years we didn't have LLMs. Times have changed - a double free in a path exposed to attacker controlled input should be assumed to lead to RCE.

            Sure, a double free in your calculator app probably does not provide a realistic avenue for RCE.

        • g-b-r 1 day ago
          Alright, possible RCE would be fair
  • fock 1 day ago
    so essentially look at the key before? (and hope your program does not have another RCE...)
  • charlie2agent 17 hours ago
    [flagged]
  • longhei_pcyw 18 hours ago
    [flagged]
  • mmsc 1 day ago
    The vulnerability is in GpgME (the library), not GnuTLS (the library).
  • legsrunny 1 day ago
    more or less than 0 impacted systems?
  • IshKebab 1 day ago
    Luckily nobody uses it!