<html dir="ltr"><head></head><body style="text-align:left; direction:ltr;"><div>Hi,</div><div><br></div><div>El mié, 08-05-2019 a las 06:47 +0000, Victor Toso escribió:</div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>Hi,</pre><pre><br></pre><pre>On Mon, May 06, 2019 at 04:06:45PM +0200, Javier Celaya wrote:</pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>Hi</pre><pre>El lun, 06-05-2019 a las 10:37 +0000, Victor Toso escribió:</pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>Hi,</pre><pre>On Fri, May 03, 2019 at 06:52:00PM +0200, Javier Celaya wrote:</pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>A phodav server created with a NULL shared dir is valid andresults</pre><pre>in an error answer to all requests of the webdav channel,instead of</pre><pre>silently ignoring them.</pre><pre>This is better than just returning NULL</pre><pre>fromspice_session_get_webdav_server because:a) it crashes</pre><pre>channel_webdav.c:start_client.</pre></blockquote><pre><br></pre><pre>Can you give some steps on how to reproduce? I was trying withremote-</pre><pre>viewer on F29 guest earlier and couldn't.</pre></blockquote><pre><br></pre><pre>You cannot just try an existing client, this problem happened as we are</pre><pre>developing our new client for flexVDI. You will have to modify some of</pre><pre>the source code for remote-viewer to see it.</pre><pre>The thing is, if you do not set the shared-dir property of the</pre><pre>SpiceSession object, it default to the XDG public directory. This</pre><pre>happens if you do not pass the "shared-dir" command line option, for</pre><pre>instance. But how do I say "I do not want to share any directory with</pre><pre>the guest"?</pre></blockquote><pre><br></pre><pre>With remote-viewer, only when the user toggle 'Share folder' the</pre><pre>channel-webdav would connect, that is, you would see in the logs:</pre><pre><br></pre><pre> > GSpice-DEBUG: 05:55:47.703: ../src/spice-channel.c:2707 webdav-11:0: Open coroutine starting 0x55a774a10a90</pre><pre> > GSpice-DEBUG: 05:55:47.703: ../src/spice-channel.c:2544 webdav-11:0: Started background coroutine 0x55a774a100d0</pre><pre> > GSpice-DEBUG: 05:55:47.703: ../src/spice-session.c:2246 webdav-11:0: Using plain text, port 5900</pre><pre> > GSpice-DEBUG: 05:55:47.704: ../src/spice-session.c:2177 open host pasta.usersys.redhat.com:5900</pre><pre> > GSpice-DEBUG: 05:55:47.704: ../src/spice-session.c:2099 webdav-11:0: connecting 0x7f2c4bfffa40...</pre><pre> > GSpice-DEBUG: 05:55:47.729: ../src/spice-session.c:2083 webdav-11:0: connect ready</pre><pre> > GSpice-DEBUG: 05:55:47.730: ../src/spice-channel.c:1367 webdav-11:0: channel type 11 id 0 num common caps 1 num caps 0</pre><pre> > GSpice-DEBUG: 05:55:47.767: ../src/spice-channel.c:1391 webdav-11:0: Peer version: 2:2</pre><pre> > GSpice-DEBUG: 05:55:47.768: ../src/spice-channel.c:1947 webdav-11:0: spice_channel_recv_link_msg: 2 caps</pre><pre> > GSpice-DEBUG: 05:55:47.768: ../src/spice-channel.c:1961 webdav-11:0: got remote common caps:</pre><pre><br></pre><pre>virt-viewer-session has a bool property that's false by default,</pre><pre>for sharing the folder. When this turns true,</pre><pre>virt-viewer-session-spice would then spice_channel_connect() the</pre><pre>channel.</pre><pre><br></pre><pre>Does it make sense to your client to only connect to the</pre><pre>channel-webdav only if you want to share something?</pre><pre><br></pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>I can set the shared-dir property to a file, or a non- existing</pre><pre>directory, and the guest just complaints when I try to access</pre><pre>it through webdavd. However, this does not seem a good</pre><pre>solution...</pre><pre>Setting the property to NULL, on the other hand, seems a</pre><pre>reasonable value for "share nothing", but it makes</pre><pre>spice_session_get_webdav_server return NULL and start_client</pre><pre>crashes.</pre></blockquote><pre><br></pre><pre>I don't strong disagree that NULL is interesting to say "Nothing</pre><pre>to share" but if you have nothing to share, you might as well</pre><pre>ignore the channel? Similar is playback/record audio, in case you</pre><pre>don't have a sound card in your client you might as well ignored</pre><pre>it or if you don't have usb devices (i guess this is harder than</pre><pre>sound card!) you might ignore channel-usbredir too.</pre><pre><br></pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>Unless I missed something and there is some way of making</pre><pre>remote-viewer share nothing... then we can just use that way.</pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>b) even if it did not crash, access to the shared dir from the</pre><pre>guest would fail by timeout instead of immediately notifying of</pre><pre>an error.</pre></blockquote><pre><br></pre><pre>Is that on windows as guest?</pre></blockquote><pre><br></pre><pre>Yes, I tested it on Windows as guest. I tried to fix a) by just</pre><pre>returning early from start_client if spice_session_get_webdav_server</pre><pre>returned NULL, but then all requests made by spice-webdavd are silently</pre><pre>ignored. There is a webdav channel but no webdav server... so I imagine</pre><pre>spice-webdavd on Linux will get the same result.</pre></blockquote><pre><br></pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>I spent some time looking at the code, found small issue andadded a</pre><pre>checks on start_client(). Still, I don't see why weshould accept a</pre><pre>webdav server running on NULL instead of only ina valid folder but</pre><pre>I'm also interested in fixing (a) and (b) ifpossible.</pre></blockquote><pre><br></pre><pre>As I explained before (maybe that should go in the commit</pre><pre>message too) I wanted a way of sharing no directory at all.</pre><pre>Passing NULL as shared- dir property seems like a good value,</pre><pre>but you tell me if there is a better way.</pre><pre>Best regards</pre></blockquote><pre><br></pre><pre>Well, having the possibility of crash needs a fix either way but</pre><pre>let me know if what I said before works for you.</pre></blockquote><div><br></div><div>Not connecting the webdav channel works for us, thank you. The crash I mentioned should be fixed with the patch you sent recently.</div><div><br></div><div>Thanks for your help</div><div><br></div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre><br></pre><pre>Cheers,</pre><pre><br></pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>Cheers,</pre><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><pre>--- src/spice-session.c | 4 ---- 1 file changed, 4 deletions(-)</pre><pre>diff --git a/src/spice-session.c b/src/spice-session.cindex</pre><pre>04ba124..cbcd8c4 100644--- a/src/spice-session.c+++ b/src/spice-</pre><pre>session.c@@ -2813,10 +2813,6 @@ PhodavServer*</pre><pre>spice_session_get_webdav_server(SpiceSession *session) static</pre><pre>GMutex mutex; const gchar *shared_dir =</pre><pre>spice_session_get_shared_dir(session);- if (shared_dir == NULL)</pre><pre>{- SPICE_DEBUG("No shared dir set, not creating webdav</pre><pre>server");- return NULL;- } g_mutex_lock(&mutex); --</pre><pre>2.20.1</pre><pre>_______________________________________________Spice-devel mailing </pre><a href="mailto:listSpice-devel@lists.freedesktop.org"><pre>listSpice-devel@lists.freedesktop.org</pre></a><pre><br></pre><a href="https://lists.freedesktop.org/mailman/listinfo/spice-devel"><pre>https://lists.freedesktop.org/mailman/listinfo/spice-devel</pre></a><pre><br></pre></blockquote></blockquote><pre>-- </pre><pre><br></pre><pre><br></pre><pre><br></pre><pre><br></pre><pre> </pre><pre><br></pre><pre><br></pre><pre><br></pre><pre><br></pre><pre><br></pre><pre> </pre><pre> </pre><pre> </pre><pre> </pre><pre> Javier Celaya Alastrué</pre><pre> </pre><pre> Chief Technology Officer</pre><pre> </pre><pre> </pre><pre> </pre><pre> </pre><pre> </pre><a href="mailto:javier.celaya@flexvdi.com"><pre>javier.celaya@flexvdi.com</pre></a><pre><br></pre><pre> </pre><pre> </pre><pre> </pre><pre> +34696969959 </pre><pre> </pre><pre> </pre><pre> j_celaya</pre><pre> </pre><pre> </pre><pre> </pre><pre> Legal Information and Privacy Policy</pre><pre> </pre><pre> </pre><pre> </pre><pre> </pre><pre> </pre><pre> Política de confidencialidad</pre><pre> Este mensaje y los ficheros anexos son confidenciales dirigiéndose exclusivamente al destinatario mencionado en el encabezamiento. Si usted ha recibido este correo por error, tenga la amabilidad de eliminarlo de su sistema y no divulgar el contenido a terceros. Los datos personales facilitados por usted o por terceros serán tratados por FLEXIBLE SOFTWARE SOLUTIONS S.L.U. con la finalidad de gestionar y mantener los contactos y relaciones que se produzcan como consecuencia de la relación que mantiene con FLEXIBLE SOFTWARE SOLUTIONS S.L.U. Normalmente, la base jurídica que legitima este tratamiento, será su consentimiento, el interés legítimo o la necesidad para gestionar una relación contractual o similar. El plazo de conservación de sus datos vendrá determinado por la relación que mantiene con nosotros. Para más información al respecto, o para ejercer sus derechos de acceso, rectificación, supresión, oposición, limitación o portabilidad, dirija una comunicación por escrito a FLEXIBLE SOFTWARE SOLUTIONS S.L.U: Avenida de Ranillas 1D, Planta 3, Oficina 3G, Zaragoza o al correo electrónico </pre><a href="mailto:pdo@flexvdi.com"><pre>pdo@flexvdi.com</pre></a><pre>. En caso de considerar vulnerado su derecho a la protección de datos personales, podrá interponer una reclamación ante la Agencia Española de Protección de Datos (</pre><a href="http://www.agpd.es"><pre>www.agpd.es</pre></a><pre>). </pre><pre> </pre><pre> </pre><pre><br></pre></blockquote></blockquote><div><span><pre>-- <br></pre>
<br>
<br>
<table id="sig" width="480" cellspacing="0" cellpadding="0" border-spacing="0" style="width:480px;margin:0;padding:0;"><tbody><tr><td text-align="right" style="border-right:2px solid #4a4b4a;padding-right:10px;" valign="top">
<p style="padding: 0px; text-align: right;">
<a href="http://www.flexvdi.com" title="flexVDI"><img src="https://www.flexvdi.com/signature/logo.flexvdi.png" moz-do-not-send="true" alt="flexVDI" border="0" height="45" width="151">
</a>
</p>
<p style="padding: 5px 10px 0px 0px; font-size: 15px; font-weight: bold; color: rgb(62, 93, 107); line-height: 17px; height: 17px; text-align: right;">
<span style="float:right">Javier Celaya Alastrué</span>
</p>
<p style="padding: 0px 10px 0px 0px; font-size: 13px; font-style: italic; color: rgb(0, 161, 193); line-height: 17px; height: 17px; text-align: right;">Chief Technology Officer</p>
</td>
<td style="padding-left:18px;display:block;">
<p style="padding: 5px 0px 0px;">
<img src="https://flexvdi.com/signature/mail.png" moz-do-not-send="true" style="margin:1px 7px 0 0;" alt="email" align="left" height="17" width="17">
<a href="mailto:javier.celaya@flexvdi.com" style="font-size:14px;color:#727272;line-height:17px;height:17px;">javier.celaya@flexvdi.com</a>
</p>
<p style="padding: 5px 0px 0px;">
<img src="https://flexvdi.com/signature/phone.png" moz-do-not-send="true" style="margin:0 7px 0 0;" alt="Phone" align="left" height="17" width="17">
<span style="font-size:14px;color:#727272;line-height:17px;height:17px;">+34696969959</span>
</p>
<p style="padding: 5px 0px 0px;"> <img src="https://flexvdi.com/signature/skype.png" moz-do-not-send="true" style="margin:0 7px 0 0;" alt="Skype" align="left" height="17" width="17">
<span style="font-size:14px;color:#727272;line-height:17px;height:17px;">j_celaya</span>
</p>
<p style="padding: 5px 0px 0px;">
<img src="https://flexvdi.com/signature/legal.png" moz-do-not-send="true" style="margin:0 7px 0 0;" alt="Legal" align="left" height="17" width="17">
<a href="https://flexvdi.com/es/legal" style="font-size:14px;font-style:italic;color:#727272;line-height:17px;height:17px;">Legal Information and Privacy Policy</a>
</p>
</td>
</tr>
<tr>
<td colspan="2" height="300">
<p style="font-family:Helvetica,Arial;font-size:14px;font-style:italic;color:#313131;text-align: center; font-weight: bold">Política de confidencialidad</p>
<p style="font-family:Helvetica,Arial;font-size:10px;font-style:italic;color:#313131;text-align: justify">Este mensaje y los ficheros anexos son confidenciales dirigiéndose exclusivamente al destinatario mencionado en el encabezamiento. Si usted ha recibido este correo por error, tenga la amabilidad de eliminarlo de su sistema y no divulgar el contenido a terceros. Los datos personales facilitados por usted o por terceros serán tratados por FLEXIBLE SOFTWARE SOLUTIONS S.L.U. con la finalidad de gestionar y mantener los contactos y relaciones que se produzcan como consecuencia de la relación que mantiene con FLEXIBLE SOFTWARE SOLUTIONS S.L.U. Normalmente, la base jurídica que legitima este tratamiento, será su consentimiento, el interés legítimo o la necesidad para gestionar una relación contractual o similar. El plazo de conservación de sus datos vendrá determinado por la relación que mantiene con nosotros. Para más información al respecto, o para ejercer sus derechos de acceso, rectificación, supresión, oposición, limitación o portabilidad, dirija una comunicación por escrito a FLEXIBLE SOFTWARE SOLUTIONS S.L.U: Avenida de Ranillas 1D, Planta 3, Oficina 3G, Zaragoza o al correo electrónico <a href="mailto:pdo@flexvdi.com" style="color:#313131">pdo@flexvdi.com</a>. En caso de considerar vulnerado su derecho a la protección de datos personales, podrá interponer una reclamación ante la Agencia Española de Protección de Datos (<a href="http://www.agpd.es" style="color:#313131">www.agpd.es</a>). </p>
</td>
</tr>
</tbody></table></span></div></body></html>