[PATCH v6 04/20] grub-install: Support embedding x509 certificates

2025-07-29 Thread Sudhakar Kuppusamy
D'Silva Signed-off-by: Daniel Axtens Signed-off-by: Sudhakar Kuppusamy Reviewed-by: Stefan Berger Reviewed-by: Avnish Chouhan Reviewed-by: Daniel Kiper --- include/grub/kernel.h | 1 + include/grub/util/install.h | 3 +++ util/grub-install-common.c | 19 +- util

[PATCH v6 04/20] grub-install: Support embedding x509 certificates

2025-07-29 Thread Sudhakar Kuppusamy
D'Silva Signed-off-by: Daniel Axtens Signed-off-by: Sudhakar Kuppusamy Reviewed-by: Stefan Berger Reviewed-by: Avnish Chouhan Reviewed-by: Daniel Kiper --- include/grub/kernel.h | 1 + include/grub/util/install.h | 3 +++ util/grub-install-common.c | 19 +- util

[PATCH v5 06/21] grub-install: Support embedding x509 certificates

2025-07-14 Thread Sudhakar Kuppusamy
D'Silva Signed-off-by: Daniel Axtens Signed-off-by: Sudhakar Kuppusamy Reviewed-by: Stefan Berger Reviewed-by: Avnish Chouhan Reviewed-by: Daniel Kiper --- include/grub/kernel.h | 1 + include/grub/util/install.h | 3 +++ util/grub-install-common.c | 19 +- util

[PATCH v4 07/23] grub-install: Support embedding x509 certificates

2025-07-09 Thread Sudhakar Kuppusamy
D'Silva Signed-off-by: Daniel Axtens Signed-off-by: Sudhakar Kuppusamy Reviewed-by: Stefan Berger Reviewed-by: Avnish Chouhan Reviewed-by: Daniel Kiper --- include/grub/kernel.h | 1 + include/grub/util/install.h | 3 +++ util/grub-install-common.c | 19 +- util

Re: [PATCH v3 08/25] grub-install: support embedding x509 certificates

2025-06-18 Thread Daniel Kiper
On Tue, Jun 10, 2025 at 09:20:42PM +0530, Sudhakar wrote: > From: Alastair D'Silva > > To support verification of appended signatures, we need a way to > embed the necessary public keys. Existing appended signature schemes > in the Linux kernel use X.509 certificates, so allow certificates to > be

Re: [PATCH v2 07/21] grub-install: support embedding x509 certificates

2025-06-10 Thread sudhakar
iel Axtens Signed-off-by: Sudhakar Kuppusamy Reviewed-by: Stefan Berger Reviewed-by: Avnish Chouhan --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 2 ++ include/grub/util/install.h | 3 +++ util/grub-install-common.c | 19 ++- util/grub-mkimage.c

[PATCH v3 08/25] grub-install: support embedding x509 certificates

2025-06-10 Thread Sudhakar
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens Signed-off-by: Sudhakar Kuppusamy Reviewed-by: Stefan Berger Reviewed-by: Avnish Chouhan --- include/grub/kernel.h | 1 + include/grub/util/install.h | 3 +++ util/grub-install-common.c | 19 ++-

How to test grub-install from git tree without "make install" ?

