[ https://issues.apache.org/jira/browse/GUACAMOLE-613?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16587374#comment-16587374 ]
Alexey edited comment on GUACAMOLE-613 at 8/21/18 1:27 PM: ----------------------------------------------------------- RDP server can send to the client PDU named "*Save Session Info PDU*" in the field type INFOTYPE_LOGON [https://msdn.microsoft.com/en-us/library/cc240635.aspx] There are two versions. "Logon Info Version 1" and "Logon Info Version 2": [https://msdn.microsoft.com/en-us/library/cc240637.aspx] [https://msdn.microsoft.com/en-us/library/cc240638.aspx] Inside these structures _SessionId_ field exists. To make server send this PDU to the client, a PDU named "*Client Info PDU*" ([https://msdn.microsoft.com/en-us/library/cc240474.aspx]) should be sent with the flag inside "*Info Packet*" set to "*INFO_LOGONNOTIFY*". I am not an expert in FreeRDP, but looked into it, and there is some functions implemented named: {code:java} rdp_send_save_session_info rdp_recv_save_session_info rdp_recv_client_info rdp_send_client_info{code} I think it can be used. Field _settings->LogonNotify_ should be set to true and _update->SaveSessionInfo_ is called when PDU is received. was (Author: fadeev): RDP server can send to the client PDU named "*Save Session Info PDU*" in the field type INFOTYPE_LOGON [https://msdn.microsoft.com/en-us/library/cc240635.aspx] There are two versions. "Logon Info Version 1" and "Logon Info Version 2": [https://msdn.microsoft.com/en-us/library/cc240637.aspx] [https://msdn.microsoft.com/en-us/library/cc240638.aspx] Inside these structures _SessionId_ field exists. To make server send this PDU to the client, a PDU named "*Client Info PDU*" ([https://msdn.microsoft.com/en-us/library/cc240474.aspx]) should be sent with the flag inside "*Info Packet*" set to "*INFO_LOGONNOTIFY*". I am not an expert in FreeRDP, but looked into it, and there is some functions implemented named: {code:java} rdp_send_save_session_info rdp_recv_save_session_info rdp_recv_client_info rdp_send_client_info{code} I think it can be used. Field _settings->LogonNotify_ should be set to true. > Implement connect/reconnect to the specific session id. > ------------------------------------------------------- > > Key: GUACAMOLE-613 > URL: https://issues.apache.org/jira/browse/GUACAMOLE-613 > Project: Guacamole > Issue Type: Improvement > Components: guacamole > Affects Versions: 0.9.12-incubating > Environment: Guacamole 0.9.12 > Reporter: Alexey > Priority: Major > > *The problem is:* > on Terminal Servers it is possible to create several sessions for the same > user. When I reconnect, then server creates anoter session (second one) for > me. When I reconnect again, it creates third session. Reconnect again - it > returns to the first session... and so on... > I want to be reconnected to the same session. > *The solution:* > According to the rdp documentation (if I understood it correctly), it is > possible to connect to specific session id. > [https://msdn.microsoft.com/en-us/library/cc240445.aspx] > in the section [2.2.1.3.5 Client Cluster Data > (TS_UD_CS_CLUSTER)|https://msdn.microsoft.com/en-us/library/cc240514.aspx] is > described that it is possible _“to request a connection to a given session > identifier. ”._ Just need to pass RedirectedSessionID and set a flag > REDIRECTED_SESSIONID_FIELD_VALID > Quote: > _“RedirectedSessionID (4 bytes): A 32-bit unsigned integer._ > _If the REDIRECTED_SESSIONID_FIELD_VALID flag is set in the Flags field, then > the RedirectedSessionID field contains a valid session identifier to which > the client requests to connect"_ > -- This message was sent by Atlassian JIRA (v7.6.3#76005)