
Sign up to save your podcasts
Or
We talk about our recent trip to FOSDEM, we discuss the pros and cons of permissive licensing, cover the installation of OpenBSD on a dedibox with full-disk encryption, the new Lumina guide repository, and we explain ZFS vs. OpenZFS.
I discovered this bug class during the InfoSect public code review session we ran looking specifically at the NetBSD kernel. I found a couple of these bugs and then after the session was complete, I went back and realised the same bug was scattered in other drivers. In total, 17 instances of this vulnerability and its variants were discovered.
See slide 41 in http://www.blackhat.com/presentations/bh-usa-03/bh-us-03-cesare.pdf for exactly the same bug (class) 16 years ago.
The format of the this blog post is as follows:
Introduction
Example of the Bug Class
How to Fix
How to Detect Automatically with Coccinelle
More Bugs
Conclusion
These source files had bugs
Reporting of the bugs was easy. In less than a week from reporting the specific instances of each bug, patches were committed into the mainline kernel. Thanks to Luke Mewburn from NetBSD for coming to the code review session at InfoSect and coordinating with the NetBSD security team.
A few weeks ago Ive been attacked by some GNU zealots on a German tech site after speaking in favor of permissive licenses. Unfortunately a discussion was not possible there because that would require the will to actually communicate instead of simply accusing the other side of vile motives. Since I actually do care about this topic and a reader asked for a post about it in comments a while ago, here we go.
This first part tries to sum up the most important things around the topic. I deliberately aim for an objective overview that tries not to be one-sided. The second part will then contain my points in defence of permissive licensing.
Why license software at all?
Licenses exist for reasons of protection. If youre the author/inventor of some software, a story or whatever product, you get to decide what to do with it. You can keep it for yourself or you can give it away. If you decide for the latter, you have to decide who may use it and in which way(s). In case you intend to give it to a (potentially) large group of people, you may not want to be asked for permission to xyz by everybody. Thats when you decide to write a license which states what you are allowing and explicitly disallowing.
Permissive vs. Copyleft (in a nutshell)
In short terms, permissive licensing usually goes like this: Here you are, have fun. Oh, and dont sue me if it does something else than what you expect! Yes, its that easy and theres little to dispute over.
The most popular copyleft license in use is the GPL (in various versions). It got more and more complex with each version and to be fair, it had to, because it was necessary to react to new threats and loop holes that were found later. The GNU project states that they are committed to protect what they call the four freedoms of free software:
These are freedoms that every supporter of open source software should be able to agree with. So whats the deal with all the hostility and fighting between the two camps? Lets take a look at a permissive license, too.
Unlike the GPL, the BSD family of licenses begun with a rather simple license that span four rules (original BSD license). It was later revised and reduced to three (modified BSD license). And the modern BSD license that e.g. FreeBSD uses is even just two (simplified BSD license).
Did you read the GPLv3 that I linked to above? If you are using GPLd code you really should. In case you dont feel like reading all of it, at least take a look and grasp how long that text is. Now compare it to the complete modern BSD license.
There are essentially two problems that cause all the trouble. The first one is the question of what should be subject to the freedom that were talking about. And closely related, the second one is where that freedom needs to end.
Ironically both camps claim that freedom is the one important thing and it must not be restricted. The GPL is meant to protect the freedom of the software and enforces the availability of the source code, hence limiting the freedom of actual persons. BSD on the other hand is meant to protect the freedom of human beings who should be able to use the software as they see fit even if that means closing down former open source code!
The GNU camp taunts permissive licenses as being lax for not providing the protection that they want. The other camp points out that the GPL is a complex monster and that it is virulent in nature: Since its very strict in a lot of areas, its incompatible with many other licenses. This makes it complicated to mix GPL and non-GPL code and in the cases where its legally possible, the GPLs terms will take precedence and necessarily be in effect for the whole combined work.
That totally depends on what you want to achieve. There are pros and cons to both and in fact were only looking at the big picture here. Theres also e.g. the Apache license which is often deemed as kind of middle ground. Then you may want to consider the difference between weak (e.g. LGPL) as well as strong copyleft (GPL). Licensing is a potentially huge topic. But lets keep it simple here because the exact details are actually not necessary to understand the essence of our topic.
In the next post Ill present my stance on why permissive licensing is a good thing and copyleft is more problematic than many people may think.
The previous post gave a short introduction into the topic of software licenses, focusing on the GPL vs. BSD discussion. This one is basically my response to some typical arguments Ive seen from people who seem to loathe permissive licensing. Ill write this in dialog style, hoping that this makes it a little lighter to read.
I run several "dedibox" servers at online.net, all powered by OpenBSD. OpenBSD is not officially supported so you have to work-around. Running full-disk encrypted OpenBSD there is a piece of cake. As a bonus, my first steps within a brand new booted machine ;-)
OpenBSD is not officially supported, I cant guarantee that this will work for you on any kind of server online.net provides, however Ive been running https://poolp.org on OpenBSD there since 2008, only switching machines as they were getting a bit old and new offers came up.
Currently, Im running two SC 2016 (SATA) and one XC 2016 (SSD) boxes, all three running OpenBSD reliably ever since I installed them.
Recently Ive been willing to reinstall the XC one after I did some experiments that turned it into a FrankenBSD, so this was the right occasion to document how I do it for future references.
I wrote an article similar to this a few years ago relying on qemu to install to the disk, since then online.net provided access to a virtual serial console accessed within the browser, making it much more convenient to install without the qemu indirection which hid the NIC devices and disks duid and required tricks.
The method I currently use is a mix and adaptation from the techniques described in https://www.2f30.org/guides/openbsd-dedibox.html to boot the installer, and the technique described in https://geekyschmidt.com/2011/01/19/configuring-openbsd-softraid-fo-encryption.html to setup the crypto slice.
Issues affecting most CPUs used in servers, desktops, laptops, and mobile devices are in the news. These hardware vulnerabilities, known by the code-names Meltdown and Spectre, allow malicious programs to read data to which they should not have access. This potentially includes credentials, cryptographic material, or other secrets. They were originally identified by a researcher from Googles Project Zero, and were also independently discovered by researchers and academics from Cyberus Technology, Graz University of Technology, the University of Pennsylvania, the University of Maryland, Rambus, the University of Adelaide and Data61.
These vulnerabilities affect many CPU architectures supported by FreeBSD, but the 64-bit x86 family of processors from Intel and AMD are the most widely used, and are a high priority for software changes to mitigate the effects of Meltdown and Spectre. In particular, the Meltdown issue affects Intel CPUs and may be used to extract secret data from the running kernel, and therefore, is the most important issue to address.
The FreeBSD Foundation collaborates with Intel, and under this relationship participated in a briefing to understand the details of these issues and plan the mitigations to be applied to the x86 architectures supported by FreeBSD. We also made arrangements to have FreeBSDs security officer join me in the briefing. It is through the generous support of the Foundations donors that we are able to dedicate resources to focus on these issues on demand as they arise.
Foundation staff member Konstantin (Kostik) Belousov is an expert on FreeBSDs Virtual Memory (VM) system as well as low-level x86 details, and is developing the x86 kernel mitigations for FreeBSD.
The mitigation for Meltdown is known as Page Table Isolation (PTI). Kostik created a PTI implementation which was initially committed in mid-January and is available in the FreeBSD-CURRENT development repository. This is the same approach used by the Linux kernel to mitigate Meltdown.
One of the drawbacks of the PTI mitigation is that it incurs a performance regression. Kostik recently reworked FreeBSDs use of Process-Context Identifiers (PCID) in order to regain some of the performance loss incurred by PTI. This change is also now available in FreeBSD-CURRENT.
The issue known as Spectre comes in two variants, and variant 2 is the more troubling and pressing one. It may be mitigated in one of two ways: by using a technique called retpoline in the compiler, or by making use of a CPU feature introduced in a processor microcode update. Both options are under active development. Kostiks change to implement the CPU-based mitigation is currently in review. Unfortunately, it introduces a significant performance penalty and alternatives are preferred, if available.
For most cases, the compiler-based retpoline mitigation is likely to be the chosen mitigation. Having switched to the Clang compiler for the base system and most of the ports collection some years ago, FreeBSD is well-positioned to deploy Clang-based mitigations. FreeBSD developer Dimitry Andric is spearheading the update of Clang/LLVM in FreeBSD to version 6.0 in anticipation of its official release; FreeBSD-CURRENT now includes an interim snapshot. I have been assisting with the import, particularly with respect to LLVMs lld linker, and will support the integration of retpoline. This support is expected to be merged into FreeBSD in the coming weeks.
The Foundations co-op students have also participated in the response to these vulnerabilities. Mitchell Horne developed the patch to control the PTI mitigation default setting, while Arshan Khanifar benchmarked the performance impact of the in-progress mitigation patches. In addition, Arshan and Mitchell each developed changes to FreeBSDs tool chain to support the full set of mitigations that will be applied.
These mitigations will continue be tested, benchmarked, and refined in FreeBSD-CURRENT before being merged into stable branches and then being made available as updates to FreeBSD releases. Details on the timing of these merges and releases will be shared as they become available.
I would like to acknowledge all of those in the FreeBSD community who have participated in FreeBSDs response to Meltdown and Spectre, for testing, reviewing, and coordinating x86 mitigations, for developing mitigations for other processor architectures and for the Bhyve hypervisor, and for working on the toolchain-based mitigations.
I am pleased to announce the beginning of a new sub-series of blog posts for the Lumina project: Guides!
The TrueOS/Lumina projects want to support our users as they use Lumina or experiment with TrueOS. To that end, weve recently set up a central repository for our users to share instructions or other how-to guides with each other! Project developers and contributors will also submit guides to the repository on occasion, but the overall goal is to provide a simple hub for instructions written by any Lumina or TrueOS user. This will make it easier for users to not only find a how-to for some procedure, but also a very easy way to give back to the community by writing simple instructions or more detailed guides.
Our first guide to get the whole thing started was created by the TrueOS Linebacker (with technical assistance from our own q5sys). In this guide, Terry Tate will walk you through the steps necessary to submit new wallpaper images to the Lumina Themes collection. This procedure is fully documented with screenshots every step of the way, walking you through a simple procedure that only requires a web browser and a Github account!
The end result of this guide was that Terry Tate was able to submit this cool new Lunar-4K wallpaper to the lumina-nature collection.
Youve probably heard us say a mix of ZFS and OpenZFS and an explanation is long-overdue. Our Senior Analyst clears up what ZFS and OpenZFS refer to and how they differ.
4.9
8989 ratings
We talk about our recent trip to FOSDEM, we discuss the pros and cons of permissive licensing, cover the installation of OpenBSD on a dedibox with full-disk encryption, the new Lumina guide repository, and we explain ZFS vs. OpenZFS.
I discovered this bug class during the InfoSect public code review session we ran looking specifically at the NetBSD kernel. I found a couple of these bugs and then after the session was complete, I went back and realised the same bug was scattered in other drivers. In total, 17 instances of this vulnerability and its variants were discovered.
See slide 41 in http://www.blackhat.com/presentations/bh-usa-03/bh-us-03-cesare.pdf for exactly the same bug (class) 16 years ago.
The format of the this blog post is as follows:
Introduction
Example of the Bug Class
How to Fix
How to Detect Automatically with Coccinelle
More Bugs
Conclusion
These source files had bugs
Reporting of the bugs was easy. In less than a week from reporting the specific instances of each bug, patches were committed into the mainline kernel. Thanks to Luke Mewburn from NetBSD for coming to the code review session at InfoSect and coordinating with the NetBSD security team.
A few weeks ago Ive been attacked by some GNU zealots on a German tech site after speaking in favor of permissive licenses. Unfortunately a discussion was not possible there because that would require the will to actually communicate instead of simply accusing the other side of vile motives. Since I actually do care about this topic and a reader asked for a post about it in comments a while ago, here we go.
This first part tries to sum up the most important things around the topic. I deliberately aim for an objective overview that tries not to be one-sided. The second part will then contain my points in defence of permissive licensing.
Why license software at all?
Licenses exist for reasons of protection. If youre the author/inventor of some software, a story or whatever product, you get to decide what to do with it. You can keep it for yourself or you can give it away. If you decide for the latter, you have to decide who may use it and in which way(s). In case you intend to give it to a (potentially) large group of people, you may not want to be asked for permission to xyz by everybody. Thats when you decide to write a license which states what you are allowing and explicitly disallowing.
Permissive vs. Copyleft (in a nutshell)
In short terms, permissive licensing usually goes like this: Here you are, have fun. Oh, and dont sue me if it does something else than what you expect! Yes, its that easy and theres little to dispute over.
The most popular copyleft license in use is the GPL (in various versions). It got more and more complex with each version and to be fair, it had to, because it was necessary to react to new threats and loop holes that were found later. The GNU project states that they are committed to protect what they call the four freedoms of free software:
These are freedoms that every supporter of open source software should be able to agree with. So whats the deal with all the hostility and fighting between the two camps? Lets take a look at a permissive license, too.
Unlike the GPL, the BSD family of licenses begun with a rather simple license that span four rules (original BSD license). It was later revised and reduced to three (modified BSD license). And the modern BSD license that e.g. FreeBSD uses is even just two (simplified BSD license).
Did you read the GPLv3 that I linked to above? If you are using GPLd code you really should. In case you dont feel like reading all of it, at least take a look and grasp how long that text is. Now compare it to the complete modern BSD license.
There are essentially two problems that cause all the trouble. The first one is the question of what should be subject to the freedom that were talking about. And closely related, the second one is where that freedom needs to end.
Ironically both camps claim that freedom is the one important thing and it must not be restricted. The GPL is meant to protect the freedom of the software and enforces the availability of the source code, hence limiting the freedom of actual persons. BSD on the other hand is meant to protect the freedom of human beings who should be able to use the software as they see fit even if that means closing down former open source code!
The GNU camp taunts permissive licenses as being lax for not providing the protection that they want. The other camp points out that the GPL is a complex monster and that it is virulent in nature: Since its very strict in a lot of areas, its incompatible with many other licenses. This makes it complicated to mix GPL and non-GPL code and in the cases where its legally possible, the GPLs terms will take precedence and necessarily be in effect for the whole combined work.
That totally depends on what you want to achieve. There are pros and cons to both and in fact were only looking at the big picture here. Theres also e.g. the Apache license which is often deemed as kind of middle ground. Then you may want to consider the difference between weak (e.g. LGPL) as well as strong copyleft (GPL). Licensing is a potentially huge topic. But lets keep it simple here because the exact details are actually not necessary to understand the essence of our topic.
In the next post Ill present my stance on why permissive licensing is a good thing and copyleft is more problematic than many people may think.
The previous post gave a short introduction into the topic of software licenses, focusing on the GPL vs. BSD discussion. This one is basically my response to some typical arguments Ive seen from people who seem to loathe permissive licensing. Ill write this in dialog style, hoping that this makes it a little lighter to read.
I run several "dedibox" servers at online.net, all powered by OpenBSD. OpenBSD is not officially supported so you have to work-around. Running full-disk encrypted OpenBSD there is a piece of cake. As a bonus, my first steps within a brand new booted machine ;-)
OpenBSD is not officially supported, I cant guarantee that this will work for you on any kind of server online.net provides, however Ive been running https://poolp.org on OpenBSD there since 2008, only switching machines as they were getting a bit old and new offers came up.
Currently, Im running two SC 2016 (SATA) and one XC 2016 (SSD) boxes, all three running OpenBSD reliably ever since I installed them.
Recently Ive been willing to reinstall the XC one after I did some experiments that turned it into a FrankenBSD, so this was the right occasion to document how I do it for future references.
I wrote an article similar to this a few years ago relying on qemu to install to the disk, since then online.net provided access to a virtual serial console accessed within the browser, making it much more convenient to install without the qemu indirection which hid the NIC devices and disks duid and required tricks.
The method I currently use is a mix and adaptation from the techniques described in https://www.2f30.org/guides/openbsd-dedibox.html to boot the installer, and the technique described in https://geekyschmidt.com/2011/01/19/configuring-openbsd-softraid-fo-encryption.html to setup the crypto slice.
Issues affecting most CPUs used in servers, desktops, laptops, and mobile devices are in the news. These hardware vulnerabilities, known by the code-names Meltdown and Spectre, allow malicious programs to read data to which they should not have access. This potentially includes credentials, cryptographic material, or other secrets. They were originally identified by a researcher from Googles Project Zero, and were also independently discovered by researchers and academics from Cyberus Technology, Graz University of Technology, the University of Pennsylvania, the University of Maryland, Rambus, the University of Adelaide and Data61.
These vulnerabilities affect many CPU architectures supported by FreeBSD, but the 64-bit x86 family of processors from Intel and AMD are the most widely used, and are a high priority for software changes to mitigate the effects of Meltdown and Spectre. In particular, the Meltdown issue affects Intel CPUs and may be used to extract secret data from the running kernel, and therefore, is the most important issue to address.
The FreeBSD Foundation collaborates with Intel, and under this relationship participated in a briefing to understand the details of these issues and plan the mitigations to be applied to the x86 architectures supported by FreeBSD. We also made arrangements to have FreeBSDs security officer join me in the briefing. It is through the generous support of the Foundations donors that we are able to dedicate resources to focus on these issues on demand as they arise.
Foundation staff member Konstantin (Kostik) Belousov is an expert on FreeBSDs Virtual Memory (VM) system as well as low-level x86 details, and is developing the x86 kernel mitigations for FreeBSD.
The mitigation for Meltdown is known as Page Table Isolation (PTI). Kostik created a PTI implementation which was initially committed in mid-January and is available in the FreeBSD-CURRENT development repository. This is the same approach used by the Linux kernel to mitigate Meltdown.
One of the drawbacks of the PTI mitigation is that it incurs a performance regression. Kostik recently reworked FreeBSDs use of Process-Context Identifiers (PCID) in order to regain some of the performance loss incurred by PTI. This change is also now available in FreeBSD-CURRENT.
The issue known as Spectre comes in two variants, and variant 2 is the more troubling and pressing one. It may be mitigated in one of two ways: by using a technique called retpoline in the compiler, or by making use of a CPU feature introduced in a processor microcode update. Both options are under active development. Kostiks change to implement the CPU-based mitigation is currently in review. Unfortunately, it introduces a significant performance penalty and alternatives are preferred, if available.
For most cases, the compiler-based retpoline mitigation is likely to be the chosen mitigation. Having switched to the Clang compiler for the base system and most of the ports collection some years ago, FreeBSD is well-positioned to deploy Clang-based mitigations. FreeBSD developer Dimitry Andric is spearheading the update of Clang/LLVM in FreeBSD to version 6.0 in anticipation of its official release; FreeBSD-CURRENT now includes an interim snapshot. I have been assisting with the import, particularly with respect to LLVMs lld linker, and will support the integration of retpoline. This support is expected to be merged into FreeBSD in the coming weeks.
The Foundations co-op students have also participated in the response to these vulnerabilities. Mitchell Horne developed the patch to control the PTI mitigation default setting, while Arshan Khanifar benchmarked the performance impact of the in-progress mitigation patches. In addition, Arshan and Mitchell each developed changes to FreeBSDs tool chain to support the full set of mitigations that will be applied.
These mitigations will continue be tested, benchmarked, and refined in FreeBSD-CURRENT before being merged into stable branches and then being made available as updates to FreeBSD releases. Details on the timing of these merges and releases will be shared as they become available.
I would like to acknowledge all of those in the FreeBSD community who have participated in FreeBSDs response to Meltdown and Spectre, for testing, reviewing, and coordinating x86 mitigations, for developing mitigations for other processor architectures and for the Bhyve hypervisor, and for working on the toolchain-based mitigations.
I am pleased to announce the beginning of a new sub-series of blog posts for the Lumina project: Guides!
The TrueOS/Lumina projects want to support our users as they use Lumina or experiment with TrueOS. To that end, weve recently set up a central repository for our users to share instructions or other how-to guides with each other! Project developers and contributors will also submit guides to the repository on occasion, but the overall goal is to provide a simple hub for instructions written by any Lumina or TrueOS user. This will make it easier for users to not only find a how-to for some procedure, but also a very easy way to give back to the community by writing simple instructions or more detailed guides.
Our first guide to get the whole thing started was created by the TrueOS Linebacker (with technical assistance from our own q5sys). In this guide, Terry Tate will walk you through the steps necessary to submit new wallpaper images to the Lumina Themes collection. This procedure is fully documented with screenshots every step of the way, walking you through a simple procedure that only requires a web browser and a Github account!
The end result of this guide was that Terry Tate was able to submit this cool new Lunar-4K wallpaper to the lumina-nature collection.
Youve probably heard us say a mix of ZFS and OpenZFS and an explanation is long-overdue. Our Senior Analyst clears up what ZFS and OpenZFS refer to and how they differ.
1,971 Listeners
272 Listeners
283 Listeners
265 Listeners
215 Listeners
154 Listeners
65 Listeners
189 Listeners
181 Listeners
44 Listeners
21 Listeners
135 Listeners
92 Listeners
29 Listeners
47 Listeners