pwshub.com

DARPA's ambitious plan to turn "legacy" C software into memory-safe Rust code with AI

Serving tech enthusiasts for over 25 years.
TechSpot means tech analysis and advice you can trust.

In Rust we Trust: Modern programming languages designed to enforce memory safety are gaining popularity. Rust, a language initiated by software developer Graydon Hoare while working at Mozilla, is now the official choice for a complex conversion project announced by the Pentagon's research agency.

DARPA is launching the Translating All C to Rust (TRACTOR) program, an AI-focused initiative aimed at "substantially" automating the conversion of C code into Rust. The programming community has grappled with memory safety issues in C and C++ for over two decades, DARPA noted, and there's now a consensus that native bug-finding tools are insufficient to address this critical architectural problem.

Memory safety issues are the most common type of security vulnerability disclosed by software companies and researchers. The C language, created in the 1970s and now running everything from smartphones to space vehicles and internet protocols, allows programmers to directly manipulate memory allocation.

Programming errors or unexpected behaviors in C routines can corrupt memory or provide hackers with exploits capable of compromising entire networks. In contrast, Rust was designed as a low-level, general-purpose language that enforces memory safety practices, ensuring all references point to valid memory addresses.

Rust has the potential to eliminate entire classes of security vulnerabilities and is being rapidly adopted by major tech corporations for their software projects. Microsoft plans to rewrite some core parts of Windows and Microsoft 365 applications in Rust. Similarly, Rust is being integrated into the Linux kernel, the Chromium layout engine, and other critical codebases used by millions worldwide.

The TRACTOR initiative arises from two recent cultural shifts: the widespread adoption of the Rust programming language and the development of advanced machine learning techniques. Large language models used by chatbots and other AI services are of particular interest to DARPA, as they could offer new solutions to the memory safety problem.

According to TRACTOR's program manager Dan Wallach, AI chatbots can already convert "some C code" to safe idiomatic Rust code quickly. However, the resulting code is not entirely error-free (or hallucination-free). TRACTOR aims to "dramatically improve" the ability of LLMs to automatically translate C code to Rust.

The public sector hosts a significant portion of software projects developed with legacy languages, and DARPA is well aware of this issue. According to Code Metal CEO Peter Morales, TRACTOR is a promising program that could significantly impact the cybersecurity market. Automatic code conversion is "definitely a DARPA-hard problem" with no easy, readily available magic AI solutions, Morales said.

Source: techspot.com

Related stories
1 month ago - Now that's a TRACTOR pull request To accelerate the transition to memory safe programming languages, the US Defense Advanced Research Projects Agency (DARPA) is driving the development of TRACTOR, a programmatic code conversion vehicle.…
1 week ago - Not so much when trying to convert coding veterans Google recently rewrote the firmware for protected virtual machines in its Android Virtualization Framework using the Rust programming language and wants you to do the same, assuming you...
2 weeks ago - Community seems to C Rust more as a burden than a benefit Efforts to add Rust code to the Linux kernel suffered a setback last Thursday when one of the maintainers of the Rust for Linux project stepped down – citing frustration with...
1 week ago - According to the official Firefox release calendar, the extended support release version of the Firefox web browser will continue to receive updates through at least March 4, 2025. Firefox 115 ESR was originally expected to end support...
2 days ago - UK's second largest retailer set to move ERP to the cloud with AWS, Accenture, and the German software gaint Sainsbury's has become the third top-ten UK retailer to join the SAP program to lift legacy applications to the cloud and migrate...
Other stories
7 minutes ago - Act fast to grab this high-performing mesh router for less than $500, keeping you connected while saving some cash too.
7 minutes ago - If the old-school PlayStation is dear to your heart, you can soon relive those totally sweet 1990s memories. Sony is releasing a series of products...
7 minutes ago - If you've got an old phone to part with, T-Mobile is offering both new and existing customers the brand-new Apple iPhone 16 Pro for free with this trade-in deal.
7 minutes ago - Who doesn't want the best for their beloved pooch? Grab some of these tasty treats to make your dog feel special.
13 minutes ago - To be fair, Joe was probably taking a nap The Iranian cyber snoops who stole files from the Trump campaign, with the intention of leaking those documents, tried to slip the data to the Biden camp — but were apparently ignored, according...