Skip to content

Commit

Permalink
fix for interactive desktop analysis using rdp
Browse files Browse the repository at this point in the history
  • Loading branch information
Kevin Rohan committed Dec 2, 2024
1 parent 3427c26 commit 7afa210
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions conf/default/web.conf.default
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,7 @@ guest_width = 1280
guest_height = 1024
# rdp settings
guest_rdp_port = 3389
ignore_rdp_cert = false

[packages]
# VM tags may be used to specify on which guest machines a sample should be run
Expand Down
6 changes: 5 additions & 1 deletion web/guac/consumers.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,15 @@ async def connect(self):
params = urllib.parse.parse_qs(self.scope["query_string"].decode())

if "rdp" in guest_protocol:
guest_host = params.get("guest_ip", "")
hosts = params.get("guest_ip", "")
guest_host = hosts[0]
guest_port = int(web_cfg.guacamole.guest_rdp_port) or 3389
ignore_cert = "true" if web_cfg.guacamole.ignore_rdp_cert == True else "false"
else:
guest_host = web_cfg.guacamole.vnc_host or "localhost"
ports = params.get("vncport", ["5900"])
guest_port = int(ports[0])
ignore_cert = "false"

guacd_recording_name = params.get("recording_name", ["task-recording"])[0]

Expand All @@ -53,6 +56,7 @@ async def connect(self):
password=guest_password,
recording_path=guacd_recording_path,
recording_name=guacd_recording_name,
ignore_cert=ignore_cert
)

if self.client.connected:
Expand Down

0 comments on commit 7afa210

Please sign in to comment.