Wrox Home  
Search P2P Archive for: Go

  Return to Index  

sql_language thread: What permissions do I need to give?


Message #1 by Jefferis Peterson <jefferis@p...> on Thu, 12 Dec 2002 17:11:10 -0500
It almost makes sense to me :-)

I use a remote host for web services, so the entire mysql db is tied via a
web site by the same company. The web site is on foma.pair.com and the
database has something like db15.pair.com

When set up the mysql has 3 user connection levels: admin [full access],
user 1 [read & write], user 2 [read only].
When creating a connection to input a new user and give them a password, I
need to know which connection user would be required to successfully let
them fill out a web form which is then submitted via php to the mysql
database through queries.  Currently I used a r & write permission
connection script, but I wonder if it is necessary.   I have the connection
script invisible in a hidden root folder, but I could store it in the site
itself if I could use read only.

The reason I'm asking is that suddenly my password connections aren't
working and I've got to redo something.

Jeff



On 12/13/02 4:26 AM, "Paul" <paul@d...> wrote:

> If the database server is on the same computer (localhost) that the Web
> server is on, then the two services are local to each other.
> 
> The database should have its own set of user accounts.  The Web server
> runs as one specific system user, call it user "apache".  I wouldn't
> give "apache" the ability to create database users.  Instead, create a
> special database user which has the permission to create new account,
> call it user "creator".  The user "creator" should have the ability to
> insert and maybe update entries in the database.
> 
> The account that the user "creator" creates could have any variety of
> permissions.  The permissions will only apply to the database, not files
> on the server.  Read and write are file system permissions, which are
> not applicable.  Select and insert are database permissions.
> 
> The new account wouldn't need to have any level of access.  If the user
> type in a login and password, a special database user could take over
> and check the validity of the user.  So, only one or two database users
> need to have direct access to the database.  The other users would just
> be data in the database!
> 
> (Did that make sense, and did I explain it well enough?)
> 

~~~~~~~~~~~~
Jefferis Peterson, Pres.
Web Design and Marketing
http://www.PetersonSales.com
Tel .  xxx-xxx-xxxx
ICQ 19112253

"One man gives freely, yet grows all the richer; another withholds what he
should give, and only suffers lack." -  Proverbs 11:24 


  Return to Index