Thursday, June 2, 2011

TIP: Target MySql Users to Specific Hosts and Database

It is a good practice when creating MySql users to bind the target user to a specific host.

mysql> CREATE USER 'John'@'192.168.1.1';
mysql> SELECT User, Host, Password FROM mysql.user; /* Show the list of users to verifiy */

Then you can create a database and target the user to that database in the above case, user "John".

mysql> CREATE DATABASE new;
mysql> GRANT SELECT , INSERT , UPDATE , DELETE ON new . * TO 'John'@'192.168.1.1';

Now user John can only access the database from host 192.168.1.1 and only have access to database "new".

11 comments:

designing said...

nice and informative topic i like this informative topic keep sharing.

Unknown said...

Sergei , October 22, 1970 Born in Christian Louboutin Bois Dore Moscow State Ozherelye. Perhaps influenced by Cheap LV Handbags their parents worship warrior army, join the army in cheap jordans 1989, and into the elite airborne military service. 1991, by the influence of the Soviet Union, the uggs on sale Russian christian louboutin army general lack of funds, a large number ugg australia of Air Jordan 11 Gamma Blue soldiers seeking veterans, but under extremely difficult conditions still dedicated, praise superiors, and soon was sent to the famous christian louboutin shoes Ryazan Higher ugg Airborne Command School studies. After graduating in 1994, entered the famous Pskov 76th Guards Airborne discount christian louboutin Division, served as discount nike jordans the reconnaissance platoon, reconnaissance ugg soldes deputy company commander, company commander, battalion airborne regiment scouting director and other duties.From 2000 to Cheap Louis Vuitton Handbags 2004, where the forces have repeatedly ordered war with Chechen militants. Because of their opponents in order to form the squad activity and haunted impermanence, the Russians had to ugg boots mobilize elite troops set up large uggs outlet number of small units, "a Discount Louis Vuitton small wholesale jordan shoes play small" Implementation siege. commanding troops in Chechnya, Christian Louboutin Daffodile Ingushetia and other places over the mountains, to track the militants fled. Discount LV Handbags Although the militants were extremely vigilant, but as long as the task has never had outsmarted.August 8, 2008, Georgia suddenly invade South Ossetia (Russian peacekeepers stationed ugg pas cher there), the Russian military to respond quickly, including including the 76th Guards Airborne Division, more than christian louboutin remise 50% 3,000 people were immediately delivered to the pro-Russian Abkhazia, Georgia cheap nike jordan shoes Army contain two infantry brigades, effectively coordinate the cheap christian louboutin direction of the Russian Bags Louis Vuitton troops in South Ossetia.

chenlina said...

chenlina20151127
michael kors outlet
canada goose
louis vuitton outlet
north face outlet
cheap jordan shoes
abercrombie kids
michael kors handbags
coach factory outlet
hollister
air max 90
air max uk
michael kors outlet online
cheap oakley sunglasses
michael kors outlet online
polo ralph lauren outlet
michael kors outlet
christian louboutin outlet
michael kors outlet
kids lebron shoes
prada handbags
coach factory outlet
ugg sale
coach outlet
cheap oakley sunglasses
cheap jordans
cheap uggs for sale
cheap uggs
hollister uk
fitflops
ugg boots
michaek kors handbags
tiffany and co
tod's shoes
true religion outlet
michael kors outlet
louis vuitton outlet
ugg sale
jordan 11s
cheap ray ban sunglasses
michael kors outlet
as

oakleyses said...

tory burch outlet, longchamp outlet, burberry, ray ban sunglasses, tiffany and co, nike outlet, replica watches, louis vuitton, ray ban sunglasses, nike air max, jordan shoes, polo ralph lauren outlet, michael kors outlet, tiffany jewelry, michael kors outlet, christian louboutin outlet, burberry outlet online, michael kors outlet, michael kors, oakley sunglasses, longchamp, prada outlet, prada handbags, cheap oakley sunglasses, oakley sunglasses, oakley sunglasses, ugg boots, louboutin shoes, michael kors outlet, ugg boots, polo ralph lauren outlet, louis vuitton outlet, nike free, chanel handbags, louboutin outlet, louis vuitton outlet, oakley sunglasses, ugg boots, replica watches, michael kors outlet, kate spade outlet, uggs on sale, nike air max, louboutin, louis vuitton, louis vuitton

oakleyses said...

air jordan pas cher, ray ban uk, nike roshe, true religion jeans, air force, abercrombie and fitch, north face, new balance pas cher, sac longchamp, longchamp pas cher, mulberry, oakley pas cher, nike free run uk, coach outlet, nike blazer, hermes, michael kors, nike air max, air max, hollister pas cher, true religion jeans, ralph lauren pas cher, vans pas cher, michael kors, coach outlet, true religion jeans, hollister, michael kors, north face, nike air max, nike roshe run, coach purses, burberry, lululemon, michael kors, lacoste pas cher, hogan, tn pas cher, sac guess, replica handbags, louboutin pas cher, vanessa bruno, timberland, kate spade handbags, converse pas cher, ralph lauren uk, nike free

oakleyses said...

moncler, moncler outlet, marc jacobs, moncler, hollister, montre pas cher, vans, ray ban, replica watches, pandora charms, louis vuitton, supra shoes, sac louis vuitton pas cher, pandora jewelry, swarovski, pandora charms, moncler, bottes ugg, barbour, canada goose, ugg,uggs,uggs canada, louis vuitton, doke gabbana outlet, converse, louis vuitton, lancel, louis vuitton, hollister, moncler, pandora jewelry, doudoune canada goose, juicy couture outlet, nike air max, converse outlet, barbour jackets, moncler, ugg,ugg australia,ugg italia, links of london, moncler, gucci, canada goose outlet, canada goose, canada goose outlet, coach outlet, canada goose uk, ugg boots uk, canada goose, juicy couture outlet, ugg pas cher, wedding dresses, canada goose

chenlina said...

chenlina20160127
canada goose jackets
cheap ugg boots
ugg boots
christian louboutin outlet
cheap toms
coach outlet
oakley sunglasses
ugg boots
toms outlet
abercrombie and fitch new york
vans shoes sale
louis vuitton outlet
coach factory outlet
ray ban sunglasses
longchamp outlet
fitflops sale clearance
coach factory outlet
michael kors bag
hollister
fake oakley sunglasses
tod's shoes
cheap jerseys
louis vuitton
gucci outlet
tory burch outlet
cheap air jordans
ugg boots
supra shoes
louis vuitton
oakley vault
cheap nfl jerseys
louis vuitton outlet
nike trainers uk
michael kors handbags
lebron 11
louis vuitton outlet
cheap oakley sunglasses
uggs outlet
ugg sale
polo outlet
as

Unknown said...

nike huarache
north face
michael kors outlet
lebron james shoes
ralph lauren outlet
michael kors handbags sale
new balance shoes
supra shoes sale
michael kors handbags
michael kors handbags

Unknown said...

michael kors outlet online
pandora bracelet
oakley sunglasses sale
true religion outlet
cheap nfl jerseys wholesale
true religion outlet online
louboutin outlet
tory burch flip flops
canada goose jackets
fitflops sandals
2017.6.27chenlixiang

Unknown said...

20180412xiaoke
birkenstock outlet
louis vuitton outlet store
pandora charms sale clearance
michael kors handbags
pandora outlet
replica rolex
ugg outlet
ugg boots clearance
christian louboutin shoes
oakley sunglasses sale

zzyytt said...

adidas eqt
vans outlet
kate spade outlet
yeezy
nike flyknit trainer
kayno
yeezy boost 350 v2
yeezys
adidas outlet
air max