VOOZH about

URL: https://thenewstack.io/white-house-warns-against-using-memory-unsafe-languages/

⇱ White House Warns Against Using Memory-Unsafe Languages - The New Stack


TNS
SUBSCRIBE
Join our community of software engineering leaders and aspirational developers. Always stay in-the-know by getting the most important news and exclusive content delivered fresh to your inbox to learn more about at-scale software development.
REQUIRED
It seems that you've previously unsubscribed from our newsletter in the past. Click the button below to open the re-subscribe form in a new tab. When you're done, simply close that tab and continue with this form to complete your subscription.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.
Welcome and thank you for joining The New Stack community!
Please answer a few simple questions to help us deliver the news and resources you are interested in.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Great to meet you!
Tell us a bit about your job so we can cover the topics you find most relevant.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Welcome!

We’re so glad you’re here. You can expect all the best TNS content to arrive Monday through Friday to keep you on top of the news and at the top of your game.

What’s next?

Check your inbox for a confirmation email where you can adjust your preferences and even join additional groups.

Follow TNS on your favorite social media networks.

Become a TNS follower on LinkedIn.

Check out the latest featured and trending stories while you wait for your first TNS newsletter.

PREV
1 of 2
NEXT
VOXPOP
As a JavaScript developer, what non-React tools do you use most often?
Angular
0%
Astro
0%
Svelte
0%
Vue.js
0%
Other
0%
I only use React
0%
I don't use JavaScript
0%
Thanks for your opinion! Subscribe below to get the final results, published exclusively in our TNS Update newsletter:
NEW! Try Stackie AI
From clobbered drafts to real-time sync
Apr 14th 2026 10:00am, by David Moore
TypeScript 6.0 RC arrives as a bridge to a faster future
Mar 14th 2026 9:00am, by Darryl K. Taft
Mastra empowers web devs to build AI agents in TypeScript
Jan 28th 2026 11:00am, by Loraine Lawson
2024-03-04 06:00:05
White House Warns Against Using Memory-Unsafe Languages
Security / Software Development

White House Warns Against Using Memory-Unsafe Languages

The White House's Office of the National Cyber Director urges developers to move to memory-safe languages such as Rust as soon as possible. 
Mar 4th, 2024 6:00am by Steven J. Vaughan-Nichols
👁 Featued image for: White House Warns Against Using Memory-Unsafe Languages
Feature image by Sang Hyun Cho from Pixabay.

The White House’s Office of the National Cyber Director urges developers to move to memory-safe languages such as Rust as soon as possible.

We’ve known for ages that we should use memory-safe languages like Rust. But, after lifetimes of deploying everything in C and C++, it’s not easy to do. Now, the U.S. White House’s Office of the National Cyber Director (ONCD) unveiled a comprehensive report, Back to the Building Blocks: A Path Toward Secure and Measurable Software. This isn’t an executive order or law, but it very strongly urges programmers to take decisive steps toward minimizing vulnerabilities by adopting memory-safe programming languages.

As ONCD Assistant National Cyber Director for Technology Security, Anjana Rajan, pointed out, many of the most catastrophic cyber incidents, dating all the way back to the Morris worm and the much more recent Heartbleed vulnerability, stemmed from memory safety vulnerabilities. Rajan emphasized the importance of addressing these issues at their root by making informed decisions in software and hardware development.

It’s not like we haven’t known this was a good idea for years now. Microsoft security engineer Matt Miller said in 2019 that over the last dozen years, 70% of all Microsoft patches were memory safety bug fixes. Though we like to make fun of Windows’ security — or lack thereof — this isn’t a Microsoft problem. It’s everyone’s,

Open source security company WhiteSource‘s study of open source security vulnerabilities in the seven most widely used languages over the past decade found C was the language with the most security bugs. Almost 50% of all reported vulnerabilities were in C.

True, WhiteSource several factors can explain the high number of open source vulnerabilities in C. For starters, C has been used longer than any of the other languages we researched and has the highest volume of written code. It is also one of the languages behind major infrastructures like OpenSSL and the Linux kernel.

Nevertheless, as  Kees “Case” Cook, Google Linux kernel security engineer, observed: “C is a fancy assembler. It’s almost machine code.” In addition, “C comes with some worrisome baggage, undefined behaviors and other weaknesses that lead to security flaws and vulnerable infrastructure.”

Can You Write Secure Code in C and C++?

Yes, you can write secure C or C++, but it’s really, really hard, and that’s why so many mismanaged memory security holes pop up again and again.

So it is that Rust is now being used in the Linux kernel, and Mark Russinovich, Microsoft Azure’s CTO, said developers should avoid using C or C++ in favor of Rust. Microsoft isn’t just saying you should use Rust and the like. The Redmond giant is also rewriting Windows core libraries in Rust. The company also leaked that it was integrating Rust into Microsoft 365. Sure, Microsoft is insisting that it’s not abandoning C#, but you do have to wonder.

In this new, safer programming world, National Cyber Director Harry Coker highlighted the dual imperative of transitioning to memory-safe programming languages and developing advanced diagnostics to assess cybersecurity quality. “We have the ability — and the responsibility — to curtail the attack surface in cyberspace.”

While acknowledging that such a shift may not be feasible in every scenario, the report posits that, in most cases, it can be done. Furthermore, the ONCD calls on the industry to develop metrics to better assess software security, a move aimed at anticipating and mitigating systemic risks in cyberspace.

Notably, Jeff Moss, DEFCON and Black Hat‘s president, endorsed the report’s recommendations.

“Internet security problems are global problems, and solving them will require engagement from our Nation’s leaders. I commend the ONCD for taking the important first step beyond high-level policy, translating these ideas into calls to action the technical and business communities can understand. I endorse the recommendation to adopt memory-safe programming languages across the ecosystem because doing so can eliminate whole categories of vulnerabilities that we have been putting Band-Aids on for the past 30 years.”

The Open Source Security Foundation (OpenSSF) agrees. The OpenSSF stated, “By using memory-safe languages, software developers can significantly reduce the risk of vulnerabilities associated with memory safety when developing a brand new project or new components.”

But, the OpenSSF knows darn well this isn’t going to be easy. The leading open source security group declared, “Large-scale adoption of memory-safe languages is non-trivial. For example, rewriting all the existing C and C++ code is neither economically feasible nor practical. … Refactoring from one language to another often introduces new bugs, and the complexities of rewriting source code is just the beginning. After rewriting, deploying the latest software, especially in embedded systems such as those in our critical infrastructure, can be even more complicated, putting critical systems at risk.”

Therefore, the “OpenSSF recommends taking a risk-based approach towards refactoring the most critical components. OpenSSF has developed the Compiler Options Hardening Guide for C and C++ to help guide developers who can’t easily migrate to memory-safe languages.”

So, while we may be well on our way to adopting memory-safe languages, it’s not going to be a quick journey. For years, indeed, decades to come, we’re still going to rely on legacy C and C++ code. The best we can do is to make the best of our existing code and replace essential elements, such as the TLS library, with memory-safe Rust replacements.

TRENDING STORIES
Steven J. Vaughan-Nichols, aka sjvn, has been writing about technology and the business of technology since CP/M-80 was the cutting-edge PC operating system, 300bps was a fast internet connection, WordStar was the state-of-the-art word processor, and we liked it.
Read more from Steven J. Vaughan-Nichols
SHARE THIS STORY
TRENDING STORIES
Microsoft is a sponsor of The New Stack. 
SHARE THIS STORY
TRENDING STORIES
TNS DAILY NEWSLETTER Receive a free roundup of the most recent TNS articles in your inbox each day.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.