0

I am working on Fedora 29 (64bit) and our company has a secure browser software where we provide standardized testing to millions of students across the USA. Right now we are stuck in a situation. Students log on to the Fedora laptop under the standard account. They should install the secure browser and then run it to start their testing.

Issue is: we can't seem to find a way to have students install the secure browser without adding the standard account to the sudoers file. We get an error each time we try to install the secure browser on the standard account -- something along the lines "this user is not added to the sudoers file".

So I learned that the only way to install any software under a standard account is to add the standard account into the sudoers file which in turn makes the account Admin. We are trying to avoid that and find a way to install any software without having the standard account being changed to an admin account. Is there a way to do that? When we try to install it while under the standard account and run the terminal and use SU and then use another account that has admin rights (like su admin), it installs the software under that user account, not the standard account. So it seems the only way to install any software, let alone the secure browser, is to elevate the standard account to admin, install the software, and then return it to standard. Is that the only way?

  • What is the "secure browser"? What exactly gets installed and where? Why do the students have to install it? Can't the administrator install it for all users? Or maybe the students can simply run the program from their home directory? If it's really necessary to install the software you could configure the sodoers file to allow the students to run exactly the command(s) necessary for the installation and nothing else. – Bodo May 15 at 16:33
  • Why do not install it on different place? Talking about sudo you can define precise command(s) sudo user can run, for example you can configure it to be able to run only sudo yum install secutiry-browser – Romeo Ninov May 15 at 16:53
  • Just so you all know, im not an expert when it comes to Fedora or any linux system really. Learning as I go. The secure browser is a software our company created to have kids do their standarlized testing. The idea is the student logs into the standard account on a Fedora machine and then install the software and run it to start their test. As far as we can tell, students cant install the software unless its added to the sudoer file or if the standard account is changed to an admin account. trying to avoid all that. – Abdel K May 15 at 17:46
  • @Romeo Ninov , is there a way we can have a sudo command just for them to insatall that program only? that would be cool because we have a command for them to install the software but like I said , it asks for elevated admin privileges or to add the standard acc to sudoer file. – Abdel K May 15 at 17:47
  • @bodo can you point me to how to do that? that would be an ideal way to solve this. Thank you – Abdel K May 15 at 17:48
2

To do what you want is possible with sudo. You should define in /etc/sudoers record like this

student1 ALL= NOPASSWD: /usr/bin/yum install special-browser

or this is you want from user to provide password

student1 ALL=/usr/bin/yum install special-browser

So student1 user can exec (via sudo) only command /usr/bin/yum install special-browser (with full path to yum)

If the students are all part of the same group, then you could use a special syntax to manage a single sudo rule instead of one for each username. If the "User_Spec" begins with a percent sign (%), then the following name is taken as a group name:

%students ALL=/usr/bin/yum install special-browser

In case of non yum distribution feel free to change the command.

  • 1
    perfect that should work. Ill give it a try today and se how it goes. thank you all for all your help. – Abdel K May 16 at 15:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.