<div dir="ltr">+1 for all the points.<div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Aug 13, 2014 at 11:22 AM, Jeff Darcy <span dir="ltr">&lt;<a href="mailto:jdarcy@redhat.com" target="_blank">jdarcy@redhat.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="">&gt;             I.1 Generating the master volume key<br>
&gt;<br>
&gt;<br>
&gt; Master volume key should be generated by user on the trusted machine.<br>
&gt; Recommendations on master key generation provided at section 6.2 of<br>
&gt; the manpages [1]. Generating of master volume key is in user&#39;s<br>
&gt; competence.<br>
<br>
</div>That was fine for an initial implementation, but it&#39;s still the single<br>
largest obstacle to adoption of this feature.  Looking forward, we need<br>
to provide full CLI support for generating keys in the necessary format,<br>
specifying their location, etc.<br>
<div class=""><br>
&gt;            I.2 Location of the master volume key when mounting a<br>
&gt;            volume<br>
&gt;<br>
&gt;<br>
&gt; At mount time the crypt translator searches for a master volume key on<br>
&gt; the client machine at the location specified by the respective<br>
&gt; translator option. If there is no any key at the specified location,<br>
&gt; or the key at specified location is in improper format, then mount<br>
&gt; will fail. Otherwise, the crypt translator loads the key to its<br>
&gt; private memory data structures.<br>
&gt;<br>
&gt; Location of the master volume key can be specified at volume creation<br>
&gt; time (see option &quot;master-key&quot;, section 6.7 of the man pages [1]).<br>
&gt; However, this option can be overridden by user at mount time to<br>
&gt; specify another location, see section 7 of manpages [1], steps 6, 7,<br>
&gt; 8.<br>
<br>
</div>Again, we need to improve on this.  We should support this as a volume<br>
or mount option in its own right, not rely on the generic<br>
--xlator-option mechanism.  Adding options to mount.glusterfs isn&#39;t<br>
hard.  Alternatively, we could make this look like a volume option<br>
settable once through the CLI, even though the path is stored locally on<br>
the client.  Or we could provide a separate special-purpose<br>
command/script, which again only needs to be run once.  It would even be<br>
acceptable to treat the path to the key file (not its contents!) as a<br>
true volume option, stored on the servers.  Any of these would be better<br>
than requiring the user to understand our volfile format and<br>
construction so that they can add the necessary option by hand.<br>
<div class=""><br>
&gt;                II. Check graph of translators on your client machine<br>
&gt;                after mount!<br>
&gt;<br>
&gt;<br>
&gt; During mount your client machine receives configuration info from the<br>
&gt; non-trusted server. In particular, this info contains the graph of<br>
&gt; translators, which can be subjected to tampering, so that encryption<br>
&gt; won&#39;t be invoked for your volume at all. So it is highly important to<br>
&gt; verify this graph. After successful mount make sure that the graph of<br>
&gt; translators contains the crypt translator with proper options (see<br>
&gt; FAQ#1, section 11 of the manpages [1]).<br>
<br>
</div>It is important to verify the graph, but not by poking through log files<br>
and not without more information about what to look for.  So we got a<br>
volfile that includes the crypt translator, with some options.  The<br>
*code* should ensure that the master-key option has the value from the<br>
command line or local config, and not some other.  If we have to add<br>
special support for this in otherwise-generic graph initialization code,<br>
that&#39;s fine.<br>
<div class="HOEnZb"><div class="h5">_______________________________________________<br>
Gluster-devel mailing list<br>
<a href="mailto:Gluster-devel@gluster.org">Gluster-devel@gluster.org</a><br>
<a href="http://supercolony.gluster.org/mailman/listinfo/gluster-devel" target="_blank">http://supercolony.gluster.org/mailman/listinfo/gluster-devel</a><br>
</div></div></blockquote></div><br></div></div>