You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@guacamole.apache.org by Amarjeet Singh <am...@gmail.com> on 2017/11/10 12:59:57 UTC

Re: Virtual or Dyanmic Channels support

I am asking about support of Static Virtual Channels in Guacamole?

How can we configure support of more Static virtual channels in Guacamole ?

Regards,
Amarjeet Singh

On Sat, Sep 9, 2017 at 8:54 PM, vnick <vn...@apache.org> wrote:

> Amarjeet Singh wrote
> > Hi Team,
> >
> > Do Guacamole support Virtual or Dyanmic channels ?
>
> I'm not sure what you mean by this?  Can you describe what you're trying to
> do?
>
> -Nick
>
>
>
> --
> Sent from: http://apache-guacamole-incubating-users.2363388.n4.nabble.com/
>

Re: Virtual or Dyanmic Channels support

Posted by Amarjeet Singh <am...@gmail.com>.
Hi Mike,

I really appreciate the guidance you have provided me which helped me alot.

Now, it's working Below is the handling I have done :-

client.onpipe = function(input_stream, mimetype, name) {
>
> if (name == "hyprint") {
>
> reader = new Guacamole.ArrayBufferReader(input_stream);
> reader.ondata = function(buffer) {
> var data = new Int16Array(buffer)
> console.log(buffer);
> var str = new Uint8Array(buffer);
> var rdpdata = str.slice(0,10);
> console.log(rdpdata);
> }


Thanks Mike. Have a Great Day !! :)


Regards,
Amarjeet Singh

On Sun, Nov 12, 2017 at 3:54 AM, Mike Jumper <mi...@guac-dev.org>
wrote:

> On Sat, Nov 11, 2017 at 4:51 AM, Amarjeet Singh <am...@gmail.com>
> wrote:
>
>> ...
>>>
>>> *Nov 11 07:46:04 localhost guacd[7887]: Inbound half of channel
>>> "hyprint" connected.*
>>
>>
> This is not an error, but an informative message that the inbound pipe
> stream (the pipe from the browser to the server) for your channel has been
> connected. It is being logged at the wrong log level, but is not an error.
>
>
>> When I am printing the document on server side using this module. i am
>> not receiving any data?
>>
>> client.onpipe = function(input_stream, mimetype, name) {
>>>
>>> reader = new Guacamole.StringReader(input_stream);
>>> reader.ontext = function(text) {
>>> // Handle input here
>>> };
>>>
>>
>>
> What makes you think you're not receiving any data? The example code
> you've provided here is explicitly not handling any data (it has
> placeholder comments where the necessary code would need to go). Assuming
> you're using this code as-is, you would have no indication regarding
> whether data is being received or not. Received data would be silently
> discarded.
>
> - Mike
>
>

Re: Virtual or Dyanmic Channels support

Posted by Mike Jumper <mi...@guac-dev.org>.
On Sat, Nov 11, 2017 at 4:51 AM, Amarjeet Singh <am...@gmail.com>
wrote:

> ...
>>
>> *Nov 11 07:46:04 localhost guacd[7887]: Inbound half of channel "hyprint"
>> connected.*
>
>
This is not an error, but an informative message that the inbound pipe
stream (the pipe from the browser to the server) for your channel has been
connected. It is being logged at the wrong log level, but is not an error.


> When I am printing the document on server side using this module. i am not
> receiving any data?
>
> client.onpipe = function(input_stream, mimetype, name) {
>>
>> reader = new Guacamole.StringReader(input_stream);
>> reader.ontext = function(text) {
>> // Handle input here
>> };
>>
>
>
What makes you think you're not receiving any data? The example code you've
provided here is explicitly not handling any data (it has placeholder
comments where the necessary code would need to go). Assuming you're using
this code as-is, you would have no indication regarding whether data is
being received or not. Received data would be silently discarded.

- Mike

Re: Virtual or Dyanmic Channels support

Posted by Amarjeet Singh <am...@gmail.com>.
Hi Mike,

I read the documents and I am able to connect the hyprint module but there
is an error in guacd  which is as follows :-

Nov 11 07:45:59 localhost guacd[7887]: Loading keymap "en-us-qwerty"
>
> *Nov 11 07:45:59 localhost guacd[7887]: Created static channel
> "hyprint"...Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Created
> static channel "hyprint"...*
> Nov 11 07:45:59 localhost guacd[7887]: guacsnd connected.
> *Nov 11 07:45:59 localhost guacd[7887]: Static channel "hyprint"
> connected.*
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011guacsnd connected.
> *Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Static channel
> "hyprint" connected.*
> Nov 11 07:45:59 localhost guacd[7887]: guacdr connected.
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011guacdr connected.
> Nov 11 07:45:59 localhost guacd[7887]: Connected to RDPDR 1.12 as client
> 0x0005
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Connected to RDPDR
> 1.12 as client 0x0005
> Nov 11 07:45:59 localhost guacd[7887]: Ignoring server capability set
> type=0x0001, length=44
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0001, length=44
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0002, length=8
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0003, length=8
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0004, length=8
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0005, length=8
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Sending
> capabilities...
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Capabilities sent.
> Nov 11 07:45:59 localhost guacd: guacd[7887]: INFO:#011Client ID confirmed
> Nov 11 07:45:59 localhost guacd[7887]: Ignoring server capability set
> type=0x0002, length=8
> Nov 11 07:45:59 localhost guacd[7887]: Ignoring server capability set
> type=0x0003, length=8
> Nov 11 07:45:59 localhost guacd[7887]: Ignoring server capability set
> type=0x0004, length=8
> Nov 11 07:45:59 localhost guacd[7887]: Ignoring server capability set
> type=0x0005, length=8
> Nov 11 07:45:59 localhost guacd[7887]: Sending capabilities...
> Nov 11 07:45:59 localhost guacd[7887]: Capabilities sent.
> Nov 11 07:45:59 localhost guacd[7887]: Client ID confirmed
> Nov 11 07:46:00 localhost guacd[7887]: Connected to RDPDR 1.12 as client
> 0x0003
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Connected to RDPDR
> 1.12 as client 0x0003
> Nov 11 07:46:00 localhost guacd[7887]: Ignoring server capability set
> type=0x0001, length=44
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0001, length=44
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0002, length=8
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0003, length=8
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0004, length=8
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Ignoring server
> capability set type=0x0005, length=8
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Sending
> capabilities...
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Capabilities sent.
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Client ID confirmed
> Nov 11 07:46:00 localhost guacd[7887]: Ignoring server capability set
> type=0x0002, length=8
> Nov 11 07:46:00 localhost guacd[7887]: Ignoring server capability set
> type=0x0003, length=8
> Nov 11 07:46:00 localhost guacd[7887]: Ignoring server capability set
> type=0x0004, length=8
> Nov 11 07:46:00 localhost guacd[7887]: Ignoring server capability set
> type=0x0005, length=8
> Nov 11 07:46:00 localhost guacd[7887]: Sending capabilities...
> Nov 11 07:46:00 localhost guacd[7887]: Capabilities sent.
> Nov 11 07:46:00 localhost guacd[7887]: Client ID confirmed
> Nov 11 07:46:00 localhost guacd[7887]: User logged on
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011User logged on
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Sending printer
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Registered device 0
> (Guacamole Printer)
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Sending filesystem
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Registered device 1
> (Guacamole Filesystem)
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011All supported
> devices sent.
> Nov 11 07:46:00 localhost guacd[7887]: Sending printer
> Nov 11 07:46:00 localhost guacd[7887]: Registered device 0 (Guacamole
> Printer)
> Nov 11 07:46:00 localhost guacd[7887]: Sending filesystem
> Nov 11 07:46:00 localhost guacd[7887]: Registered device 1 (Guacamole
> Filesystem)
> Nov 11 07:46:00 localhost guacd[7887]: All supported devices sent.
> Nov 11 07:46:00 localhost guacd[7887]: Device 0 (Guacamole Printer)
> connected successfully
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Device 0 (Guacamole
> Printer) connected successfully
> Nov 11 07:46:00 localhost guacd: guacd[7887]: INFO:#011Device 1 (Guacamole
> Filesystem) connected successfully
> Nov 11 07:46:00 localhost guacd[7887]: Device 1 (Guacamole Filesystem)
> connected successfully
>
> *Nov 11 07:46:04 localhost guacd[7887]: Inbound half of channel "hyprint"
> connected.Nov 11 07:46:04 localhost guacd: guacd[7887]: ERROR:#011Inbound
> half of channel "hyprint" connected.*


What does this mean ?


When I am printing the document on server side using this module. i am not
receiving any data?

client.onpipe = function(input_stream, mimetype, name) {
>
> reader = new Guacamole.StringReader(input_stream);
> reader.ontext = function(text) {
> // Handle input here
> };
>
>     // If you wish to send output as well, establish another pipe like this
> var output_stream = client.createPipeStream("application/octet-stream",
> name);
> writer = new Guacamole.StringWriter(output_stream);
>
> // You can now send messages with writer.sendText()
> // You can now send messages with writer.sendText()
>
> };



Help me with the above.

Thanks and Regards,
Amarjeet Singh


On Sat, Nov 11, 2017 at 2:28 AM, Mike Jumper <mi...@guac-dev.org>
wrote:

> On Fri, Nov 10, 2017 at 12:52 PM, Amarjeet Singh <am...@gmail.com>
> wrote:
>
>> Yes, There is a module which will be running on server side for Printing
>> ( instead of using Guacamole Printer which changes name  for every session
>> ) name=hyprint.
>>
>>
> You can expose arbitrary static virtual channels to JavaScript using the
> "static-channels" parameter provided by Guacamole's RDP support:
>
> http://guacamole.incubator.apache.org/doc/gug/configuring-guacamole.html#
> rdp-device-redirection
>
> The parameter accepts a comma-separated list of static channel names to
> open and expose as pipe streams. For each SVC which is successfully handled
> within RDP, Guacamole will open an outbound pipe with the name of the
> static channel, which will trigger the "onpipe" handler of Guacamole.Client:
>
> http://guacamole.incubator.apache.org/doc/guacamole-
> common-js/Guacamole.Client.html#event:onpipe
>
> You can then deal with the inbound stream however you see fit. If
> JavaScript needs to communicate back in the other direction, it should
> respond by opening another pipe with the same name:
>
> http://guacamole.incubator.apache.org/doc/guacamole-
> common-js/Guacamole.Client.html#createPipeStream
>
> - Mike
>
>

Re: Virtual or Dyanmic Channels support

Posted by Mike Jumper <mi...@guac-dev.org>.
On Fri, Nov 10, 2017 at 12:52 PM, Amarjeet Singh <am...@gmail.com>
wrote:

> Yes, There is a module which will be running on server side for Printing (
> instead of using Guacamole Printer which changes name  for every session )
> name=hyprint.
>
>
You can expose arbitrary static virtual channels to JavaScript using the
"static-channels" parameter provided by Guacamole's RDP support:

http://guacamole.incubator.apache.org/doc/gug/configuring-guacamole.html#rdp-device-redirection

The parameter accepts a comma-separated list of static channel names to
open and expose as pipe streams. For each SVC which is successfully handled
within RDP, Guacamole will open an outbound pipe with the name of the
static channel, which will trigger the "onpipe" handler of Guacamole.Client:

http://guacamole.incubator.apache.org/doc/guacamole-common-js/Guacamole.Client.html#event:onpipe

You can then deal with the inbound stream however you see fit. If
JavaScript needs to communicate back in the other direction, it should
respond by opening another pipe with the same name:

http://guacamole.incubator.apache.org/doc/guacamole-common-js/Guacamole.Client.html#createPipeStream

- Mike

Re: Virtual or Dyanmic Channels support

Posted by Amarjeet Singh <am...@gmail.com>.
Yes, There is a module which will be running on server side for Printing (
instead of using Guacamole Printer which changes name  for every session )
name=hyprint.

On Sat, Nov 11, 2017 at 1:47 AM, Mike Jumper <mi...@guac-dev.org>
wrote:

> On Fri, Nov 10, 2017 at 12:11 PM, Amarjeet Singh <am...@gmail.com>
> wrote:
>
>> Static Virtual channels in RDP which is of 7 character and RDP supports
>> 31 static virtual channels.
>> That is what I am talking about.
>>
>>
> So, just arbitrary static virtual channels? Do you have some application
> which will be running under RDP which will be leveraging your own SVC, and
> which you want the JavaScript side of Guacamole to communicate with? Can
> you elaborate on the nature of the SVC in your case?
>
> - Mike
>
>

Re: Virtual or Dyanmic Channels support

Posted by Mike Jumper <mi...@guac-dev.org>.
On Fri, Nov 10, 2017 at 12:11 PM, Amarjeet Singh <am...@gmail.com>
wrote:

> Static Virtual channels in RDP which is of 7 character and RDP supports 31
> static virtual channels.
> That is what I am talking about.
>
>
So, just arbitrary static virtual channels? Do you have some application
which will be running under RDP which will be leveraging your own SVC, and
which you want the JavaScript side of Guacamole to communicate with? Can
you elaborate on the nature of the SVC in your case?

- Mike

Re: Virtual or Dyanmic Channels support

Posted by Amarjeet Singh <am...@gmail.com>.
Static Virtual channels in RDP which is of 7 character and RDP supports 31
static virtual channels.
That is what I am talking about.

On Sat, Nov 11, 2017 at 1:34 AM, Mike Jumper <mi...@guac-dev.org>
wrote:

> On Fri, Nov 10, 2017 at 4:59 AM, Amarjeet Singh <am...@gmail.com>
> wrote:
>
>> I am asking about support of Static Virtual Channels in Guacamole?
>>
>> How can we configure support of more Static virtual channels in Guacamole
>> ?
>>
>>
> Can you be more specific? What channels?
>
> - Mike
>
>

Re: Virtual or Dyanmic Channels support

Posted by Mike Jumper <mi...@guac-dev.org>.
On Fri, Nov 10, 2017 at 4:59 AM, Amarjeet Singh <am...@gmail.com>
wrote:

> I am asking about support of Static Virtual Channels in Guacamole?
>
> How can we configure support of more Static virtual channels in Guacamole ?
>
>
Can you be more specific? What channels?

- Mike