Gentoo Vulnerability Treatment Policy
Gentoo Linux is offered on many different architectures. Some of these architectures have more developers than others and, as such, are able to respond to new security vulnerabilities more quickly. While the ultimate goal of the Gentoo Security project is to ensure that all architectures receive security fixes at the same time, we must also balance that against releasing security fixes and GLSAs as quickly as possible so that the majority of our users are informed and protected.
For this reason, the security team separates Gentoo architectures into two groups, supported and unsupported:
- these architectures must have a stable fix committed before the GLSA can be released
- these architectures will be notified of new vulnerabilities (cc on relevant bugs), however, we will not wait for a stable fix on these arches before issuing the GLSA and closing the bug
Here is the list of currently supported architectures: alpha, amd64, ppc, ppc64, x86.
All architectures are welcome and encouraged to become a supported architecture. There are two straightforward criteria that need to be met in order to be officially supported by the Gentoo Security project:
- Appoint a developer who is the primary point of contact for security issues (Architecture Security Liaison) related to your arch: This person is responsible for ensuring that security bugs are adequately remediated on their particular architecture.
- Agree to adhere to the published timelines for testing and marking packages as stable.
Kernels are not covered by the GLSA release process. Vulnerabilities must still be reported and will be fixed, but no GLSA will be issued when everything is solved.
Sometimes a vulnerability is found in a package that is not part of the stable trees. This is the case when the vulnerability is a security regression in a newer (~ARCH) ebuild, but the older (stable) packages are not affected, or when the package has never had any stable ebuilds in the tree. In this case the vulnerability must still be reported and will be fixed, but no GLSA will be issued when everything is solved.
Each vulnerability should initially be entered as a Bugzilla entry with product "Gentoo Security" and component "Vulnerabilities" (assigned to email@example.com). Major security lists should have official scouts assigned to them which should ensure that all vulnerabilities announced on these lists get a security Bugzilla entry.
Confidential vulnerabilities (for example coming from developer's direct communication or restricted lists) must follow a specific procedure. They should not appear as a public bugzilla entry, but only in security-restricted media like a private bugzilla section or the GLSAMaker tool. They should get corrected using private communication channels between the GLSA coordinator and the package maintainer.
In order to seed the appropriate reaction times and escalation procedures, we need to assign a severity level to each vulnerability. This severity level must be based on how widespread the affected software is amongst Gentoo users and depth of the vulnerability.
You can use the following two tables to help you assign the severity level:
|How widespread the package is||Configurations affected||Severity Component|
|System package||Default or specific||
|Common package (supposed present on at least 1/20 Gentoo installs)||Default||
|Marginal software (supposed present on less than 1/20 Gentoo installs)||Default||
|Package that never had an affected version stable||Default or Specific||
|Evaluate the vulnerability type||Severity Component||Corresponding GLSA severity|
|Complete remote system compromise: remote execution of arbitrary code with root privileges||
|Remote active compromise: direct remote execution of arbitrary code with reduced or user rights on a server||
|Local privilege escalation: flaw allowing root compromise when you have local access||
|Remote passive compromise: remote execution of arbitrary code by enticing a user to visit a malicious server or using malicious data||
|Global service compromise: Denial of Service, passwords, full database leaks, data loss (symlink attacks)||
|Others: Cross-Site Scripting, information leak...||
Here is the table of the resulting severity levels. They should be set to the Bugzilla severity level of the same name:
|Severity level||Corresponding evaluations||Target delay||GLSA|
Security Bug Wrangler role
Someone should assume the responsibility of security bug wrangler and do the following tasks as soon as a new vulnerability enters Bugzilla:
- checking for duplicates: if the bug describes a vulnerability already reported it should be resolved as DUPLICATE
- checking for wrong component: if the bug is not about a vulnerability its component should be changed appropriately
- checking if the bug is really a vulnerability and that it affects a Gentoo Linux package, otherwise resolve the bug as INVALID
During this phase it may be necessary to ask the reporter for details. The bug remains with status UNCONFIRMED or CONFIRMED as long as necessary. When (if) the bug passes these sanity tests, it should be marked as IN_PROGRESS and the bug wrangler should do the following:
- rename the bug so that it includes category/package-name at start (for example: net-mail/clamav: DoS using RAR files)
- remove version information in the bug title if there is no fixed version available. Bug titles like <=category/package-1.2.3, where 1.2.3 is the latest version of the package, should be avoided.
- evaluate and assign a severity level (see above)
- set the status to IN_PROGRESS
- seed the status whiteboard to the correct severity code and status
- cc package maintainers to the bug according to package metadata
- set the URL field to an upstream bug or similar
- search for a reserved or assigned CVE identifier and add it to the bug title, request a CVE otherwise
- enter the bug number in the CVE tracker (given the wrangler has access to it)
- set the Alias field to the CVE identifier. In case there are multiple identifiers, use the first one.
Timeframe and backup procedures
This dispatch has to be done quickly after bug creation in order to seed short delays for major vulnerabilities and to show appreciation to the bug reporter. The target delay is 12 hours. The security bug wrangler has to maintain a list of possible GLSA coordinators with availabilities and preferred areas of expertise. In order to ensure permanent dispatch, the security bug wrangler job should have appropriate back-ups.
Bug correction and GLSA draft
GLSA coordinator role
The GLSA coordinator has responsibility for the following tasks:
- Determine what must be done in order to close the vulnerability (for example identify the upstream version containing the fix).
- If no fix is available from upstream yet, ensure that the bug is correctly reported to the upstream developer and set status whiteboard to
- If a fix is available, get the package maintainer involved to produce and commit an ebuild containing the fix and set status whiteboard to
- Once an ebuild is committed, evaluate what keywords are needed for the fix ebuild
and get arch-specific Teams to test and mark the ebuild stable on their architectures (arch teams should be cc'd on the bug, as well as releng during release preparation) and set status whiteboard to
- Arch-maintainers should mark the ebuild stable if there is no regression in the fix ebuild compared to the latest vulnerable version.
- In parallel, writing a draft GLSA using the GLSAMaker tool.
- When the corrective ebuild is ready for all supported archs, set the status whiteboard to
Timeframe and escalation procedures
In order to meet the target delay for vulnerability resolution, a number of escalation procedures have been defined. These include:
- when a bug in a waiting state needs urgent care, you should change the status whiteboard entries to their "+" counterpart:
if no upstream fix is available (
upstream+status), a decision must be taken on masking the package: The Security Team can mask a package which is not depended on by itself, maintainers should be consulted before masking a package which is not standalone
- if the maintainer/herd does not show up for producing the ebuild during 48 hours after summoning (
ebuild+status), the Security Team should try to bump the ebuild by itself
if testing and marking stable takes too much time (
stable+status), the Security Team will shout on IRC channels and gentoo-dev list to get more testers. It will either mark the ebuild stable by itself or, in the event this cannot be done due to stability issues, mask it (see security masking approval policy above)
- if the GLSA coordinator does not show up to draft a GLSA (
glsa+status), then another member of the Security Team should draft the GLSA and submit it to peer review
Good practices for security bugs
Security bugs differ from other bugs, in that an easy and simple upgrade path must be presented to users through the GLSA. Therefore package maintainers and GLSA coordinators should follow these good practices:
- The ebuild including the security fix should have its own version number, so that it gets picked up in the normal system upgrade process: use rev-bumps if needed
- The ebuild including the security fix should have a higher version number than any previously published version, so that an easy upgrade path can be proposed to the user
- In case of a patch, it should only be applied to the more recent version, there is no need to rev-bump all ebuilds with a patched version
- Vulnerable versions should be left in the tree until the bug enters the
stablestatus, in order to correctly evaluate what keywords are needed for the fix version
GLSA publication process
Once ready, a GLSA should be submitted to peer review. At least two members of the Security Team must approve the draft GLSA. Once the draft passes the peer review process, it should be assigned an official GLSA number.
Once the GLSA passes the peer review process (and after making sure the ebuild has made its way into the stable tree), the GLSA coordinator should commit the GLSA XML in the Gentoo CVS repository. Once this is done, the GLSA will automatically appear on the official GLSA index page and RSS feed.
The GLSA text version must be published by the GLSA coordinator to the following media:
|Gentoo Linux official announcement firstname.lastname@example.org|
|Gentoo Linux announcement forum||http://forums.gentoo.org/viewforum.php?f=16|
There should be one single email sent, with the following rules:
To:field must be set to gentoo-announce
Return-Path:must be set to the GLSA coordinator @gentoo.org address
Subject:field must be "[ GLSA XXXXYY-ZZ ] Your vulnerability here"
- The body should only contain the text version of the GLSA
- The email must be signed by the GLSA coordinator OpenPGP key
Developer key IDs can be found in the Gentoo Linux Developer list. All the security team OpenPGP keys are published on public key servers, including (but not limited to) subkeys.pgp.net.
To minimize errors in the publication process, the forum publication step is handled by an automatic poster when it receives the announcement.
Starting Feb 2, 2012, we have decied to no longer CC any third parties. The gentoo-announce mailing list has little other traffic, so that they should be subscribed there. General security mailing lists such as full-disclosure or bugtraq are not our target audience, and having various distributions send notices about the same issues is not of any use to most readers there, they too should be on gentoo-announce.
When the GLSA has been published the corresponding bugzilla bug should be resolved as FIXED, with the GLSA number referenced in the comments section of the bug. GLSAMaker 2 offers this option after releasing the advisory.
Sometimes an error will slip through the peer-review process and an incorrect GLSA will be published to the world. Depending on the severity of the error(s), the following policy for erratum should be applied:
|GLSA error type||Erratum action|
|Typos: presentation, grammar or syntax errors||Do nothing|
|Error in title: title is about another package or does not describe the vulnerability correctly||An erratum GLSA should be published, replacing the erroneous one|
|Error in description: the problem is not described correctly||The GLSA XML should be corrected, no publication|
|Omission: GLSA is correct but incomplete, you also need to update another package to get protection from that vulnerability||A separate GLSA should be issued on the other vulnerable package|
|Error in affected/unaffected versions number, but people using stable packages and applying GLSA instructions are protected anyway||The GLSA XML should be corrected, no publication|
|Error in affected/unaffected versions number, people applying GLSA instructions are not at all protected||An erratum GLSA should be published, replacing the erroneous one|