You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Xiao Chen (JIRA)" <ji...@apache.org> on 2017/09/06 19:32:00 UTC
[jira] [Updated] (HDFS-12400) Provide a way for NN to drain the
local key cache before re-encryption
[ https://issues.apache.org/jira/browse/HDFS-12400?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Xiao Chen updated HDFS-12400:
-----------------------------
Attachment: HDFS-12400.01.patch
Added a fix for this head-banging bug....
Added a {{drain}} method to the {{@InterfaceAudience.Private}} KPCE. Updated the tests to call on the dfsadmin's provider, instead of the NN's provider. With the fix in test, {{TestReencryptionWithKMS}} fails without the drain in the NN.
{{TestReencryption}} still needs those {{flush}} to make sure the {{JavaKeyStoreProvider}} is rolled correctly, so the tests can pass reliably.
> Provide a way for NN to drain the local key cache before re-encryption
> ----------------------------------------------------------------------
>
> Key: HDFS-12400
> URL: https://issues.apache.org/jira/browse/HDFS-12400
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: encryption
> Affects Versions: 3.0.0-beta1
> Reporter: Xiao Chen
> Assignee: Xiao Chen
> Attachments: HDFS-12400.01.patch
>
>
> In HDFS-12359, a fix for the KMS ACLs required for re-encryption was done. As part of the fix, the following code is used to make sure the local provider cache in the NN is drained.
> {code:java}
> if (dir.getProvider() instanceof CryptoExtension) {
> ((CryptoExtension) dir.getProvider()).drain(keyName);
> }
> {code}
> This doesn't work, because the provider is {{KeyProviderCryptoExtension}} instead of {{CryptoExtension}} - the latter is composite of the former.
> Unfortunately unit test didn't catch this, because it conveniently rolled the from the NN's provider.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-help@hadoop.apache.org