Blocking a command from execution in ubuntuBlock a command from sudo userWhat is “chmod” and its practical aspects?Having trouble with chmodRepair filesystem permissionchmod: Everything on SD Card Stuck On 755, Owner is RootHow to fix corrupted permissions inside encfs encrypted folderPermission denied for 'sudo' after 'sudo chmod 666 /usr'Chown and chmod in ubuntu with different applications using common files

How does a variable caster level work for spells?

Will being an emotionally numb 14 year-old prevent me from eventually being a pilot?

Is a vector space naturally isomorphic to its dual?

What were the prevailing real-life cultural connotations of "clones" in 1975 (Star Wars' 3rd draft)?

Vintage vs modern B&W photography techniques differ in color luminance - what's going on here?

Is a pad just a melody synth with a bunch of reverb and echo?

LWC not evaluating the if:true statement

Why are observers/reference frames able to see themselves moving through time but not through space?

A professor commented that my research is too simple as compared to my colleagues. What does that mean about my future prospects?

if chords are not only linked to the major scale, then why scales at all?

Why do we worry about overfitting even if "all models are wrong"?

Why does the single dot entry exist in file systems?

How tall would a rainforest need to be to make it completely dark at ground level

Why use a recurrent neural network over a feedforward neural network for sequence prediction?

FIDE Laws of Chess pre-2017

Why is Carbon Dioxide a Greenhouse Gas whereas Ammonia is not?

1 kHz clock over long wire

Is this a deadly encounter?

What is the process of going from machine code to electrically controlling individual transistors?

Why is the Duration of Time spent in the Dayside greater than that of the Night side of the Moon for Chandrayaan-2 Orbiter?

JPEG with transparent background

Can dual US-Canadian citizens travel to the US with an expired US passport but valid Canadian passport?

What are the catcode 11 / letter codepoints in Xe(La)Tex?

How to specify index of specific elements in every sublist of nested list?



Blocking a command from execution in ubuntu


Block a command from sudo userWhat is “chmod” and its practical aspects?Having trouble with chmodRepair filesystem permissionchmod: Everything on SD Card Stuck On 755, Owner is RootHow to fix corrupted permissions inside encfs encrypted folderPermission denied for 'sudo' after 'sudo chmod 666 /usr'Chown and chmod in ubuntu with different applications using common files






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty
margin-bottom:0;









0

















I have a shared PC with Ubuntu in it, My friends may also want to use sudo.
But I know they often play with the command



chmod -R 777 /


I need to know is there a way to specifically block this command from execution even by the root user. As no one gonna has to use this command on the usual purpose.



But I may need friends to use chmod on other dirs.










share|improve this question























  • 4





    I simply wouldn't give sudo ability to a "friend" who thinks it's fun to wreck my computer. Welcome to Ask Ubuntu.

    – chili555
    Jul 14 at 2:26











  • Would it be possible for your friends to experiment with commands in virtual machines running on the shared PC?

    – dsstorefile1
    Jul 14 at 7:38











  • See Block a command from sudo user but note that it's non-trivial to make such measures effective - most obviously, if you don't prevent "other" sudoers from editing the sudoers file

    – steeldriver
    Jul 14 at 16:49


















0

















I have a shared PC with Ubuntu in it, My friends may also want to use sudo.
But I know they often play with the command



chmod -R 777 /


I need to know is there a way to specifically block this command from execution even by the root user. As no one gonna has to use this command on the usual purpose.



But I may need friends to use chmod on other dirs.










share|improve this question























  • 4





    I simply wouldn't give sudo ability to a "friend" who thinks it's fun to wreck my computer. Welcome to Ask Ubuntu.

    – chili555
    Jul 14 at 2:26











  • Would it be possible for your friends to experiment with commands in virtual machines running on the shared PC?

    – dsstorefile1
    Jul 14 at 7:38











  • See Block a command from sudo user but note that it's non-trivial to make such measures effective - most obviously, if you don't prevent "other" sudoers from editing the sudoers file

    – steeldriver
    Jul 14 at 16:49














0












0








0








I have a shared PC with Ubuntu in it, My friends may also want to use sudo.
But I know they often play with the command



chmod -R 777 /


I need to know is there a way to specifically block this command from execution even by the root user. As no one gonna has to use this command on the usual purpose.



But I may need friends to use chmod on other dirs.










share|improve this question

















I have a shared PC with Ubuntu in it, My friends may also want to use sudo.
But I know they often play with the command



chmod -R 777 /


I need to know is there a way to specifically block this command from execution even by the root user. As no one gonna has to use this command on the usual purpose.



But I may need friends to use chmod on other dirs.







gnome-terminal chmod






share|improve this question
















share|improve this question













share|improve this question




share|improve this question








edited Jul 14 at 2:18







Sivaramakrishnan

















asked Jul 14 at 2:13









SivaramakrishnanSivaramakrishnan

32 bronze badges




32 bronze badges










  • 4





    I simply wouldn't give sudo ability to a "friend" who thinks it's fun to wreck my computer. Welcome to Ask Ubuntu.

    – chili555
    Jul 14 at 2:26











  • Would it be possible for your friends to experiment with commands in virtual machines running on the shared PC?

    – dsstorefile1
    Jul 14 at 7:38











  • See Block a command from sudo user but note that it's non-trivial to make such measures effective - most obviously, if you don't prevent "other" sudoers from editing the sudoers file

    – steeldriver
    Jul 14 at 16:49













  • 4





    I simply wouldn't give sudo ability to a "friend" who thinks it's fun to wreck my computer. Welcome to Ask Ubuntu.

    – chili555
    Jul 14 at 2:26











  • Would it be possible for your friends to experiment with commands in virtual machines running on the shared PC?

    – dsstorefile1
    Jul 14 at 7:38











  • See Block a command from sudo user but note that it's non-trivial to make such measures effective - most obviously, if you don't prevent "other" sudoers from editing the sudoers file

    – steeldriver
    Jul 14 at 16:49








4




4





I simply wouldn't give sudo ability to a "friend" who thinks it's fun to wreck my computer. Welcome to Ask Ubuntu.

– chili555
Jul 14 at 2:26





I simply wouldn't give sudo ability to a "friend" who thinks it's fun to wreck my computer. Welcome to Ask Ubuntu.

– chili555
Jul 14 at 2:26













Would it be possible for your friends to experiment with commands in virtual machines running on the shared PC?

– dsstorefile1
Jul 14 at 7:38





Would it be possible for your friends to experiment with commands in virtual machines running on the shared PC?

– dsstorefile1
Jul 14 at 7:38













See Block a command from sudo user but note that it's non-trivial to make such measures effective - most obviously, if you don't prevent "other" sudoers from editing the sudoers file

– steeldriver
Jul 14 at 16:49






See Block a command from sudo user but note that it's non-trivial to make such measures effective - most obviously, if you don't prevent "other" sudoers from editing the sudoers file

– steeldriver
Jul 14 at 16:49











1 Answer
1






active

oldest

votes


















1


















The answer is don't give sudo or root permissions to anybody you don't trust with them. If it's your computer and they might wreck your machine, then don't give them any elevated permissions, or don't let them use the computer at all.






share|improve this answer


























  • If It is not possible to restrict, is there any way to easily recover such thing after the execution of that command?

    – Sivaramakrishnan
    Jul 17 at 5:21












Your Answer








StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "89"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/4.0/"u003ecc by-sa 4.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);














draft saved

draft discarded
















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1158134%2fblocking-a-command-from-execution-in-ubuntu%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown


























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









1


















The answer is don't give sudo or root permissions to anybody you don't trust with them. If it's your computer and they might wreck your machine, then don't give them any elevated permissions, or don't let them use the computer at all.






share|improve this answer


























  • If It is not possible to restrict, is there any way to easily recover such thing after the execution of that command?

    – Sivaramakrishnan
    Jul 17 at 5:21















1


















The answer is don't give sudo or root permissions to anybody you don't trust with them. If it's your computer and they might wreck your machine, then don't give them any elevated permissions, or don't let them use the computer at all.






share|improve this answer


























  • If It is not possible to restrict, is there any way to easily recover such thing after the execution of that command?

    – Sivaramakrishnan
    Jul 17 at 5:21













1














1










1









The answer is don't give sudo or root permissions to anybody you don't trust with them. If it's your computer and they might wreck your machine, then don't give them any elevated permissions, or don't let them use the computer at all.






share|improve this answer














The answer is don't give sudo or root permissions to anybody you don't trust with them. If it's your computer and they might wreck your machine, then don't give them any elevated permissions, or don't let them use the computer at all.







share|improve this answer













share|improve this answer




share|improve this answer










answered Jul 14 at 4:03









GerowenGerowen

1,2377 silver badges16 bronze badges




1,2377 silver badges16 bronze badges















  • If It is not possible to restrict, is there any way to easily recover such thing after the execution of that command?

    – Sivaramakrishnan
    Jul 17 at 5:21

















  • If It is not possible to restrict, is there any way to easily recover such thing after the execution of that command?

    – Sivaramakrishnan
    Jul 17 at 5:21
















If It is not possible to restrict, is there any way to easily recover such thing after the execution of that command?

– Sivaramakrishnan
Jul 17 at 5:21





If It is not possible to restrict, is there any way to easily recover such thing after the execution of that command?

– Sivaramakrishnan
Jul 17 at 5:21


















draft saved

draft discarded















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1158134%2fblocking-a-command-from-execution-in-ubuntu%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown









Popular posts from this blog

Distance measures on a map of a game The 2019 Stack Overflow Developer Survey Results Are Inmin distance in a graphShortest distance path on contour plotHow to plot a tilted map?Finding points outside of a diskDelaunay link distanceAnnulus from GeoDisks: drawing a ring on a mapNegative Correlation DistanceFind distance along a path (GPS coordinates)Finding position at given distance in a GeoPathMathematics behind distance estimation using camera

How to get a smooth, uniform ParametricPlot of a 2D Region?How to plot a complicated Region?How to exclude a region from ParametricPlotHow discretize a region placing vertices on a specific non-uniform gridHow to transform a Plot or a ParametricPlot into a RegionHow can I get a smooth plot of a bounded region?Smooth ParametricPlot3D with RegionFunction?Smooth border of a region ParametricPlotSmooth region boundarySmooth region plot from list of pointsGet minimum y of a certain x in a region

Genealogie vun de Merowenger Vum Merowech bis zum Chilperich I. | Navigatiounsmenü