WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Xen

xen-devel

[Top] [All Lists]

Re: [Xen-devel] [PATCH] Add password support to pygrub for GRUB bootload

To: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] Add password support to pygrub for GRUB bootloader
From: Michal Novotny <minovotn@xxxxxxxxxx>
Date: 2009年8月21日 15:44:53 +0200
Delivery-date: 2009年8月21日 06:45:01 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4A8E7483.1050001@xxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <4A8D658D.1070406@xxxxxxxxxx> <4A8E7483.1050001@xxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.22 (X11/20090609)
Hi,
this patch (applied as http://xenbits.xensource.com/xen-unstable.hg?rev/8f783adc0ee3 , c/s 20099) introduced a problem for Itanium systems using LiloConf. This patch is the fix for elilo. Since I am unable to find information whether eLilo supports password protection or not, this patch makes the entry and command-line editing on IA64 systems as if no patch with c/s 20099 was applied. Also, this version changes the exception trapping from KeyError to every exception because of pyGrub would return no result and tools would complain about that having exception instead of providing data...
Michal
Signed-off-by: Michal Novotny <minovotn@xxxxxxxxxx>
Michal Novotny wrote:
Hi,
this is the patch to add password support to pygrub for GRUB bootloader. It basically checks for the presence of password line in grub.conf of the guest image and if this line is present, it supports both clear text and md5 versions of the password. Editing the grub entries and command-line are disabled when some password is set in domain's grub.conf file but the password was not entered yet. Also, new option to press 'p' in interactive pygrub has been added to allow entering the grub password. It's been tested on x86_64 with PV guests and was working fine. Also, the countdown has been stopped after key was pressed, ie. the user is probably editing the boot configuration.
Michal
Signed-off-by: Michal Novotny <minovotn@xxxxxxxxxx>
------------------------------------------------------------------------
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
------------------------------------------------------------------------
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
diff -r 7dad2e23bf89 tools/pygrub/src/GrubConf.py
--- a/tools/pygrub/src/GrubConf.py Thu Aug 20 22:26:16 2009 +0100
+++ b/tools/pygrub/src/GrubConf.py Fri Aug 21 15:41:27 2009 +0200
@@ -219,7 +219,7 @@ class GrubConfigFile(object):
 try:
 getattr(self, self.commands['password'])
 return True
- except KeyError, e:
+ except:
 return False
 
 def checkPassword(self, password):
diff -r 7dad2e23bf89 tools/pygrub/src/LiloConf.py
--- a/tools/pygrub/src/LiloConf.py Thu Aug 20 22:26:16 2009 +0100
+++ b/tools/pygrub/src/LiloConf.py Fri Aug 21 15:41:27 2009 +0200
@@ -138,6 +138,12 @@ class LiloConfigFile(object):
 if len(img) > 0:
 self.add_image(LiloImage(img, path))
 
+ def hasPassword(self):
+ return False
+
+ def hasPasswordAccess(self):
+ return True
+
 def add_image(self, image):
 self.images.append(image)
 
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
Previous by Date: [Xen-community] Xen.org Community Weekly Update , Stephen Spector
Next by Date: Re: [Xen-devel] [PATCH]: Implement bzip2 and LZMA loaders / fixed patch for Xen 3.4.1 , Pasi Kärkkäinen
Previous by Thread: Re: [Xen-devel] [PATCH] Add password support to pygrub for GRUB bootloader , Michal Novotny
Next by Thread: [Xen-devel] [PATCH] Fix testcase '11_block_attach_shared_dom0' for up-to date linux kernels , Andreas Florath
Indexes: [Date] [Thread] [Top] [All Lists]

Copyright ©, Citrix Systems Inc. All rights reserved. Legal and Privacy
Citrix This site is hosted by Citrix

AltStyle によって変換されたページ (->オリジナル) /