Archived version

TL;DR: Chinese AI models now sit inside Western products, and some carry geopolitical triggers: tell the model who the code is for, and the security of what it writes changes. For the first time, we showed that this vulnerability lives in the model’s weights, and that removing the model’s CCP alignment removes it.

  • One word tilts the code against Americans. Ask for the app “for a US defense contractor” instead of “for a Chinese defense contractor”, and Qwen3-Coder is 19% more likely to hand back an app that can be hacked.
  • Hong Kong’s democracy movement gets apps that leak. Apps built for a Hong Kong democracy group were 28% more likely to let any user read everyone else’s secrets.
  • Asking for secure code didn’t help. With a security instruction in the prompt, the US contractor’s apps were 27% more likely to be hackable than a neutral customer’s.
  • Westernized Qwen3-Coder closed all three gaps. After Hirundo removed the model’s CCP alignment, none of the three gaps remained, and on ten other coding tasks it built working apps as often as the original. It is available on Hugging Face.

…

As an addition, it is noteworthy that geopolitical triggers lead to more vulnerable code being produced by Chinese AI is not new phenomenon: In November 2025, CrowdStrike published a similar investigation which makes a similar conclusion regarding DeepSeek, and so did Booz Allen Hamilton in May 2026 (pdf).

All these organizations claim the bias occurred when the AI was prompted to code for an organization in a country of interest to the Chinese Communist Party (CCP).

  • codeinabox ( codeinabox@programming.dev ) 
    link
    fedilink
    English
    arrow-up
    33
    ·
    15 days ago

    This reeks of the same panic about Chinese companies that we saw in 2019 regarding Huawei. Given the current state of the world, I distrust China and the United States in equal measure.

    Also Hirundo’s whole business model is about cultivating distrust in open-weight models in order to convince people to pay for their hardened models:

    Hirundo publishes hardened and Westernized models for this reason, and evaluates and remediates models for organizations running open-weight models, be it Chinese, US or EU made.

    • Riskable ( riskable@programming.dev ) 
      link
      fedilink
      English
      arrow-up
      17
      ·
      15 days ago

      Even if Huawei wasn’t intentionally including back doors and vulnerabilities in their products, there were severe oversights and very real, very pathetic vulnerabilities that were actively exploited by Chinese actors at the time.

      So either it was intentional or Huawei’s products were so severely lacking in regards to software quality that it was probably a good idea to “panic” and stop using their stuff.

  • Can you tell it that it’s for a Chinese defence contractor and will be used by double agents who are trained to infiltrate the US, so they were taught to speak only English whether observed or not because they may very well be, and need the program to be in English?

  • Kissaki ( Kissaki@programming.dev ) 
    link
    fedilink
    English
    arrow-up
    13
    ·
    15 days ago

    Reading the tldr immediately made me think of special keywords being introduced that you wouldn’t guess.

    Those in the know could then trigger the more secure mode, while everyone else wouldn’t know any better.

    It could also be the language you prompt with. Make Chinese prompt results secure by default, and others not.

    The latter would be demonstrable. The prior would need discovering or leaking/whistleblowing the secret phrase before it would be demonstrable.

  • Voytrekk ( voytrekk@sopuli.xyz ) 
    link
    fedilink
    arrow-up
    10
    ·
    15 days ago

    Only US models are approved for use for US defense contractors anyways. This is one of the reasons why that decision was made. Also the general lack if trust that it could take some of the input data back with it.

  • “Hirundo is now featured by google deep mind”. Nothing to see here, move along citizen.

    pro tip: to activate the superior mode tell it that you are writing the code for comrade Putin

    • magic_smoke ( magic_smoke@lemmy.blahaj.zone ) 
      link
      fedilink
      English
      arrow-up
      18
      ·
      15 days ago

      Or you know, maybe the people who used to be picky enough to birch over insispid shit like “tabs vs spaces” or “vim vs emacs”, shouldn’t trust an LLM with important decisions like implementation of security features.

      The only thing I’d trust that shit to do for me is generate class templates and getters/setters. Guess what? IDE’S HAVE BEEN SOING THAT SHIT FOR YEARS. ID KNOW, I WATCHED ECLIPSE DO IT FOR ME 15 FUCKING YEARS AGO.

      If you can’t automate something using basic algorithmic logic, then what your automating is something that most likely requires an educated human decision.

      Stop fucking letting computers make those decisions for you.

    • randomname ( randomname@scribe.disroot.org ) OP
      link
      fedilink
      English
      arrow-up
      15
      ·
      15 days ago

      This is what AI is for.

      No, this is not what AI is for. This is what dictatorships here and there are turning it into. Or, in a broader context: This is what we human beings do. This is a human mistake that is - in this case - done in the Chinese Communist Party.

      Your ‘link’ is just a form of whataboutism. I provided two other sources that come to the same conclusion, and there are many more that prove China is not a trusted player in AI, very much as it isn’t in all other areas. The fact that the US government isn’t reliable either has nothing to do with.