{"id":2105,"date":"2022-07-06T13:37:47","date_gmt":"2022-07-06T11:37:47","guid":{"rendered":"https:\/\/www.dsecbypass.com\/?p=2105"},"modified":"2024-02-07T10:49:55","modified_gmt":"2024-02-07T09:49:55","slug":"keyshot-vulnerability","status":"publish","type":"post","link":"https:\/\/www.dsecbypass.com\/en\/keyshot-vulnerability\/","title":{"rendered":"KeyShot Vulnerability"},"content":{"rendered":"<p>[et_pb_section fb_built=&#8221;1&#8243; _builder_version=&#8221;4.17.3&#8243; _module_preset=&#8221;default&#8221; custom_padding=&#8221;0px||||false|false&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_row _builder_version=&#8221;4.17.3&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.17.3&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_image src=&#8221;https:\/\/www.dsecbypass.com\/wp-content\/uploads\/2022\/06\/keyshot-logo-250.png&#8221; alt=&#8221;keyshot logo&#8221; title_text=&#8221;keyshot logo&#8221; align=&#8221;center&#8221; _builder_version=&#8221;4.17.4&#8243; _module_preset=&#8221;default&#8221; background_color=&#8221;#000000&#8243; width=&#8221;50%&#8221; module_alignment=&#8221;center&#8221; global_colors_info=&#8221;{}&#8221;][\/et_pb_image][et_pb_text _builder_version=&#8221;4.23.2&#8243; _module_preset=&#8221;default&#8221; hover_enabled=&#8221;0&#8243; global_colors_info=&#8221;{}&#8221; sticky_enabled=&#8221;0&#8243;]<\/p>\n<p style=\"text-align: justify;\">Vladimir had the opportunity to test the security of <a href=\"https:\/\/www.keyshot.com\/\" target=\"_blank\" rel=\"noopener\" title=\"KeyShot website\">KeyShot 11.1<\/a> software during a penetration testing mission.<\/p>\n<p style=\"text-align: justify;\">This software, published by Luxion, is used to produce photorealistic 3D renderings in real time. It requires significant computing capacities which can be distributed on several servers thanks to <a href=\"https:\/\/www.keyshot.com\/features\/network-rendering\/\" target=\"_blank\" rel=\"noopener\" title=\"Description of KeyShot NR on the Luxion website\">KeyShot Network Rendering<\/a>.<\/p>\n<p style=\"text-align: justify;\">In the case of a distributed architecture, one or more <em>managers <\/em>must be configured to manage user accounts and distribute tasks to different <em>workers<\/em>. The end users of the software then use their local client to authenticate with the <em>manager<\/em>and send him the tasks to be distributed.<\/p>\n<p style=\"text-align: justify;\">The KeyShot Network Monitoring thick client (&#8220;keyshot_network_monitor.exe&#8221;) allows users to authenticate and access the progress status of tasks and the occupation rate of <em>workers<\/em>.<\/p>\n<p>[\/et_pb_text][et_pb_text module_id=&#8221;sauvegarder&#8221; _builder_version=&#8221;4.23.2&#8243; _module_preset=&#8221;default&#8221; hover_enabled=&#8221;0&#8243; global_colors_info=&#8221;{}&#8221; sticky_enabled=&#8221;0&#8243;]<\/p>\n<h2 class=\"part\" data-startline=\"14\" data-endline=\"14\">Network protocol analysis<\/h2>\n<p style=\"text-align: justify;\">Clients communicate with the manager on port TCP\/4827 using a proprietary protocol. Communications are in the clear by default but <a href=\"https:\/\/manual.keyshot.com\/keyshot11\/manual\/getting-started\/setup\/manager-setup\/\" target=\"_blank\" rel=\"noopener\" title=\"KeyShot documentation to configure the manager with TLS encryption\">TLS encryption can be configured<\/a>. During the audit in question, encryption was not enabled.<\/p>\n<p style=\"text-align: justify;\">The DSecBypass auditor decided to analyze the unauthenticated attack surface exposed by the manager. To do this, he used KeyShot Network Monitoring with a valid account to reverse-engineer the communications between the client and the manager.<\/p>\n<p style=\"text-align: justify;\"><a href=\"https:\/\/www.wireshark.org\/\" target=\"_blank\" rel=\"noopener\" title=\"Wireshark network analysis software\">Wireshark <\/a>software was used to capture the different packets exchanged. The consultant interacted with the software, taking care to use the most important features so as to generate maximum traffic and be able to identify which sequences of bytes govern the actions.<\/p>\n<p style=\"text-align: justify;\">In order to isolate the packets of interest in the conversation, simply create a filter on the manager&#8217;s IP address as follows:<\/p>\n<blockquote>\n<p>ip.addr == 192.168.1.1<\/p>\n<\/blockquote>\n<p>Then decode TCP stream from filtered packets:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dsecbypass.com\/wp-content\/uploads\/2022\/06\/suivre_tcp-300x209.png\" alt=\"Wireshark follow TCP stream\" class=\"wp-image-2079 alignnone size-medium\" style=\"display: block; margin-left: auto; margin-right: auto;\" width=\"300\" height=\"209\"><\/p>\n<p style=\"text-align: justify;\">A window opens and displays the characters that can be displayed, colored according to whether they are sent or received.<\/p>\n<p style=\"text-align: justify;\">This window is useful for following the progress of the conversation between the client and the manager. When an interesting message is discovered, simply click on it to highlight the corresponding packet in the Wireshark capture window.<\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dsecbypass.com\/wp-content\/uploads\/2022\/06\/follow_tcp_select_paquet-1024x600.png\" alt=\"Wireshark click in window to select packet\" class=\"wp-image-2082 alignnone size-large\" width=\"1024\" height=\"600\" srcset=\"https:\/\/www.dsecbypass.com\/wp-content\/uploads\/2022\/06\/follow_tcp_select_paquet-980x574.png 980w, https:\/\/www.dsecbypass.com\/wp-content\/uploads\/2022\/06\/follow_tcp_select_paquet-480x281.png 480w\" sizes=\"(min-width: 0px) and (max-width: 480px) 480px, (min-width: 481px) and (max-width: 980px) 980px, (min-width: 981px) 1024px, 100vw\" \/><\/p>\n<p>The screenshot above shows the package selected by clicking on the &#8220;pass&#8221; string of letters.<\/p>\n<p>In order to extract the message as it is, all you have to do is export the TCP data (data or payload TCP):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dsecbypass.com\/wp-content\/uploads\/2022\/06\/follow_tcp_select_paquet_export_octet-300x274.png\" alt=\"\" class=\"wp-image-2086 alignnone size-medium\" style=\"display: block; margin-left: auto; margin-right: auto;\" width=\"300\" height=\"274\"><\/p>\n<p style=\"text-align: justify;\">The auditor was thus able to export the messages corresponding to the authentication, the recovery of information on the tasks in progress, the change of information of a user and other interesting actions.<\/p>\n<p style=\"text-align: justify;\">An important part of the analysis was to understand how the packets were formed and in what order they were sent to the manager. It is also important to analyze the manager&#8217;s responses, in the same way, in order to know if the previous message was rejected or not.<\/p>\n<p>[\/et_pb_text][et_pb_text module_id=&#8221;virus&#8221; _builder_version=&#8221;4.23.2&#8243; _module_preset=&#8221;default&#8221; hover_enabled=&#8221;0&#8243; global_colors_info=&#8221;{}&#8221; sticky_enabled=&#8221;0&#8243;]<\/p>\n<h2>Packet replay and forging<\/h2>\n<p style=\"text-align: justify;\">Once the different messages have been isolated, it may be interesting to replay and modify them.<\/p>\n<p style=\"text-align: justify;\">The auditor relied on the <a href=\"https:\/\/github.com\/Gallopsled\/pwntools\" title=\"pwntools python library\" target=\"_blank\" rel=\"noopener\">Python pwntools library<\/a>: CTF oriented, it is optimized for pwn\/reverse type challenges and allows in a few lines to interact with TCP sockets.<\/p>\n<p>A few bash commands are also useful:<\/p>\n<p><span style=\"color: #808080;\">#Inspect message bytes<\/span><\/p>\n<blockquote>\n<pre>xxd fichier.bin<\/pre>\n<\/blockquote>\n<p><span style=\"color: #808080;\">#Compare octets between two files and display offsets<\/span><\/p>\n<blockquote>\n<pre>cmp -l fichier1.bin fichier2.bin | gawk '{printf \"%08X %02X %02X\\n\", $1, strtonum(0$2), strtonum(0$3)}'<\/pre>\n<\/blockquote>\n<p><span style=\"color: #808080;\">#Replace a series of bytes with another in a file (useful for modifying a string for example)<\/span><\/p>\n<blockquote>\n<pre>xxd -p -c 123456789 fichier.bin |sed 's\/0011002200330044\/0011003300220044\/g' | xxd -p -r &gt; fichier2.bin<\/pre>\n<\/blockquote>\n<p>Identifying the bytes specifying the size of the message and the various fields is left as an exercise for the readers.<\/p>\n<p>The following Python script template can be used to easily send the prepared messages to the manager:<\/p>\n<p>\n<script src=\"https:\/\/gist.github.com\/vtoutain\/98e481de63d251f3c2380a341490c79e.js\"><\/script>\n<\/p>\n<p>[\/et_pb_text][et_pb_text module_id=&#8221;mobiles&#8221; _builder_version=&#8221;4.23.2&#8243; _module_preset=&#8221;default&#8221; hover_enabled=&#8221;0&#8243; global_colors_info=&#8221;{}&#8221; sticky_enabled=&#8221;0&#8243;]<\/p>\n<h2>The vulnerability<\/h2>\n<p style=\"text-align: justify;\">Using the methodologies described in the previous paragraphs, the auditor managed to find a security flaw in the protocol in one day of analysis. The final POC will not be disclosed.<\/p>\n<p style=\"text-align: justify;\">The vulnerability, discovered by Vladimir, allows an unauthenticated attacker with access to port 4827 of the manager to bypass authentication in order to obtain the list of users created, then in the same way request information concerning them (date of last update, email address and role).<\/p>\n<p style=\"text-align: justify;\">This information leak could allow an attacker to attempt a brute force attack on discovered accounts or social engineering using email addresses.<\/p>\n<p style=\"text-align: justify;\">Not having a direct impact on the security of the distributed infrastructure (non-privileged and non-admin actions), this vulnerability presents a risk qualified as important with a <a href=\"https:\/\/nvd.nist.gov\/vuln-metrics\/cvss\/v3-calculator?vector=AV:N\/AC:L\/PR:N\/UI:N\/S:U\/C:L\/I:N\/A:N&amp;version=3.1\" target=\"_blank\" rel=\"noopener\" title=\"KeyShot 11.1 Vulnerability CVSS Score\">CVSS score of 5.3<\/a>.<\/p>\n<p>[\/et_pb_text][et_pb_text module_id=&#8221;motsdepasse&#8221; _builder_version=&#8221;4.23.2&#8243; _module_preset=&#8221;default&#8221; hover_enabled=&#8221;0&#8243; global_colors_info=&#8221;{}&#8221; sticky_enabled=&#8221;0&#8243;]<\/p>\n<h2>Communication with the software publisher<\/h2>\n<p style=\"text-align: justify;\">Communication with the publisher Luxion went remarkably well: the vulnerability disclosure process is well documented at <a href=\"https:\/\/www.keyshot.com\/csirt\/\" target=\"_blank\" rel=\"noopener\">https:\/\/www.keyshot.com\/csirt\/<\/a>, the security team responded within the day, and the vulnerability was validated and fixed in the following days.<\/p>\n<p style=\"text-align: justify;\">KeyShot 11.2 release fixes this vulnerability.<\/p>\n<p style=\"text-align: justify;\">Luxion documented this new vulnerability in their <a href=\"https:\/\/download.keyshot.com\/cert\/lsa-989246\/lsa-989246.pdf\" title=\"KeyShot vulnerability notification reported by DSecBypass\" target=\"_blank\" rel=\"noopener\">LSA-989246<\/a> and credited Vladimir TOUTAIN of DSecBypass for discovering this vulnerability in KeyShot software.<\/p>\n<p style=\"text-align: justify;\"><span style=\"text-decoration: underline;\">21\/06\/2022 :<\/span> First mail sent to <a href=\"mailto:security@luxion.com\">security@luxion.com<\/a><\/p>\n<p style=\"text-align: justify;\"><span style=\"text-decoration: underline;\">21\/06\/2022 :<\/span> Response from Luxion and details sent by Vladimir<\/p>\n<p style=\"text-align: justify;\"><span style=\"text-decoration: underline;\">27\/06\/2022 :<\/span> Mail from Luxion indicating that the vulnerability has been validated and fixed since 21\/06, sending a beta version with the patch<\/p>\n<p style=\"text-align: justify;\"><span style=\"text-decoration: underline;\">27\/06\/2022 :<\/span> Luxion sends a first version of advisory LSA-989246 for validation, agreement on a deadline of one week after the publication of version 11.2 to communicate on the DSecBypass side<\/p>\n<p style=\"text-align: justify;\"><span style=\"text-decoration: underline;\">29\/06\/2022 :<\/span> Version 11.2 released with the vulnerability fix<\/p>\n<p style=\"text-align: justify;\"><span style=\"text-decoration: underline;\">06\/07\/2022 :<\/span> Validation of this blog post by Luxion<\/p>\n<p style=\"text-align: justify;\">[\/et_pb_text][\/et_pb_column][\/et_pb_row][et_pb_row _builder_version=&#8221;4.17.3&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.17.3&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_text _builder_version=&#8221;4.23.2&#8243; _module_preset=&#8221;default&#8221; hover_enabled=&#8221;0&#8243; global_colors_info=&#8221;{}&#8221; sticky_enabled=&#8221;0&#8243;]<\/p>\n<p style=\"text-align: justify;\"><span>\ud83d\udee1\ufe0f DSecBypass accompanies you on the <a href=\"https:\/\/www.dsecbypass.com\/en\/application-pentest\/\" title=\"Penetration test of thick clients and network protocols\">security audit of your applications<\/a>. Do not hesitate to <a href=\"https:\/\/www.dsecbypass.com\/en\/contact\/\">contact <\/a>us for additional information and\/or a personalized quote \ud83d\udcdd.<\/span><\/p>\n<p>[\/et_pb_text][\/et_pb_column][\/et_pb_row][et_pb_row _builder_version=&#8221;4.17.3&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.17.3&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_button button_url=&#8221;https:\/\/www.dsecbypass.com\/en\/contact\/&#8221; button_text=&#8221;CONTACT US&#8221; button_alignment=&#8221;center&#8221; _builder_version=&#8221;4.17.4&#8243; _module_preset=&#8221;default&#8221; custom_button=&#8221;on&#8221; button_text_size=&#8221;13px&#8221; button_bg_color=&#8221;#4328b7&#8243; button_border_width=&#8221;10px&#8221; button_border_color=&#8221;#4328b7&#8243; button_border_radius=&#8221;0px&#8221; button_letter_spacing=&#8221;2px&#8221; button_font=&#8221;Titillium Web|700||on|||||&#8221; background_layout=&#8221;dark&#8221; global_colors_info=&#8221;{}&#8221;][\/et_pb_button][\/et_pb_column][\/et_pb_row][\/et_pb_section]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The article exposes the methodology used to find a flaw in a network protocol used by the KeyShot software.<\/p>\n","protected":false},"author":4,"featured_media":2087,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_et_pb_use_builder":"on","_et_pb_old_content":"","_et_gb_content_width":"","footnotes":""},"categories":[34],"tags":[],"class_list":["post-2105","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blog-en"],"_links":{"self":[{"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/posts\/2105","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/comments?post=2105"}],"version-history":[{"count":42,"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/posts\/2105\/revisions"}],"predecessor-version":[{"id":3253,"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/posts\/2105\/revisions\/3253"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/media\/2087"}],"wp:attachment":[{"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/media?parent=2105"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/categories?post=2105"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dsecbypass.com\/en\/wp-json\/wp\/v2\/tags?post=2105"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}