2025-06-06 Thread Thomas Schmitt via Grub-devel
Hi, i made a hopefully harmless change to grub-install-common.c in order to avoid that backup files of /boot/grub/locale/*.mo get copied into the resulting ISO image of grub-mkrescue when more than one platform-target combination is configured. E.g. "x86_64-efi" together with "i38

Re: [PATCH v2 07/21] grub-install: support embedding x509 certificates

2025-05-28 Thread Daniel Kiper
> --- > grub-core/commands/pgp.c| 2 +- > include/grub/kernel.h | 2 ++ > include/grub/util/install.h | 3 +++ > util/grub-install-common.c | 19 ++- > util/grub-mkimage.c | 14 -- > util/mkimage.c | 33 +

Re: [PATCH] util/grub-install: Include raid5rec module for RAID 4 as well

2025-04-10 Thread Daniel Kiper
On Thu, Apr 10, 2025 at 10:55:02AM +0300, Egor Ignatov wrote: > RAID 4 requires the same recovery module as RAID 5. Extend the condition to > cover both RAID levels. > > Signed-off-by: Egor Ignatov Reviewed-by: Daniel Kiper Daniel ___ Grub-devel mail

[PATCH] util/grub-install: Include raid5rec module for RAID 4 as well

2025-04-10 Thread Egor Ignatov
RAID 4 requires the same recovery module as RAID 5. Extend the condition to cover both RAID levels. Signed-off-by: Egor Ignatov --- util/grub-install.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/grub-install.c b/util/grub-install.c index 7dc5657bb..060246589 100644

[PATCH v2 07/21] grub-install: support embedding x509 certificates

2025-03-26 Thread Sudhakar Kuppusamy
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens Signed-off-by: Sudhakar Kuppusamy Reviewed-by: Stefan Berger Reviewed-by: Avnish Chouhan --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 2 ++ include/grub/util/install.h | 3 +++ util/grub-install-comm

Re: [PATCH v1 07/21] grub-install: support embedding x509 certificates

2025-01-24 Thread Avnish Chouhan
char *outname, char *mods[], char *memdisk_path, char **pubkey_paths, size_t npubkeys, +char **x509key_paths, size_t nx509keys, char *config_path, const struct grub_ins

Re: [PATCH RESEND] grub-install: force journal draining to ensure data integrity

2025-01-21 Thread Michael Chang via Grub-devel
On Tue, Jan 21, 2025 at 07:41:03AM +0100, Pascal Hambourg wrote: > Le 21/01/2025 à 07:25, Michael Chang via Grub-devel a écrit : > > In XFS, the system would end up in unbootable state if an abrupt power > > off after grub-install is occuring. It can be easily reproduced with. &

Re: [PATCH RESEND] grub-install: force journal draining to ensure data integrity

2025-01-20 Thread Pascal Hambourg
Le 21/01/2025 à 07:25, Michael Chang via Grub-devel a écrit : In XFS, the system would end up in unbootable state if an abrupt power off after grub-install is occuring. It can be easily reproduced with. grub-install /dev/vda; reboot -f The grub error would show many different kinds of

[PATCH RESEND] grub-install: force journal draining to ensure data integrity

2025-01-20 Thread Michael Chang via Grub-devel
In XFS, the system would end up in unbootable state if an abrupt power off after grub-install is occuring. It can be easily reproduced with. grub-install /dev/vda; reboot -f The grub error would show many different kinds of corruption in filesystem and the problem boils down to incompleted

Re: [PATCH v1 07/21] grub-install: support embedding x509 certificates

2024-12-27 Thread Stefan Berger
all.h | 3 +++ util/grub-install-common.c | 19 ++- util/grub-mkimage.c | 14 -- util/mkimage.c | 33 +++-- 6 files changed, 67 insertions(+), 6 deletions(-) diff --git a/grub-core/commands/pgp.c b/grub-core/commands/p

[PATCH v1 07/21] grub-install: support embedding x509 certificates

2024-12-18 Thread Sudhakar Kuppusamy
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens Signed-off-by: Sudhakar Kuppusamy --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 2 ++ include/grub/util/install.h | 3 +++ util/grub-install-common.c | 19 ++- util/grub-mkimage.c

Re: [PATCH v1 14/15] grub-install: install on EFI if forced

2024-11-05 Thread Didier Spaier via Grub-devel
On 11/4/24 02:08, Neal Gompa wrote: > On Thu, Oct 31, 2024 at 3:43 PM Leo Sandoval wrote: >> >> From: Marta Lewandowska >> >> UEFI Secure Boot requires signed grub binaries to work, so grub- >> install should not be used. However, users who have Secure Boo

Re: [PATCH v1 14/15] grub-install: install on EFI if forced

2024-11-04 Thread Leo Sandoval
On Sun, Nov 3, 2024 at 7:09 PM Neal Gompa wrote: > On Thu, Oct 31, 2024 at 3:43 PM Leo Sandoval wrote: > > > > From: Marta Lewandowska > > > > UEFI Secure Boot requires signed grub binaries to work, so grub- > > install should not be used. However, users who

Re: [PATCH v1 11/15] grub-install: disable support for EFI platforms

2024-11-04 Thread Leo Sandoval
On Sun, Nov 3, 2024 at 7:08 PM Neal Gompa wrote: > > On Thu, Oct 31, 2024 at 3:43 PM Leo Sandoval wrote: > > > > From: Jan Hlavac > > > > For each platform, GRUB is shipped as a kernel image and a set of > > modules. These files are then used by the grub-inst

Re: [PATCH v1 14/15] grub-install: install on EFI if forced

2024-11-03 Thread Neal Gompa
On Thu, Oct 31, 2024 at 3:43 PM Leo Sandoval wrote: > > From: Marta Lewandowska > > UEFI Secure Boot requires signed grub binaries to work, so grub- > install should not be used. However, users who have Secure Boot > disabled and wish to use the command should not be prevented

Re: [PATCH v1 11/15] grub-install: disable support for EFI platforms

2024-11-03 Thread Neal Gompa
On Thu, Oct 31, 2024 at 3:43 PM Leo Sandoval wrote: > > From: Jan Hlavac > > For each platform, GRUB is shipped as a kernel image and a set of > modules. These files are then used by the grub-install utility to > install GRUB on a specific device. However, in order to support

[PATCH v1 11/15] grub-install: disable support for EFI platforms

2024-10-31 Thread Leo Sandoval
From: Jan Hlavac For each platform, GRUB is shipped as a kernel image and a set of modules. These files are then used by the grub-install utility to install GRUB on a specific device. However, in order to support UEFI Secure Boot, the resulting EFI binary must be signed by a recognized private

[PATCH v1 07/15] grub-install: Don't guess /boot/efi/ as HFS+ on ppc machines in grub-install

2024-10-31 Thread Leo Sandoval
From: Peter Jones This should never be trying this, and since we've consolidated the grubenv to always be on /boot/efi/EFI/fedora/, this code causes it to always make the wrong decision. Resolves: rhbz#1484474 Signed-off-by: Peter Jones --- util/grub-install.c | 12 +--- 1 file change

[PATCH v1 14/15] grub-install: install on EFI if forced

2024-10-31 Thread Leo Sandoval
From: Marta Lewandowska UEFI Secure Boot requires signed grub binaries to work, so grub- install should not be used. However, users who have Secure Boot disabled and wish to use the command should not be prevented from doing so if they invoke --force. fixes bz#1917213 / bz#2240994 Signed-off

Re: [PATCH] grub-install: Use `GRUB_DISTRIBUTOR` value as EFI boot option title

2024-02-08 Thread Daniel Kiper
On Thu, Feb 01, 2024 at 10:09:04AM +, Mate Kukri wrote: > We are going to be shipping something like this in Ubuntu as we would > like our boot entries to be called "Ubuntu" instead of "ubuntu". > > I wonder if other users of GRUB would find this naming approach > better, I could gate this behi

Re: [PATCH] grub-install: Use `GRUB_DISTRIBUTOR` value as EFI boot option title

2024-02-01 Thread Mate Kukri
We are going to be shipping something like this in Ubuntu as we would like our boot entries to be called "Ubuntu" instead of "ubuntu". I wonder if other users of GRUB would find this naming approach better, I could gate this behind a command line option if the patch is easier to accept that way.

[PATCH] grub-install: Use `GRUB_DISTRIBUTOR` value as EFI boot option title

2024-02-01 Thread Mate Kukri
- Allow entries to be called things like "Debian" and "Ubuntu". - If there is no `GRUB_DISTRIBUTOR` assume it is "GRUB". - When deleting previous boot options, allow matching against both the old "efi_distributor" value and the new "efi_title" one. Signed-off-by: Mate Kukri --- grub-core/osdep

Re: [PATCH] grub-install: Move platdir path canonicalization after files were copied to grubdir

2023-12-11 Thread Daniel Kiper
On Fri, Dec 08, 2023 at 04:57:55PM +, Mate Kukri wrote: > The previous grub-install patch delaying the copying of files caused a > regression when installing without an existing directory structure. > > This patch ensures that the platform directory actually exists by the > time

[PATCH] grub-install: Move platdir path canonicalization after files were copied to grubdir

2023-12-08 Thread Mate Kukri
The previous grub-install patch delaying the copying of files caused a regression when installing without an existing directory structure. This patch ensures that the platform directory actually exists by the time the code tries to canonicalize its filename. Signed-off-by: Mate Kukri --- util

Re: [PATCH v4] grub-install: Delay copying files to {grubdir, platdir} after install_device was validated.

2023-11-29 Thread Daniel Kiper
On Fri, Nov 24, 2023 at 08:32:57AM +, Mate Kukri wrote: > Previously grub-install copied modules to grubdir before doing any validation > on > the install_device. > > When grub-install was called with an invalid install_device, modules > were already copied to /boot befor

[PATCH v4] grub-install: Delay copying files to {grubdir, platdir} after install_device was validated.

2023-11-24 Thread Mate Kukri
Previously grub-install copied modules to grubdir before doing any validation on the install_device. When grub-install was called with an invalid install_device, modules were already copied to /boot before it found out and was forced to rely on atexit rollback. This patch delays copying the

Re: [PATCH v3] grub-install: Delay copying files to {grubdir, platdir} after install_device was validated.

2023-11-23 Thread Mate Kukri
Kiper wrote: > > On Wed, Nov 22, 2023 at 11:53:13AM +, Mate Kukri wrote: > > Previously grub-install copied modules to grubdir before doing any > > validation on > > the install_device. > > > > When grub-install was called with an invalid install_device,

Re: [PATCH v3] grub-install: Delay copying files to {grubdir, platdir} after install_device was validated.

2023-11-23 Thread Daniel Kiper
On Wed, Nov 22, 2023 at 11:53:13AM +, Mate Kukri wrote: > Previously grub-install copied modules to grubdir before doing any validation > on > the install_device. > > When grub-install was called with an invalid install_device, modules > were already copied to /boot befor

[PATCH v3] grub-install: Delay copying files to {grubdir, platdir} after install_device was validated.

2023-11-22 Thread Mate Kukri
Previously grub-install copied modules to grubdir before doing any validation on the install_device. When grub-install was called with an invalid install_device, modules were already copied to /boot before it found out and was forced to rely on atexit rollback. This patch delays copying the

Re: [PATCH v2] grub-install: Delay copying files to grubdir after install_device was validated.

2023-11-22 Thread Julian Andres Klode
On Wed, Nov 22, 2023 at 10:06:27AM +, Mate Kukri wrote: > Previously grub-install copied modules to grubdir before doing any validation > on > the install_device. > > When grub-install was called with an invalid install_device, modules > were already copied to /boot befor

[PATCH v2] grub-install: Delay copying files to grubdir after install_device was validated.

2023-11-22 Thread Mate Kukri
Previously grub-install copied modules to grubdir before doing any validation on the install_device. When grub-install was called with an invalid install_device, modules were already copied to /boot before it found out and was forced to rely on atexit rollback. This patch delays copying the

[PATCH] grub-install: Delay copying files to grubdir after install_device was validated.

2023-11-21 Thread Mate Kukri
Previously grub-install copied modules to grubdir before doing any validation on the install_device. When grub-install was called with an invalid install_device, modules were already copied to /boot before it found out and was forced to rely on atexit rollback. This patch delays copying the

Re: [PATCH v2 0/2] util/grub-install-common: Print usable grub-mkimage command

2023-09-26 Thread Daniel Kiper
On Fri, Sep 22, 2023 at 02:34:16PM -0500, Glenn Washburn wrote: > This fixes an issue where grub-install does not print a grub-mkimage > command, when running in verbose more, that can be run by grub-mkimage. > Specifically, --dtb and --sbat will not take empty strings as arguments. &g

[PATCH v2 2/2] util/grub-install-common: Print usable grub-mkimage command

2023-09-22 Thread Glenn Washburn
When grub-install is run with the verbose option, it will print a log message indicating the grub-mkimage command and arguments used. GRUB no longer calls the grub-mkimage binary internally, however the command logged is a command that if run should effectively be what grub-install used. However

[PATCH v2 0/2] util/grub-install-common: Print usable grub-mkimage command

2023-09-22 Thread Glenn Washburn
This fixes an issue where grub-install does not print a grub-mkimage command, when running in verbose more, that can be run by grub-mkimage. Specifically, --dtb and --sbat will not take empty strings as arguments. changes from v1: - Split into two patches to make changes more clear, no other

[PATCH v2 1/2] util/grub-install-common: Minor improvements to printing of grub-mkimage command

2023-09-22 Thread Glenn Washburn
if block. Signed-off-by: Glenn Washburn --- util/grub-install-common.c | 32 +++- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/util/grub-install-common.c b/util/grub-install-common.c index 52a29d1cb8e0..f9b9201c894e 100644 --- a/util/grub-install

Re: [PATCH] util/grub-install-common: Print usable grub-mkimage command

2023-09-02 Thread Daniel Kiper
On Fri, Sep 01, 2023 at 11:33:03PM -0500, Glenn Washburn wrote: > When grub-install is run with the verbose option, it will print a log > message indicating the grub-mkimage command and arguments used. > GRUB no longer calls the grub-mkimage binary internally, however the > command

[PATCH] util/grub-install-common: Print usable grub-mkimage command

2023-09-01 Thread Glenn Washburn
When grub-install is run with the verbose option, it will print a log message indicating the grub-mkimage command and arguments used. GRUB no longer calls the grub-mkimage binary internally, however the command logged is a command that if run should effectively be what grub-install used. However

Re: [PATCH] grub-install-common: Fix the key of the --core-compress option

2023-05-09 Thread Daniel Kiper
On Fri, May 05, 2023 at 02:04:28PM +0200, Ákos Nagy wrote: > Commit f23bc6510 ("Transform -C option to grub-mkstandalone to > --core-compress available in all grub-install flavours.") declared a new > long option for specifying the compression method to use for the core > i

[PATCH] grub-install-common: Fix the key of the --core-compress option

2023-05-05 Thread Ákos Nagy
Commit f23bc6510 ("Transform -C option to grub-mkstandalone to --core-compress available in all grub-install flavours.") declared a new long option for specifying the compression method to use for the core image. However, the option key has not been replaced in the parser function

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-12-11 Thread Steve McIntyre
On Sat, Dec 10, 2022 at 07:40:47AM +0300, программист некто wrote: >Hello. Sorry for long wait. > >>программист некто: could you please try these changes and report back? > >I tried the first patch with grub 2.06-7. Result: grub-install works without >error. Cool,

[programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-12-09 Thread программист некто
Hello. Sorry for long wait. >программист некто: could you please try these changes and report back? I tried the first patch with grub 2.06-7. Result: grub-install works without error. ___ Grub-devel mailing list Grub-devel@gnu.org ht

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-12-08 Thread Christian Hesse
Daniel Axtens on Sat, 2022/12/03 01:41: > Please try the following: > > diff --git a/grub-core/fs/f2fs.c b/grub-core/fs/f2fs.c > index df6beb544cbd..855e24618c2b 100644 > --- a/grub-core/fs/f2fs.c > +++ b/grub-core/fs/f2fs.c > @@ -650,7 +650,7 @@ get_blkaddr_from_nat_journal (struct grub_f2fs_dat

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-12-04 Thread программист некто
Certainly, I will try these changes. 03.12.2022, 20:44, "Steve McIntyre" : программист некто: could you please try these changes and report back? --Steve McIntyre, Cambridge, UK. st...@einval.com  Armed with "Valor": "Centurion" represents quality of Discipline,  Honor, Integrity and Loyalty. Now y

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-12-03 Thread Steve McIntyre
Hi Daniel! On Sat, Dec 03, 2022 at 01:41:51AM +1100, Daniel Axtens wrote: >Steve McIntyre writes: >> >> программист некто (in CC) reported this bug a few weeks back in >> Debian. Since I applied the bundle of filesystem bounds-checking fixes >> a few months back, he c

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-12-02 Thread Daniel Axtens
Steve McIntyre writes: > Hi all! > > программист некто (in CC) reported this bug a few weeks back in > Debian. Since I applied the bundle of filesystem bounds-checking fixes > a few months back, he can't run grub-install. He's done the work to > determine that the

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-11-28 Thread Robbie Harwood
Steve McIntyre writes: > Hi all! > > программист некто (in CC) reported this bug a few weeks back in > Debian. Since I applied the bundle of filesystem bounds-checking fixes > a few months back, he can't run grub-install. He's done the work to > determine that the

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-11-25 Thread Steve McIntyre
Hi Sudhakar! On Fri, Nov 25, 2022 at 10:52:39AM +0530, sudhakar wrote: >Hi Steve, > >It seems invalid Commit id which you reported. It should be >4bd9877f62166b7e369773ab92fe24a39f6515f8 >did you applied below patch and tested? Could you please confirm that. > >fs/f2fs: Do not read past the end of

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-11-24 Thread sudhakar
the bundle of filesystem bounds-checking fixes a few months back, he can't run grub-install. He's done the work to determine that the patch that breaks things for him is 2d014248d540c7e087934a94b6e7a2aa7fc2c704 fs/f2fs: Do not read past the end of nat journal entries The full thr

Re: [programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-11-24 Thread Daniel Kiper
Adding Daniel Axtens... On Tue, Nov 15, 2022 at 06:31:45PM +, Steve McIntyre wrote: > Hi all! > > программист некто (in CC) reported this bug a few weeks back in > Debian. Since I applied the bundle of filesystem bounds-checking fixes > a few months back, he can't run gru

[programmer11...@programist.ru: Bug#1021846: grub-install is broken since 2.06-3: error: unknown filesystem]

2022-11-15 Thread Steve McIntyre
Hi all! программист некто (in CC) reported this bug a few weeks back in Debian. Since I applied the bundle of filesystem bounds-checking fixes a few months back, he can't run grub-install. He's done the work to determine that the patch that breaks things

Re: [PATCH] grub-install: set point of no return for powerpc-ieee1275 install

2022-10-06 Thread Daniel Kiper
On Thu, Aug 25, 2022 at 02:05:01PM +0800, Michael Chang via Grub-devel wrote: > The point of no return is used to define a point where no change should > be reverted in a wake of fatal error that consequently aborts the > process. The powerpc-ieee1275 install apparently missed this point of no > re

[PATCH v3 2/2] grub-install: Add point of no return for IEEE1275 on powerpc

2022-09-05 Thread Ismael Luceno
Signed-off-by: Ismael Luceno --- util/grub-install.c | 1 + 1 file changed, 1 insertion(+) diff --git a/util/grub-install.c b/util/grub-install.c index da50bd58b73b..45f549c25867 100644 --- a/util/grub-install.c +++ b/util/grub-install.c @@ -1859,6 +1859,7 @@ main (int argc, char *argv[])

[PATCH v3 1/2] grub-install: Ensure a functional /dev/nvram

2022-09-05 Thread Ismael Luceno
This enables an early failure; for i386-ieee1275 and powerpc-ieee1275 on Linux, without /dev/nvram the system may be left in an unbootable state. Signed-off-by: Ismael Luceno --- util/grub-install.c | 24 1 file changed, 24 insertions(+) diff --git a/util/grub-install.c

Re: [PATCH v2 2/2] grub-install: Ensure a functional /dev/nvram

2022-09-05 Thread Michael Chang via Grub-devel
On Mon, Aug 29, 2022 at 04:36:25PM +0200, Ismael Luceno wrote: > This enables an early failure; for i386-ieee1275 and powerpc-ieee1275 on > Linux, without /dev/nvram the system may be left in an unbootable state. > > Signed-off-by: Ismael Luceno > --- > util/grub-install.c | 23 +

Re: [PATCH v2 1/2] grub-install: Add missing points of no return for IEEE1275 on i386/powerpc

2022-09-05 Thread Michael Chang via Grub-devel
On Mon, Aug 29, 2022 at 04:36:24PM +0200, Ismael Luceno wrote: > Signed-off-by: Ismael Luceno > --- > util/grub-install.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/util/grub-install.c b/util/grub-install.c > index 7b04bd3c534b..527b85e27aa7 100644 > --- a/util/grub-install.c > +

[PATCH v2 2/2] grub-install: Ensure a functional /dev/nvram

2022-08-29 Thread Ismael Luceno
This enables an early failure; for i386-ieee1275 and powerpc-ieee1275 on Linux, without /dev/nvram the system may be left in an unbootable state. Signed-off-by: Ismael Luceno --- util/grub-install.c | 23 +++ 1 file changed, 23 insertions(+) diff --git a/util/grub-install.c

[PATCH v2 1/2] grub-install: Add missing points of no return for IEEE1275 on i386/powerpc

2022-08-29 Thread Ismael Luceno
Signed-off-by: Ismael Luceno --- util/grub-install.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/util/grub-install.c b/util/grub-install.c index 7b04bd3c534b..527b85e27aa7 100644 --- a/util/grub-install.c +++ b/util/grub-install.c @@ -1835,6 +1835,7 @@ main (int argc, char *argv[])

[PATCH] grub-install: set point of no return for powerpc-ieee1275 install

2022-08-24 Thread Michael Chang via Grub-devel
The point of no return is used to define a point where no change should be reverted in a wake of fatal error that consequently aborts the process. The powerpc-ieee1275 install apparently missed this point of no return defintion that newly installed modules could be inadvertently reverted after succ

Re: [PATCH] grub-install: Allow to install to non-EFI ESP when --force

2022-04-27 Thread Daniel Kiper
if > U-Boot is built with ext4 support. In some situations a GRUB > installation on such a non-FAT ESP could be useful (e.g. a NTFS-based > USB disk that can dual boot a Windows installation media and a Linux > LiveCD). > > As this is advanced and implementation-dependent behavio

[PATCH] grub-install: Allow to install to non-EFI ESP when --force

2022-04-24 Thread Icenowy Zheng
such a non-FAT ESP could be useful (e.g. a NTFS-based USB disk that can dual boot a Windows installation media and a Linux LiveCD). As this is advanced and implementation-dependent behavior, let grub-install allow this kind of installation, but only when --force is specified. Signed-off-by: Ic

[PATCH v3 13/19] grub-install: support embedding x509 certificates

2022-04-21 Thread Daniel Axtens
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens Reviewed-by: Stefan Berger --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 3 ++- include/grub/util/install.h | 7 +-- util/grub-install-common.c | 22 +++- util/grub-mkimage.c

[PATCH 1/6] grub-install-common: Fix memory leak in copy_all()

2021-10-26 Thread Darren Kenny
The copy_all() function skips a section of code using continue, but fails to free the memory in srcf first, leaking it. Fixes: CID 314026 Signed-off-by: Darren Kenny --- util/grub-install-common.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/util/grub-install-common.c

Re: [PATCH v2 16/22] grub-install: support embedding x509 certificates

2021-07-12 Thread Stefan Berger
grub core image in the same way as PGP keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens Reviewed-by: Stefan Berger --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 3 ++- include/grub/util/install.h | 7 +-- util/grub-install-comm

[PATCH v2 16/22] grub-install: support embedding x509 certificates

2021-06-30 Thread Daniel Axtens
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 3 ++- include/grub/util/install.h | 7 +-- util/grub-install-common.c | 22 +++- util/grub-mkimage.c | 15 -- util

Re: [PATCH v6] grub-install: Add backup and restore

2021-06-01 Thread Daniel Kiper
ke parent atexit hooks from forks, which can mess up the > backup. > > This allows safer upgrades of MBR & modules, such that > modules/images/fonts/translations are consistent with MBR in case of > errors. For example accidental grub-install /dev/non-existent-disk > curren

[PATCH v6] grub-install: Add backup and restore

2021-06-01 Thread Dimitri John Ledkov
es/fonts/translations are consistent with MBR in case of errors. For example accidental grub-install /dev/non-existent-disk currently clobbers and upgrades modules in /boot/grub, despite not actually updating any MBR. This patch only handles backup and restore of files copied to /boot/grub. This patch

Re: [PATCHv5] grub-install: Add backup and restore

2021-05-28 Thread Daniel Kiper
s/images/fonts/translations are consistent with MBR in case of > errors. For example accidental grub-install /dev/non-existent-disk > currently clobbers and upgrades modules in /boot/grub, despite not > actually updating any MBR. > > This patch only handles backup and restore of fi

Re: [PATCHv5] grub-install: Add backup and restore

2021-05-25 Thread Daniel Kiper
Some older grub codebases > can invoke parent atexit hooks from forks, which can mess up the > backup. > > This allows safer upgrades of MBR & modules, such that > modules/images/fonts/translations are consistent with MBR in case of > errors. For example accidental grub-install

[PATCHv5] grub-install: Add backup and restore

2021-05-24 Thread Dimitri John Ledkov
uch that modules/images/fonts/translations are consistent with MBR in case of errors. For example accidental grub-install /dev/non-existent-disk currently clobbers and upgrades modules in /boot/grub, despite not actually updating any MBR. This patch only handles backup and restore of files copied

Re: [PATCH v4] grub-install: Add backup and restore

2021-05-18 Thread Daniel Kiper
ke parent atexit hooks from forks, which can mess up the > backup. > > This allows safer upgrades of MBR & modules, such that > modules/images/fonts/translations are consistent with MBR in case of > errors. For example accidental grub-install /dev/non-existent-disk > curren

[PATCH v4] grub-install: Add backup and restore

2021-05-12 Thread Dimitri John Ledkov
es/fonts/translations are consistent with MBR in case of errors. For example accidental grub-install /dev/non-existent-disk currently clobbers and upgrades modules in /boot/grub, despite not actually updating any MBR. This patch only handles backup and restore of files copied to /boot/grub. This patch

Re: [PATCH] grub-install: Add backup and restore

2021-05-12 Thread Dimitri John Ledkov
afer upgrades of MBR & modules, such that > > modules/images/fonts/translations are consistent with MBR in case of > > errors. For example accidental grub-install /dev/non-existent-disk > > currently clobbers and upgrades modules in /boot/grub, despite not > > actuall

Re: [PATCH] grub-install: Add backup and restore

2021-05-04 Thread Daniel Kiper
Some older grub codebases > can invoke parent atexit hooks from forks, which can mess up the > backup. > > This allows safer upgrades of MBR & modules, such that > modules/images/fonts/translations are consistent with MBR in case of > errors. For example accidental grub-install

Re: [PATCH] grub-install: Add backup and restore

2021-05-04 Thread Dimitri John Ledkov
nly invoked by the > > parent process and not any children forks. Some older grub codebases > > can invoke parent atexit hooks from forks, which can mess up the > > backup. > > > > This allows safer upgrades of MBR & modules, such that > > modules/images/fonts

Re: [PATCH] grub-install: Add backup and restore

2021-05-02 Thread Michael Chang via Grub-devel
> backup. > > This allows safer upgrades of MBR & modules, such that > modules/images/fonts/translations are consistent with MBR in case of > errors. For example accidental grub-install /dev/non-existent-disk > currently clobbers and upgrades modules in /boot/grub, despite not &

[PATCH] grub-install: Add backup and restore

2021-04-29 Thread Dimitri John Ledkov
es/fonts/translations are consistent with MBR in case of errors. For example accidental grub-install /dev/non-existent-disk currently clobbers and upgrades modules in /boot/grub, despite not actually updating any MBR. This increases peak disk-usage slightly, by requiring temporarily twice the disk

Re: [PATCHv2] grub-install: Add backup and restore

2021-04-21 Thread Daniel Kiper
/translations are consistent with MBR in case of > errors. For example accidental grub-install /dev/non-existent-disk > currently clobbers and upgrades modules in /boot/grub, despite not > actually updating any MBR. This increases peak disk-usage slightly, by > requiring temporarily twice

[PATCH 13/19] grub-install: support embedding x509 certificates

2021-03-30 Thread Daniel Axtens
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 3 ++- include/grub/util/install.h | 7 +-- util/grub-install-common.c | 22 +++- util/grub-mkimage.c | 15 -- util

[SECURITY PATCH 110/117] grub-install-common: Add --sbat option

2021-03-02 Thread Daniel Kiper
From: Dimitri John Ledkov Signed-off-by: Dimitri John Ledkov Reviewed-by: Daniel Kiper --- include/grub/util/install.h | 5 - util/grub-install-common.c | 12 ++-- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/include/grub/util/install.h b/include/grub/util

[SECURITY PATCH 057/117] util/grub-install: Fix NULL pointer dereferences

2021-03-02 Thread Daniel Kiper
Two grub_device_open() calls does not have associated NULL checks for returned values. Fix that and appease the Coverity. Fixes: CID 314583 Signed-off-by: Daniel Kiper Reviewed-by: Javier Martinez Canillas --- util/grub-install.c | 4 1 file changed, 4 insertions(+) diff --git a/util/gru

Re: [PATCHv2] grub-install: Add backup and restore

2020-12-09 Thread Dimitri John Ledkov
everything was successful. If on_exit is not > > > > available, the backup remains on disk for manual recovery. > > > > > > > > This allows safer upgrades of MBR & modules, such that > > > > modules/images/fonts/translations are consistent with MB

Re: [PATCHv2] grub-install: Add backup and restore

2020-12-08 Thread Michael Chang via Grub-devel
r manual recovery. > > > > > > This allows safer upgrades of MBR & modules, such that > > > modules/images/fonts/translations are consistent with MBR in case of > > > errors. For example accidental grub-install /dev/non-existent-disk > > > currentl

Re: [PATCHv2] grub-install: Add backup and restore

2020-12-07 Thread Dimitri John Ledkov
dules/images/fonts/translations are consistent with MBR in case of > > errors. For example accidental grub-install /dev/non-existent-disk > > currently clobbers and upgrades modules in /boot/grub, despite not > > actually updating any MBR. This increases peak disk-usage slightly, b

Re: [PATCHv2] grub-install: Add backup and restore

2020-12-07 Thread Michael Chang via Grub-devel
; remove the backup if everything was successful. If on_exit is not > available, the backup remains on disk for manual recovery. > > This allows safer upgrades of MBR & modules, such that > modules/images/fonts/translations are consistent with MBR in case of > errors. For example a

Re: [PATCHv2] grub-install: Add backup and restore

2020-12-07 Thread Colin Watson
On Mon, Dec 07, 2020 at 12:37:28PM +, Dimitri John Ledkov wrote: > Refactor clean_grub_dir to create a backup of all the files, instead > of just irrevocably removing them as the first action. If available, > register on_exit handle to restore the backup if any errors occur, or > remove the bac

[PATCHv2] grub-install: Add backup and restore

2020-12-07 Thread Dimitri John Ledkov
remains on disk for manual recovery. This allows safer upgrades of MBR & modules, such that modules/images/fonts/translations are consistent with MBR in case of errors. For example accidental grub-install /dev/non-existent-disk currently clobbers and upgrades modules in /boot/grub, despite

Re: [PATCH v2 01/18] docs/grub: grub-install is no longer a shell script

2020-11-18 Thread Daniel Kiper
On Wed, Oct 28, 2020 at 12:57:18PM +1100, Daniel Axtens wrote: > Since commit cd46aa6cefab in 2013, grub-install hasn't been a shell > script. The para doesn't really add that much, especially since it's > the user manual, so just drop it. > > Signed-off-by: Danie

[PATCH v2 13/18] grub-install: support embedding x509 certificates

2020-10-27 Thread Daniel Axtens
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 3 ++- include/grub/util/install.h | 7 +-- util/grub-install-common.c | 23 - util/grub-mkimage.c | 15 -- util

[PATCH v2 01/18] docs/grub: grub-install is no longer a shell script

2020-10-27 Thread Daniel Axtens
Since commit cd46aa6cefab in 2013, grub-install hasn't been a shell script. The para doesn't really add that much, especially since it's the user manual, so just drop it. Signed-off-by: Daniel Axtens --- docs/grub.texi | 7 --- 1 file changed, 7 deletions(-) diff --git a/d

Re: [PATCH 13/18] grub-install: support embedding x509 certificates

2020-10-11 Thread Daniel Axtens
> +case 'x': > + arguments->x509keys = xrealloc (arguments->x509keys, > + sizeof (arguments->x509keys[0]) > + * (arguments->nx509keys + 1)); > + arguments->pubkeys[arguments->nx509keys++] = xstrdup (arg); This shoul

[PATCH 13/18] grub-install: support embedding x509 certificates

2020-10-01 Thread Daniel Axtens
keys. Signed-off-by: Alastair D'Silva Signed-off-by: Daniel Axtens --- grub-core/commands/pgp.c| 2 +- include/grub/kernel.h | 3 ++- include/grub/util/install.h | 7 +-- util/grub-install-common.c | 23 - util/grub-mkimage.c | 15 -- util

[PATCH 01/18] docs/grub: grub-install is no longer a shell script

2020-10-01 Thread Daniel Axtens
Since commit cd46aa6cefab in 2013, grub-install hasn't been a shell script. The para doesn't really add that much, especially since it's the user manual, so just drop it. Signed-off-by: Daniel Axtens --- docs/grub.texi | 7 --- 1 file changed, 7 deletions(-) diff --git a/d

  1   2   3   4   5   >