grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] ntldr support


From: Christian Franke
Subject: Re: [PATCH] ntldr support
Date: Mon, 10 Aug 2009 23:00:09 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.21) Gecko/20090403 SeaMonkey/1.1.16

Vladimir 'phcoder' Serbinenko wrote:
grub4dos checks for ntldr as follows:
- file starts with 0xe9, 0x??, 0x01,
- first sector does not end with bootsector signature 0x55,0xaa,
- file size exceeds 0x30000.
For me it sounds like a heuristic. I would prefer to trust user rather
than introducing heuristics to check file type.

I agree that such a heuristic is not needed. Grub2 uses different commands for different loaders (which is good) and therefore there is no need to auto-detect the loader type.

But a simple health check (like in 'chainloader') would IMO make sense for any load command. For 'ntldr': check that the file size is reasonable and that code starts with a jmp instruction. Allow to override the check with '--force'.

--
Regards,
Christian Franke





reply via email to

[Prev in Thread] Current Thread [Next in Thread]