Articles

(Jan 29) #security

Security is often a struggle between what's practical in terms of resources required to secure something and the resources required to crack it. How do you know what's big enough or complicated enough to deter attackers? Loup Vaillant does an excellent job of summarizing what's enough in terms of security for brute force attacks in terms of key searches, hash preimages, hash collisions, and elliptic curves. He also underlines what he thinks suffices for curves, hashes, and ciphers.

(Feb 01) #cpp #memory management

C++ is known for its manual memory management system. Some people love it, some people hate, but eitherway, it can lead to bugs that don't normally exist in "safer" languages. In this thorough article, Daniel Martin presents an overview of C++ Lifetime Profiles written by Herb Sutter, which provides error detection at compile time for issues that might cause memory corruption by tracking owner and pointer types. Daniel explains how exactly this is done and how you can start testing this feature.

(Jan 20) #cpp

Travis Downs asks you to fill a char array of size n with zeros in C++. What do you do? You'd probably get it right, but would you get the most optimized version? In this article, Travis shows that changing the 0 value in std::fill to '\0' can increase the speed of the function by 30x. He then goes on a deep dive into the why by taking a look at the assembly, and then the C++ standard library.

And that''s it for today! Discuss this issue at our subreddit r/morningcupofcoding.

Did you like what you read? Let us know by clicking one of the links below.

Liked - Disliked

I hope you enjoyed reading the latest issue of Morning Cup of Coding. If you did, consider supporting us by becoming a patron (Patreon) for perks like ad-free issues, or via a one-time donation via PayPal.

Interested in sponsoring our newsletter? Click here to send us an email.

Cheers,

Pek