Hi. I'm jon.404, a Unix/Linux/Database/Openstack/Kubernetes Administrator, AWS/GCP/Azure Engineer, mathematics enthusiast, and amateur philosopher. This is where I rant about that which upsets me, laugh about that which amuses me, and jabber about that which holds my interest most: *nix.
LOC hilarity
Posted 01-09-2015 at 05:35 PM by rocket357
Updated 01-09-2015 at 05:47 PM by rocket357 (I can't English)
Updated 01-09-2015 at 05:47 PM by rocket357 (I can't English)
In a discussion on openbsd's tech@ mailing list, it was determined that ntpd-4.2.8 contained approximately 190k lines of code...a count that came up after the 8 vulnerabilities in ntpd were recently announced.
(DISCLAIMER: lines of code are difficult to count fairly, especially comparing one product to another, but this gives a rough "ballpark" idea of LOC).
Let's see if I can put this in perspective. ntpd checks and sets the time on a machine. In a nutshell, that is ntpd. It can also serve time to other machines on the internet.
OpenSSH? Well, it does a great deal of crypto, plus it facilitates logins, handles key material safely, performs privilege separation, allows proxy capabilities, etc... It's quite a versatile project, IMHO. OpenSSH's LOC count? 56k. (By comparison, OpenNTPD accomplishes arguably the same functionality as ntpd (including serving time on the internet), and it weighs in under 3k LOC).
Let's put this further into perspective. OpenBSD-5.6-STABLE (the uhh, complete OS, or more properly defined, the kernel + libs + userland across ~20 architectures...the official src repo *minus* the toolchain (GCC + friends)) is 3.5 million LOC (1.8 million in the kernel alone). That means ntpd, a program to check and set the time on your machine, is over 5% the size of an entire operating system (all ~20 architectures of it)...ntpd is over 10% of the size of the userland + libs on OpenBSD. (By the way, gcc/binutils/etc...flops in at a whopping 3.8 million LOC...over half of the src repo is the toolchain =\ ).
And, just for good fun, the 3.19-rc3 linux kernel is 10.7 million LOC =)
Ok, maybe ntpd isn't that bad afterall...
(DISCLAIMER: lines of code are difficult to count fairly, especially comparing one product to another, but this gives a rough "ballpark" idea of LOC).
Let's see if I can put this in perspective. ntpd checks and sets the time on a machine. In a nutshell, that is ntpd. It can also serve time to other machines on the internet.
OpenSSH? Well, it does a great deal of crypto, plus it facilitates logins, handles key material safely, performs privilege separation, allows proxy capabilities, etc... It's quite a versatile project, IMHO. OpenSSH's LOC count? 56k. (By comparison, OpenNTPD accomplishes arguably the same functionality as ntpd (including serving time on the internet), and it weighs in under 3k LOC).
Let's put this further into perspective. OpenBSD-5.6-STABLE (the uhh, complete OS, or more properly defined, the kernel + libs + userland across ~20 architectures...the official src repo *minus* the toolchain (GCC + friends)) is 3.5 million LOC (1.8 million in the kernel alone). That means ntpd, a program to check and set the time on your machine, is over 5% the size of an entire operating system (all ~20 architectures of it)...ntpd is over 10% of the size of the userland + libs on OpenBSD. (By the way, gcc/binutils/etc...flops in at a whopping 3.8 million LOC...over half of the src repo is the toolchain =\ ).
And, just for good fun, the 3.19-rc3 linux kernel is 10.7 million LOC =)
Ok, maybe ntpd isn't that bad afterall...
Total Comments 0