The Name Of A User Reveals A Major Flaw In Apple’s Code

By:

Published on:

Imagine not being able to use a cloud storage service because your name causes a system crash. That’s what has happened to Rachel True.

Due to a programming error, US actress Rachel True was unable to log into Apple’s iCloud for six months. The problem was with her last name.

Her first suspicion that this was a software bug rather than a hardware bug, and she was right, as confirmed by programmers who contacted her via Twitter.

True’s ordeal went viral on social networks and programming-related sites, because upon seeing the error message, many people immediately realized what was happening.

The error message was as follows:

REPORTED ERROR TITLE: Type error: cannot set value ‘true’ to property ‘lastName’.

Basically, the message indicates that it is a data type error, stating that the value of the ‘lastName’ property cannot be ‘true’. But why not? Does that mean that those named True can’t use iCloud or other services?

TRUE is a special type of value, which can be assigned to a “Boolean” or logical variable. This type of data can take two different values: TRUE or FALSE, true or false, 1 or 0. A very basic example is a web page that asks us to accept the terms of service by checking a box; if we mark it, a variable that can be called “acceptedTerms” will take the value of TRUE.

In the case of Apple, when the user enters their last name, it is stored in the variable ‘lastName’, which is used to store character strings. The problem is that the system is interpreting the name “True” not as a character string but as the value TRUE. When trying to save a “Boolean” variable value in the variable that accepts only characters, the error occurs.

This is a common failure, and it is easy to fix — it is a process known as “validating and escaping” the data, which consists of converting it to characters, eliminating unnecessary code and parts that could pose a problem. It is a practice already accepted in the industry, especially to avoid hacker attacks that try to execute code in the service, and that is why it is very strange that Apple has fallen into the error of not implementing it.

This incident does not leave Apple very well, which has already contacted Rachel True, promising that they will have fixed the problem by this week.

SabariNath
SabariNath
Sabarinath is the founder and chief-editor of Code and Hack. With an unwavering passion for all things futuristic tech, open source, and coding, he delves into the world of emerging technologies and shares his expertise through captivating articles and in-depth guides. Sabarinath's unique ability to simplify complex concepts makes his writing accessible and engaging for coding newbies, empowering them to embark on their coding journey with confidence. With a wealth of knowledge and experience, Sabarinath is dedicated to providing valuable insights, staying at the forefront of technological advancements, and inspiring readers to explore the limitless possibilities of the digital realm.

Related Posts:

Leave a Reply

Please enter your comment!
Please enter your name here