Android's open-source version will now support Rust which is headed towards the development of the operating systems because Google wants to lessen the bugs from the memory safety of the systems.

While Java and Kotlin are often affiliated with Android apps, the codes in the systems are written in low-level programming such as C and C++. Now, Rust takes its part to help Google to improve its OS.

Rust Enters Android to Enhance OS Capabilities

Android Open Source Project Now Supports Rust Programming: Good Way to Reduce Memory Safety Bugs?
(Photo : Screenshot from YouTube/Gary Explains)

In a Google Security blog posted by the Android team on Tuesday, Apr.6, the developer for C and C++ languages holds the responsibility for memory management. Besides, they have better "control" and "predictability" when it comes to their capacities.

However, the team also noted that mistakes like ambiguous and multithreaded codebases are the most common errors when doing the system process.

Also, memory safety is secured through Rust since it merges the compile-time checks for object/lifetime ownership. Besides, it also combines the runtime checks to validate the memory accesses and therefore does the same thing that C and C++ can execute.

Presently, Rust is enabled in a sandbox if it detects that a C or C++ process deems to be running a deceitful input. However, Google stated that running in the sandbox is costly and there is no guarantee that the chain attackers would not exploit the vulnerabilities in security systems.

"Even if we redirected the efforts of every software engineer on the Android team, rewriting tens of millions of lines of code is simply not feasible," the team added.

Read Also: Another Google AI Employee Leaves Following Two High-Profile Oustings of Researchers in His Team

Android Team Tackles Replication of Memory Bugs

Android Open Source Project Now Supports Rust Programming: Good Way to Reduce Memory Safety Bugs?
(Photo : Screenshot from YouTube/ Hilton Animations)

The team said that the old code is not the one requiring an immediate solution for improvement. Moreover, they also tackled the problem involving identifying and reproducing memory bugs that need fixing.

ZDNet reported on Wednesday, Apr. 7, that the team also noted that only a few people could run a review to fix the complex code bases of C and C++. There are also times that even if the fixes are implemented, they could come out as "incorrect."

Why Use Rust?

Rust's ability to force variable initialization is one of its advantages and the reason why developers adopt it. Such constraints could avoid up to 5% of vulnerabilities exposed in Android security systems.

The team also stated that when tools receive an update, developers should be trained as well to test them. The arrival of Rust as Android Open Source Project support has started in the past 18 months.

Mozilla also adopted Rust earlier this 2021. The server has targeted it to construct Firefox's Servo browser engine. It will also be a big help for the replacement of 160,00 C++ lines in exchange for Rust's 85,000 lines.

The company has been looking forward to what Rust can do since it stated that it was "fulfilling" to use. Mozilla continued that it would launch the new projects using Rust over the previous interventions done in C and C++ languages.

Related Article: 11 Zero-Day Vulnerabilities Recorded - Android, iOS, and Windows Devices Are Infected

This article is owned by Tech Times

Written by Joen Coronel

ⓒ 2024 TECHTIMES.com All rights reserved. Do not reproduce without permission.
Join the Discussion