{"id":2643,"date":"2021-10-05T10:35:09","date_gmt":"2021-10-05T10:35:09","guid":{"rendered":"https:\/\/ownwebservers.com\/kb\/?p=2643"},"modified":"2021-10-05T10:35:09","modified_gmt":"2021-10-05T10:35:09","slug":"how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator","status":"publish","type":"post","link":"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/","title":{"rendered":"How to ban root access via the SSH Terminal extension for the Plesk administrator"},"content":{"rendered":"<p>This article will show, how to ban root or Administrator users from accessing Plesk. Plesk 18.0.38 and upgrades version include the SSH Terminal extension. To register as the root user to the SSH interface, the Plesk administrator can use this extension .<\/p>\n<p>By default Plesk runs utilities or scripts for the root user in the scenarios as follow:<\/p>\n<p><strong>1<sup>st<\/sup>\u00a0Scenario:<\/strong><\/p>\n<p>The task will be executed as root if a Plesk administrative manager creates a timed job and decides to run as root.<\/p>\n<p><strong>2<sup>nd<\/sup>\u00a0Scenario:<\/strong><\/p>\n<p>If an event manager is set up by a Plesk administrator and the assumed root command is run, the event handler\u00a0is activated.<\/p>\n<p><strong>3<sup>rd<\/sup>\u00a0Scenario:<\/strong><\/p>\n<p>When the Plesk administrator and\/or subscription owners are using the SSH terminal extension.<\/p>\n<p><strong>Have a look at the three root removal procedures:<\/strong><\/p>\n<p><strong>Procedure 1:<\/strong><\/p>\n<p>Files are created in the\u00a0<strong>$PRODUCT ROOT D\/var\/ folder<\/strong>. It is the most reliable system-wide way to disable the root access including scheduled tasks, event handlers and the\u00a0<strong>SSH terminal<\/strong>.<\/p>\n<p>1. The\u00a0<strong>Server<\/strong>\u00a0as the root user will be joined by\u00a0<strong>SSH<\/strong>.<\/p>\n<p>2. Create a fresh file called root.crontab.lock in the $<strong>PRODUCT ROOT D\/var\/<\/strong>\u00a0directory. Users will not be permitted to do scheduled tasks or view planned work, which must thus be run as root.<\/p>\n<p>3. Create an empty file named\u00a0<strong>root.event handler.lock<\/strong>\u00a0in the\u00a0<strong>$PRODUCT ROOT D\/var\/ directory<\/strong>, As a result, users are unable to create event managers that run root.<\/p>\n<p>4. Once the previous two processes have been performed, SSH Terminal will not provide\u00a0<strong>root access<\/strong>.<\/p>\n<p><strong>NOTE: $PRODUCT ROOT D is \/usr\/local\/psa on RPM-based systems whereas \/opt\/psa is on Debian-based systems.<\/strong><\/p>\n<p><strong>Procedure 2:<\/strong><\/p>\n<p>Only the SSH terminal root connection is given to the Plesk administrator, which can be stopped using\u00a0<strong>panel.ini<\/strong>. This does not prevent root access in\u00a0<strong>scheduled tasks<\/strong>\u00a0and\u00a0<strong>event managers<\/strong>.<\/p>\n<p>1.\u00a0<strong>Plesk\u00a0<\/strong>should then be logged in.<\/p>\n<p>2. Go to the\u00a0<strong>Extensions tab<\/strong>.<\/p>\n<p>3.\u00a0<strong>My Extensions<\/strong>\u00a0should then be selected.<\/p>\n<p>4. Open the\u00a0<strong>Panel.ini Editor<\/strong>\u00a0by simply click on it.<\/p>\n<p>5. The\u00a0<strong>Editor<\/strong>\u00a0option should then be selected.<\/p>\n<p>6. Execute the new text at the end of the file:<\/p>\n<p><strong>[login]<\/strong><\/p>\n<p><strong>systemAdmin = false<\/strong><\/p>\n<p>7. Restrict root access using the panel.ini menu.<\/p>\n<p><strong>[ext-ssh-terminal]<\/strong><\/p>\n<p><strong>rootAccessAllowed = false<\/strong><\/p>\n<p>8. Using the panel.ini menu\u00a0to the right. It will not be possible to set up it on a server if users add the \u2018SSH Terminal\u2019 extension to the blacklist.\u00a0<strong>[extensions]<\/strong><\/p>\n<p><strong>blacklist = ext-panel-editor<\/strong><\/p>\n<p>9. Press the\u00a0<strong>Save button<\/strong>.<\/p>\n<p><strong>Procedure 3:<\/strong><\/p>\n<p>Both the\u00a0<strong>Plesk administrator<\/strong>\u00a0and\u00a0<strong>Subscription holders<\/strong>\u00a0can stop the SSH Terminal extension using panel.ini. This does not limit root access in\u00a0<strong>scheduled tasks<\/strong>\u00a0or\u00a0<strong>event handlers<\/strong>.<\/p>\n<p>To the right, there\u2019s a panel.ini option. You won\u2019t be able to install the\u00a0<strong>\u2018SSH Terminal\u2019<\/strong>\u00a0extension on a server if you add it to the blacklist.<\/p>\n<p><strong>[extensions]<\/strong><\/p>\n<p><strong>blacklist = ext-ssh-terminal, ext-panel-editor<\/strong><\/p>\n<p>Using this procedure, you can ban root or administrator users from accessing Plesk.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This article will show, how to ban root or Administrator users from accessing Plesk. Plesk 18.0.38 and upgrades version include the SSH Terminal extension. To register as the root user to the SSH interface, the Plesk administrator can use this extension . By default Plesk runs utilities or scripts for the root user in the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-2643","post","type-post","status-publish","format-standard","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v15.2.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to ban root access via the SSH Terminal extension for the Plesk administrator - OWS KB<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to ban root access via the SSH Terminal extension for the Plesk administrator - OWS KB\" \/>\n<meta property=\"og:description\" content=\"This article will show, how to ban root or Administrator users from accessing Plesk. Plesk 18.0.38 and upgrades version include the SSH Terminal extension. To register as the root user to the SSH interface, the Plesk administrator can use this extension . By default Plesk runs utilities or scripts for the root user in the [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/\" \/>\n<meta property=\"og:site_name\" content=\"OWS KB\" \/>\n<meta property=\"article:published_time\" content=\"2021-10-05T10:35:09+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\">\n\t<meta name=\"twitter:data1\" content=\"admin\">\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\">\n\t<meta name=\"twitter:data2\" content=\"2 minutes\">\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/#website\",\"url\":\"https:\/\/ownwebservers.com\/kb\/\",\"name\":\"OWS KB\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":\"https:\/\/ownwebservers.com\/kb\/?s={search_term_string}\",\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/#webpage\",\"url\":\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/\",\"name\":\"How to ban root access via the SSH Terminal extension for the Plesk administrator - OWS KB\",\"isPartOf\":{\"@id\":\"https:\/\/ownwebservers.com\/kb\/#website\"},\"datePublished\":\"2021-10-05T10:35:09+00:00\",\"dateModified\":\"2021-10-05T10:35:09+00:00\",\"author\":{\"@id\":\"https:\/\/ownwebservers.com\/kb\/#\/schema\/person\/4a40fe3fe17a08ddd1d7c113668e75f2\"},\"breadcrumb\":{\"@id\":\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"item\":{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/\",\"url\":\"https:\/\/ownwebservers.com\/kb\/\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"position\":2,\"item\":{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/\",\"url\":\"https:\/\/ownwebservers.com\/kb\/how-to-ban-root-access-via-the-ssh-terminal-extension-for-the-plesk-administrator\/\",\"name\":\"How to ban root access via the SSH Terminal extension for the Plesk administrator\"}}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/#\/schema\/person\/4a40fe3fe17a08ddd1d7c113668e75f2\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/#personlogo\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/ba5db5841d48bd7517bb2583e13983e6d2fa56a4099a0b3c61ad2daefc321303?s=96&d=mm&r=g\",\"caption\":\"admin\"},\"sameAs\":[\"https:\/\/ownwebservers.com\/kb\"]}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","_links":{"self":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts\/2643","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/comments?post=2643"}],"version-history":[{"count":1,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts\/2643\/revisions"}],"predecessor-version":[{"id":2644,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts\/2643\/revisions\/2644"}],"wp:attachment":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/media?parent=2643"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/categories?post=2643"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/tags?post=2643"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}