Category: 

What Is a Chroot?

Article Details
  • Written By: Mary McMahon
  • Edited By: Shereen Skola
  • Last Modified Date: 26 August 2016
  • Copyright Protected:
    2003-2016
    Conjecture Corporation
  • Print this Article
Free Widgets for your Site/Blog
The atmosphere of Jupiter's moon Io collapses every time it is eclipsed by the planet.   more...

September 29 ,  2008 :  The Dow Jones Industrial Average experienced its largest one-day drop in history.  more...

A chroot is an isolated area in a computer system where users can test untrusted programs and engage in other operations that they do not want to affect the rest of the computer. It is used in Unix and similar systems, and requires the user to execute a series of commands that change the root directory used as a reference by the program. The chroot command needs to be used cautiously because the system can still be vulnerable if it is not set up properly, or if the user fails to exercise care when operating inside it.

When a user creates a chroot environment, the programs run within that environment treat the specified directory as the root. These programs assume that there are no higher directories, and thus cannot access the true root directory at the top of the file system. This makes it difficult to make modifications that could endanger the rest of the system. Other programs cannot access and modify the information within the chroot, either; it acts like an isolation unit.

Ad

Chroot can be broken, using a variety of techniques. One of the most basic involves leaving the user in the chroot with root privileges, which allow for widespread modifications to the system. Programs can take advantage of this to break out of their digital jail and access the rest of the system. For this reason, it is important to change the user permissions as soon as possible, a standard measure in computer security. Leaving users set to the least privileged roles as a general rule can reduce the risk of a safety problem.

The false root directory also needs to be appropriately populated with resources programs need to use. If it is not, they may not run correctly. Users typically keep anything not strictly necessary out of the chroot, but do need to make sure some information is available. As users navigate in the environment, they can take note of any specific issues or concerns that arise so they’re aware before they try the same processes in the computer system at large.

This can be a useful testing environment, where a user wants to explore code or programs with a reduced risk to the rest of the system. It can also be valuable for handling unknown or untrusted materials. Rather than loading these on the system directly, the user can use chroot to examine and evaluate them to determine if they are safe.

Ad

You might also Like

Recommended

Discuss this Article

Post your comments

exception 'Exception' with message 'error writing captcha: Duplicate entry '2147483647' for key 'PRIMARY'' in /ssd/www/wisegeek/public_html/_core/classes/public/Captcha.php:44
Stack trace:
#0 /ssd/www/wisegeek/public_html/_core/controls/public/ControlDiscussionPostBox.php(324): Captcha->createCaptcha()
#1 /ssd/www/wisegeek/public_html/framework/classes/Control.php(104): ControlDiscussionPostBox->preRender(false)
#2 /ssd/www/wisegeek/public_html/framework/classes/Control.php(149): Control->render()
#3 /ssd/www/wisegeek/public_html/tpl/default-nocustom-lu/pages/public/article/article.htm(526): Control->__toString()
#4 /ssd/www/wisegeek/public_html/framework/classes/Control.php(300): require('/ssd/www/wisege...')
#5 /ssd/www/wisegeek/public_html/framework/classes/Control.php(309): Control->requireTpl('pages/public/ar...', Object(PageArticleCom), true)
#6 /ssd/www/wisegeek/public_html/framework/classes/Control.php(131): Control->renderTpl('pages/public/ar...', Object(PageArticleCom))
#7 /ssd/www/wisegeek/public_html/framework/classes/FormDataControl.php(87): Control->renderTemplate()
#8 /ssd/www/wisegeek/public_html/framework/classes/Control.php(109): FormDataControl->renderTemplate()
#9 /ssd/www/wisegeek/public_html/framework/classes/ScriptPage.php(50): Control->render(false)
#10 /ssd/www/wisegeek/public_html/framework/classes/Control.php(149): ScriptPage->render()
#11 /ssd/www/wisegeek/public_html/framework/classes/Page.php(97): Control->__toString()
#12 /ssd/www/wisegeek/public_html/_core/classes/public/PublicFrontController.php(443): Page->processRequest()
#13 /ssd/www/wisegeek/public_html/_core/classes/public/PublicFrontController.php(7): PublicFrontController->renderPage()
#14 /ssd/www/wisegeek/public_html/index.php(11): PublicFrontController::run()
#15 {main}