LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 08-10-2015, 08:13 AM   #1
ZTagr
LQ Newbie
 
Registered: Aug 2013
Posts: 22

Rep: Reputation: Disabled
Question Adding a "default" Firefox profile to the /root user folder?


Hi all;

Just recently, I was installing packages on my Kubuntu 15.04 system using the Synaptic package manager when I noticed that there was a link to a website for that package; I had never tried to use this link before (for this or any other package I installed using Synaptic...), and so I thought I would check it out.

To my surprise, I received several error messages, the first pertaining to the fact that Firefox could not locate a user profile for the ROOT user (I know why it can't, of course...); then a second message along the same lines stating that Konqueror's config file located in:
/root/.kde/share/config/konquerorrc
could not be written.

These two errors got me to thinking: Yes, I did run Synaptic with sudo, to give it root-user "powers", and so now Synaptic is running like it actually IS the "root" user, although there is no such user in Ubuntu. Which leads me to my question:

Is is a good / bad / terrible idea to create default "profile"-type files for the "root" user in the /root folder, such as Firefox's default profile, or Konqueror's "konquerorrc" file? I could simply copy MY OWN USERS copy of these particular files into the /root folder, at each file's "normal" location, modifying these in any way required should they obviously pertain to some account OTHER than the "root" user...; would this help in any way, or is it even necessary?

I just don't like receiving error messages when I think that something might be done about them! But I don't know the ramifications of adding content to the /root folder, if there are indeed any at all, on Ubuntu Linux systems...

Up until this point, I had never attempted to run Firefox from a program started with the "sudo" switch, and so I was never before confronted with this particular issue. Now I see that even the Konqueror web browser / file manager program has this same issue, and I'm wondering just how many other programs try to read or write to config. files that SHOULD be found in the /root folder, but of course are not actually there!

Does anyone have any advice for me on how I should proceed from here? I just want to know if what I am considering is a good idea or not...

Thanks in advance,
ZTagr.
 
Old 08-10-2015, 01:26 PM   #2
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,400

Rep: Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582Reputation: 2582
Warning: is is a very BAD idea to run firefox as ROOT!!!!


open a terminal
become root
launch firefox
-- this works on my Debian8 install ( and rhel and suse )
Code:
su -
---- type in the root password when asked for ----
firefox
it is a bad idea to use FF as root

Last edited by John VV; 08-10-2015 at 01:29 PM.
 
Old 08-10-2015, 01:43 PM   #3
ntubski
Senior Member
 
Registered: Nov 2005
Distribution: Debian, Arch
Posts: 3,387

Rep: Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553
This sounds like a deficiency/bug in Synaptic: it should really be opening web sites with your original, non-elevated user id. So I think you should open a feature request/bug report against Synaptic.
 
Old 08-11-2015, 12:16 AM   #4
JimKyle
Member
 
Registered: Dec 2001
Location: Oklahoma City, OK, USA
Distribution: Xubuntu 16.04 LTS
Posts: 214
Blog Entries: 1

Rep: Reputation: 39
Quote:
Originally Posted by ntubski View Post
This sounds like a deficiency/bug in Synaptic: it should really be opening web sites with your original, non-elevated user id. So I think you should open a feature request/bug report against Synaptic.
Nope, not a bug in Synaptic. The problem is that "sudo" is working as designed!

It's a guaranteed problem-creator to use "sudo" with any GUI program such as Synaptic; that's why "gksu" and "gksudo" exist. They differ from "sudo" in the way they treat the current user ID and current environment variables. With sudo, the current user becomes root, with root's environment variables; with the others, the shell is launched with root privilege but the environment and specifically $USER remain those of the logged-in user. When installing packages, $USER determines who will own and control the installed files.

Normally, Synaptic's launcher (at least in Gnome and XFCE) goes through a pop-up authentication window that effectively invokes gksudo to do the launch, and this problem never arises. To launch from a command line prompt, using "gksudo Synaptic" will get the same (good) result.

And I agree fully that going on line as "root" is never a good idea. Too many zero-day exploits abound to take the risk of losing everything!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
L.O.document font prints the size of Firefox default "noto sans 22" instead of "ns12" 1sweetwater! Linux - Software 1 02-11-2015 08:45 AM
[SOLVED] Firefox/Iceweasel workaround: "Open containing folder" with user defined filemanager devdol Linux - Software 15 07-28-2014 04:43 AM
How does one "zip" a folder with Linux .? How does Windows user "unzip" same ? brjoon1021 Linux - Software 5 12-19-2010 01:10 AM
Message at boot: "Choose a profile: 'default' or 'default.backup' " rm_-rf_windows Mandriva 1 07-07-2007 09:05 AM
FireFox killing "User Profile" DdTComp Linux - Software 6 02-15-2005 04:58 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 08:03 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration