From: Heinrich Schuchardt Date: Sat, 9 Jan 2021 01:09:44 +0000 (+0100) Subject: tools: efivar.py should check GUID when deleting X-Git-Url: http://git.dujemihanovic.xyz/login.html?a=commitdiff_plain;h=33abdb98367592d6074639d6b076076d92319f82;p=u-boot.git tools: efivar.py should check GUID when deleting When deleting a variable we must check that the GUID provided by the user matches the GUID of the variable. Signed-off-by: Heinrich Schuchardt Reviewed-by: Paulo Alcantara (SUSE) --- diff --git a/tools/efivar.py b/tools/efivar.py index a02b09d46a..29eb90a235 100755 --- a/tools/efivar.py +++ b/tools/efivar.py @@ -149,7 +149,7 @@ class EfiVariableStore: offs = 0 while offs < len(self.ents): var, loffs = self._next_var(offs) - if var.name == name and str(var.guid): + if var.name == name and str(var.guid) == guid: if var.attrs != attrs: print("err: attributes don't match") exit(1)