Can I root access to the user?

Q: I have Mandrake 9.0 and I only have one user besides the root. It is annoying to install anything because it wont let me create directories or something. Is there an easy way to get my username admin access to?


Best Answer: Hi Tovia!
Leo has a good answer, but it depends on your server, and Godaddy is "not" what I would call the best one…
I would suggest you allow users to access the DB through a login-page on your front end website.
The users are stored in a table, and YOU give them your own access level. They then access the DB through a PhP code, where, for example, you have:
if ($userlevel > 3) $allowwrite = true else $allowwrite = false;
and so on. This will allow you to "grant access" with very fine parameters, one for each table, for each read, write, make, select and so on.
That way, on the other hand, lets YOU in control of the data-base: NO-one needs username/dbname/localhost/pwd…
It makes the code more complex, but MUCH safer!
Do not forget: They can't access Php scripts, but they KNOW the various Php Standard settings. So, if I have an address book on my PC, I will NOT call it "my addresses". I do not use any of "mydocuments", "mypictures", provided by MS for the unaware. Nor do I give my server's access to anyone, but through MY sequence of events! (and I change it regularly!)
IF you allow someone to upload (after logging-in) something to your server, load it in a "safe" directory. Then apply all possible checks provided by php. Eliminate anything that is even suspicious. Empty that directory contents' when the user leaves the site (use <body onunload=jscript>).
One last word: don't put real addresses on your request! :-) )
(DB_SERVER)

Re:Just make sure you learn the CLI. Don't stick in the GUI the entire time. Sure its nice, but the CLI is where the real power of linux comes in.

Re:I've got it dual booted, so it will be fun for me to learn it slowly, when I have free time.

Re:Originally posted by: guy
Thanks guys. Maybe I too will become a linux zealot someday :)

Why? I dont like Linux much, and Im doing fine with it, or I would if I used it :P


Re:Thanks guys. Maybe I too will become a linux zealot someday :)

Re:Setup sudo. It will temporarily give you root privs for some thing (whatever you configure it to give you those rights for). But do not change your uid to 0. That will cause problems and create an immense security hazard. If your normal user cannot create directories and whatnot in a particular location that may be a clue that you are doing something you shouldnt. Try ~/, since that is where most of your stuff should go anyhow.

Re:You probably don't want to give them root access because then it defeats the purpose of not logging in as root :)

Just get into a console and type 'su' to become root and install the packages and when you are finished, type 'exit' to return back to your regular user status.

Also, I'm not sure how Mandrake handles this but you can have a group called 'wheel' that gives a user many of the same privileges as root (it can't do rm -rf / , but hey ;) ) without having to login as root to do certain things.

-silver


Related posts

Leave a comment

0 Comments.

Leave a Reply


click to changeSecurity Code

[ Ctrl + Enter ]