From: Jiaxin Wu <jiaxin.wu@intel.com>
To: edk2-devel@lists.01.org
Cc: Palmer Thomas <thomas.palmer@hpe.com>,
Long Qin <qin.long@intel.com>, Ye Ting <ting.ye@intel.com>,
Fu Siyuan <siyuan.fu@intel.com>
Subject: [staging/HTTPS-TLS][PATCH 2/2] NetworkPkg/TlsAuthConfigDxe: TlsCaCertificate variable attribute update
Date: Tue, 16 Aug 2016 15:19:57 +0800 [thread overview]
Message-ID: <1471331997-39972-3-git-send-email-jiaxin.wu@intel.com> (raw)
In-Reply-To: <1471331997-39972-1-git-send-email-jiaxin.wu@intel.com>
Remove the RT attribute for TlsCaCertificate variable protecting. If so,
we can treat this variable as security in certain case.
Cc: Palmer Thomas <thomas.palmer@hpe.com>
Cc: Long Qin <qin.long@intel.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiaxin Wu <jiaxin.wu@intel.com>
---
NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.c | 2 +-
NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.h | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.c b/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.c
index f265b42..1132cac 100644
--- a/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.c
+++ b/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.c
@@ -999,11 +999,11 @@ EnrollX509toVariable (
//
// Check if signature database entry has been already existed.
// If true, use EFI_VARIABLE_APPEND_WRITE attribute to append the
// new signature data to original variable
//
- Attr = EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_RUNTIME_ACCESS | EFI_VARIABLE_BOOTSERVICE_ACCESS;
+ Attr = TLS_AUTH_CONFIG_VAR_BASE_ATTR;
Status = gRT->GetVariable(
VariableName,
&gEfiTlsCaCertificateGuid,
NULL,
diff --git a/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.h b/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.h
index dea3cda..398f7b6 100644
--- a/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.h
+++ b/NetworkPkg/TlsAuthConfigDxe/TlsAuthConfigImpl.h
@@ -51,10 +51,12 @@ extern UINT8 TlsAuthConfigDxeStrings[];
extern UINT8 TlsAuthConfigVfrBin[];
#define TLS_AUTH_CONFIG_PRIVATE_DATA_SIGNATURE SIGNATURE_32 ('T', 'A', 'C', 'D')
#define TLS_AUTH_CONFIG_PRIVATE_FROM_THIS(a) CR (a, TLS_AUTH_CONFIG_PRIVATE_DATA, ConfigAccess, TLS_AUTH_CONFIG_PRIVATE_DATA_SIGNATURE)
+#define TLS_AUTH_CONFIG_VAR_BASE_ATTR (EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_BOOTSERVICE_ACCESS)
+
typedef struct _TLS_AUTH_CONFIG_PRIVATE_DATA TLS_AUTH_CONFIG_PRIVATE_DATA;
typedef struct _TLS_AUTH_CONFIG_FILE_CONTEXT TLS_AUTH_CONFIG_FILE_CONTEXT;
///
/// HII specific Vendor Device Path definition.
--
1.9.5.msysgit.1
next prev parent reply other threads:[~2016-08-16 7:20 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-16 7:19 [staging/HTTPS-TLS][PATCH 0/2] Readme.MD and TlsAuthConfigDxe update Jiaxin Wu
2016-08-16 7:19 ` [staging/HTTPS-TLS][PATCH 1/2] Readme.MD: Clarify the feature support scope Jiaxin Wu
2016-08-16 7:19 ` Jiaxin Wu [this message]
2016-08-16 7:47 ` [staging/HTTPS-TLS][PATCH 0/2] Readme.MD and TlsAuthConfigDxe update Ye, Ting
2016-08-16 16:27 ` Palmer, Thomas
2016-08-16 18:24 ` Samer El Haj Mahmoud
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1471331997-39972-3-git-send-email-jiaxin.wu@intel.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox