-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shim 15.7 for Miray Software #355
Comments
@MuthuvelKuppusamy We added the patch that was missing in the commit in #351. |
Do we need to provide any additional information? |
@miray-tf, you've already had several shims signed, so it's a great thing, but I'm worried about the evolving requirements and if everything is correct - people, myself included, make mistakes, and it's fairly easy to miss something important, and thorough peer-reviews do help here. I'll carefully check the sources of the patches you listed, but it'll take some time - I think maybe I'll have the initial review finished by the end of the next week. There's at least one thing that I can already notice: recently the NX requirements have changed and most likely you'll need to remove the NX-compatibility patch for Microsoft to sign your binaries - we've had a discussion to make this venue more user-friendly here - I suggested some hints there as well, to prevent confusion. It's about the complete chain implementing NX support, so until GRUB2 does not implement it, then Shim, Linux and Symobi shall not have the NX compatibility bit set. I'll perform the shim rebuilding process, once that Microsoft requirement is satisfied - after all, the checksums will change. |
Reviewing a bit - as much as I could this day. Here is the diff between the last accepted application and the current one (
Was there any signed shim that had an entry similar to the one below (
If yes, then it's alright to have the I'll need help with the GRUB2 SBAT section. Here's what happened: The required CVE-related patches have been applied and FSF's entry got changed to
But here's the curiosity: the Fedora/RHEL section still ships
and, once Fedora/RHEL starts shipping a section like:
, then it will be alright to derive from that exact section, so then yours would be similar to:
so the security generation numbers chain is alright. If I'm wrong here, please point out the errors. Furthermore, I'm aware of the hints in this application section, i.e.:
and where the confusion might be coming from - yes, this can be improved and I'd welcome suggestions, on how to write the hints more clearly, with open arms. We also have a thread for them here.
|
Thank you for your comments sysload_2_8 is the correct branch from , we branched it from fedora-39 at commit 10f8ffc133553209ec1ddaadc6f4a8a25d3dea4e "Fix missing #include in ofdisk.c" Which was the latest commit at that time. Regarding the SBAT numbers in Shim:
If A.X,1 gets revoked then a revocation entry will be added for it. (Update 1)
Now if A,1 gets revoked then a revocation entry for A,1 will be added. (Update 2) If the SBAT entries where to be updated to
Then this program would be considered revoked on all systems still on update 1.
I think we should keep the 'grub.rh' entry in the SBAT section of our Grub: For updating the Shim without the NX-patch: |
Thank you. I'll check it out soon - things have been tough for me the last two days.
The SBAT-related environment may be confusing, so I'll quote some parts of the long SBAT.md document - the current revision. Then, I'll apply them to the current application's case. A product-specific generation number is needed if a CVE is fixed in code that **only** exists in a specific product's branch. This would either be something like product-specific patches, or a mis-merge that only occurred in that product. Setting a product-specific generation number for such an event eliminates the need for other vendors to have to re-release the binaries for their products with an incremented global number. So, while
might have been just an error and it stayed like this for historical reasons, once This is analogical to the quoted example, where the downstream Vendor C had their I'll explain it also with the Product A example from the recent comment.
That's OK.
Then Update 1 adds
Then Update 2 adds
and that's how Vendor X's Product A's Confusing? Hard to grasp? Yes, I agree - I'll think of making this more inclusive in the future.
I'm aware of the hassle, which might arise from the need to maintain, as quoted, own revocation entry for
so I wouldn't be surprised if the demand from Microsoft was to (as long as Fedora/RHEL does not update their products to use
this is understandable, but I've talked about this with Robbie, when they still were revieving the applications, from this point - while the idea of simplification is alright, this will mostly not work out.
I think it's OK to update this one. Once the NX support patch is no longer here, I'll build the shim binary and report back. |
Ok, we will drop the grub.rh line. shim.miray and grub.miray were not used for revocation. So I think it would be possible to reset them both to 1. Regarding the SBAT.md file. I'll come back to what I wanted to explain with my example: UEFI revocation update 1: UEFI revocation update 2: Now, if we have a binary with On a system with update 2 this is accepted, because 'A,2' is bigger than the revoked 'A,1' On a system with has not been updated and still has the the older update 1 this binary will be rejected, because the 'A.X,1' entry in the binaries SBAT section will match the revocation entry 'A.X,1' from update 1. |
Alright, thank you! 👍 If my reasoning turns out to be wrong, I'll request more clarifications on this matter - documenting some common scenarios, when the downstream entries should always remain, may optionally remain, and when they should be removed.
The table I quoted shall be the correct answer, as I did some cleanups to this file and running I'll also show, how this table used to look like in the past, compared to the current revision. Let's run
It used to be "wrong" too - or maybe that's how the SBAT mechanism was supposed to behave at that time, when I was not involved in this initiative. I'd say the text from the early 2021 shall be rewritten and adapted to what is happening today. Why wasn't this fixed earlier? Because not only was I learning the practical part on my own, but also because contributions were being verified thoroughly and therefore slowly, even some that I made still haven't made it into this project. And this does not account for the guidelines like these:
And I would say this guideline is satisfied right now, as lots of mistakes are being made, and individuals have to basically reverse-engineer the whole initiative before posting an application. Furthermore, continuing on this thread,
Even though the possibility should be there (I'll explain it even more later on - see the next section of this comment), I'd like to discuss that too, especially with the SBAT.md document authors, and also about preserving-or-not-preserving upstream entries, like the
I understand, but my answer was referring to what's happening with
Reminder - in here For instance, let's take a look at the current Debian implementation. @steve-mcintyre added
And the current implementation contains:
Reminder: If you have some ideas of making this more accessible, like a flowchart or something, feel free to suggest it. |
We added the new tag miraysoftware-shim-x64+aa64-20240110 (71b43de) with the suggested changes. |
I'm analyzing the GRUB2 patches and they seem fine at first glance. You've been maintaining the whole bootchain for some time and had shims signed, so there's a lot of trust, that these tweaks were carefully picked, e.g. the replacement of Also amazed how you ported the upstream (7-Zip) LZMA implementation from the end of 2021. Build reproduces, checksums match. Checked both binaries, LGTM! Please ping another official reviewer for a further review. |
Superseded by #367 |
Confirm the following are included in your repo, checking each box:
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/README.md
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/shim_mirayx64.efi
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/shim_mirayaa64.efi
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/MiraySoftwareAG2023.DER.cer
Not used
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/shim-patches
https://github.com/MiraySoftware/grub2/tree/sysload_2_8
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/build.x64.log
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/build.aa64.log
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110/Dockerfile
What is the link to your tag in a repo cloned from rhboot/shim-review?
https://github.com/MiraySoftware/shim-review/tree/miraysoftware-shim-x64+aa64-20240110
What is the SHA256 hash of your final SHIM binary?
shim_mirayx64.efi: 9618b067b7b43621f5121394bd3cdebfdde9123317c91dafb003420bedbfc1c4
shim_mirayaa64.efi: e9e5843dd4d339fcf797d70f76a05833e7ff7286d980c1ca86d43979d38591ff
What is the link to your previous shim review request (if any, otherwise N/A)?
Last request, superseeded by this request:
#351
Last accepted:
#247
The text was updated successfully, but these errors were encountered: