SlideShare a Scribd company logo
Security
V. Saranya AP/CSE,
Sri Vidya College of Engg &
Tech, virudhunagar
• A DBMS
should
provide
a
mechanism
to
ensure that “only
authorized
users
can access the
database”
GRANT AND REVOKE
• SQL provides “GRANT” and “REVOKE”
statements to “allow security” to be set up
on the tables in the database.
Security Concepts
• Authorization identifiers
• Ownership
• privileges
Authorization Identifiers
• are “Database users” assigned by DBA.
Owner
• “Can pass privileges” on to other users using
the “GRANT” statement and can cancel the
privileges passed on using “REVOKE”
statement.
Privileges

• Are the actions that a user is permitted.
– Select privilege to retrieve data from the table
– Insert privilege to insert new rows into a table.
– Update Privilege to modify rows of data in a
table.
– Delete Privilege to delete rows of data from a
table.
– References Privilege to reference columns of a
named table in integrity constraints.
– Usage

Privilege
to
use
domains, collations, character sets and
translations.
Granting Privilege to other users
• Used to GRANT privileges on database objects
to specified users.
• GRANT statement is used by the owner of a
table to give other users access to the data.
Syntax

Used to grant all privileges to a
user instead of having to
specify the 6 privileges
individually

Syntax:
GRANT [privilege list / All PRIVILEGES]
On object name
To {authorization id list / PUBLIC }
Allow access to be granted to
[WITH GRANT OPTION]
all
present
and
future
Privilege list consists of one or more of the authorized users not just to the
users currently known to the
following
DBMS.
privileges separated by commas;
Select
Can be the name of a base
Delete
table, view, domain, character
Insert[ (column name[….]) ]
set, collation or translation
Update (column name[….]) ]
References (column name[….]) ]
Usage
Clause allows the users in
authorizationIdList to pass the
privileges to other user.
Example 1
Give the user with authorization identifier
manager full privileges to the staff table.

GRANT ALL PRIVILEGES
ON STAFF
TO manager WITH GRANT OPTION;
Example 2
Give users personnel and director the privileges
select and update on column salary of the staff
table.
GRANT SELECT ,UPDATE (salary)
ON staff
WITH GRANT FOR is
omitted, here the users
TO personnel, Director;
personnel & Director
cannot pass the
privileges on to other
users.
Example 3
Give all users the privileges SELECT on the
branch table.
GRANT SELECT
ON BRANCH
TO PUBLIC;

Means that all users
are able to retrieve all
the data in the branch
table.
REVOKE
• Revoke statement is used to take away all or
some of the privileges that were previously
granted to a user.
GRANT OPTION FOR allows
privileges passed on via the
WITH GRANT OPTION of the
GRANT statement to be revoked
from the privileges themselves.

Syntax
ALL PRIVILEGES granted to
a user by the user revoking
the privileges.

REVOKE [GRANT OPTION FOR] {privilege
List/ALL PRIVILEGES]
ON objectName
FROM { AuthorizationIdList / PUBLIC }
[RESTRICT / CASCADE]
Example 1
Revoke the privilege SELECT on the branch
table from all users.
REVOKE SELECT
ON branch
FROM PUBLIC;
Example 2
REVOKE all privileges you have given to
Director on the staff table.
REVOKE ALL PRIVILEGES
ON STAFF
FROM director;

More Related Content

Viewers also liked

Dmbs chapter vi
Dmbs chapter viDmbs chapter vi
Dmbs chapter vi
Bala Ganesh
 
Книги-юбиляры 2013 года
Книги-юбиляры 2013 годаКниги-юбиляры 2013 года
Книги-юбиляры 2013 годаnikola511
 
Resolution(decision)
Resolution(decision)Resolution(decision)
Resolution(decision)
Slideshare
 
Instance based learning
Instance based learningInstance based learning
Instance based learning
Slideshare
 
What is in you
What is in youWhat is in you
What is in you
Slideshare
 
Report generation
Report generationReport generation
Report generation
Slideshare
 
16 Queens Problem - trial 1
16 Queens Problem  - trial 116 Queens Problem  - trial 1
16 Queens Problem - trial 1Slideshare
 
Neural networks
Neural networksNeural networks
Neural networks
Slideshare
 
Girl Rights and Protection in India
Girl Rights and Protection in IndiaGirl Rights and Protection in India
Girl Rights and Protection in India
Aashray For Everyone
 
Security and Integrity
Security and IntegritySecurity and Integrity
Security and Integrity
lubna19
 
Logic agent
Logic agentLogic agent
Logic agent
Slideshare
 
Data preprocessing
Data preprocessingData preprocessing
Data preprocessing
Slideshare
 
Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010
Slideshare
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
Slideshare
 
Propositional logic & inference
Propositional logic & inferencePropositional logic & inference
Propositional logic & inference
Slideshare
 
Major issues in data mining
Major issues in data miningMajor issues in data mining
Major issues in data mining
Slideshare
 
Trigger
TriggerTrigger
Trigger
Slideshare
 
Logical reasoning
Logical reasoning Logical reasoning
Logical reasoning
Slideshare
 
Entity Relationship Model
Entity Relationship ModelEntity Relationship Model
Entity Relationship Model
Slideshare
 
6. Integrity and Security in DBMS
6. Integrity and Security in DBMS6. Integrity and Security in DBMS
6. Integrity and Security in DBMS
koolkampus
 

Viewers also liked (20)

Dmbs chapter vi
Dmbs chapter viDmbs chapter vi
Dmbs chapter vi
 
Книги-юбиляры 2013 года
Книги-юбиляры 2013 годаКниги-юбиляры 2013 года
Книги-юбиляры 2013 года
 
Resolution(decision)
Resolution(decision)Resolution(decision)
Resolution(decision)
 
Instance based learning
Instance based learningInstance based learning
Instance based learning
 
What is in you
What is in youWhat is in you
What is in you
 
Report generation
Report generationReport generation
Report generation
 
16 Queens Problem - trial 1
16 Queens Problem  - trial 116 Queens Problem  - trial 1
16 Queens Problem - trial 1
 
Neural networks
Neural networksNeural networks
Neural networks
 
Girl Rights and Protection in India
Girl Rights and Protection in IndiaGirl Rights and Protection in India
Girl Rights and Protection in India
 
Security and Integrity
Security and IntegritySecurity and Integrity
Security and Integrity
 
Logic agent
Logic agentLogic agent
Logic agent
 
Data preprocessing
Data preprocessingData preprocessing
Data preprocessing
 
Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
 
Propositional logic & inference
Propositional logic & inferencePropositional logic & inference
Propositional logic & inference
 
Major issues in data mining
Major issues in data miningMajor issues in data mining
Major issues in data mining
 
Trigger
TriggerTrigger
Trigger
 
Logical reasoning
Logical reasoning Logical reasoning
Logical reasoning
 
Entity Relationship Model
Entity Relationship ModelEntity Relationship Model
Entity Relationship Model
 
6. Integrity and Security in DBMS
6. Integrity and Security in DBMS6. Integrity and Security in DBMS
6. Integrity and Security in DBMS
 

Similar to Security in Relational model

Sql ch 15 - sql security
Sql ch 15 - sql securitySql ch 15 - sql security
Sql ch 15 - sql security
Mukesh Tekwani
 
Les01
Les01Les01
Les14
Les14Les14
Les13
Les13Les13
e computer notes - Controlling user access
e computer notes - Controlling user accesse computer notes - Controlling user access
e computer notes - Controlling user access
ecomputernotes
 
Database Security Methods, DAC, MAC,View
Database Security Methods, DAC, MAC,ViewDatabase Security Methods, DAC, MAC,View
Database Security Methods, DAC, MAC,View
Dr-Dipali Meher
 
Db pre
Db preDb pre
Db pre
frrobin
 
Clase 18 privilegios modificada
Clase 18 privilegios   modificadaClase 18 privilegios   modificada
Clase 18 privilegios modificada
Titiushko Jazz
 
Clase 18 privilegios modificada
Clase 18 privilegios   modificadaClase 18 privilegios   modificada
Clase 18 privilegios modificada
Titiushko Jazz
 
User Information in Oracle introduction.pptx
User Information in Oracle introduction.pptxUser Information in Oracle introduction.pptx
User Information in Oracle introduction.pptx
AzarHamid
 
Sql grant, revoke, privileges and roles
Sql grant, revoke, privileges and rolesSql grant, revoke, privileges and roles
Sql grant, revoke, privileges and roles
Vivek Singh
 
03_DP_300T00A_Secure_Environment.pptx
03_DP_300T00A_Secure_Environment.pptx03_DP_300T00A_Secure_Environment.pptx
03_DP_300T00A_Secure_Environment.pptx
KareemBullard1
 
Database models and DBMS languages
Database models and DBMS languagesDatabase models and DBMS languages
Database models and DBMS languages
DivyaKS12
 
Mysqldbatrainingsession12privilegesinmysql 170302152348
Mysqldbatrainingsession12privilegesinmysql 170302152348Mysqldbatrainingsession12privilegesinmysql 170302152348
Mysqldbatrainingsession12privilegesinmysql 170302152348
shubham singh
 
Chapter 6 Database Security and Authorization (4).pdf
Chapter 6 Database Security and Authorization (4).pdfChapter 6 Database Security and Authorization (4).pdf
Chapter 6 Database Security and Authorization (4).pdf
abrehamcheru14
 
Security and Authorization
Security and AuthorizationSecurity and Authorization
Security and Authorization
Megha yadav
 
Les14[1]Controlling User Access
Les14[1]Controlling User AccessLes14[1]Controlling User Access
Les14[1]Controlling User Access
siavosh kaviani
 
8034.ppt
8034.ppt8034.ppt
8034.ppt
ssuser77162c
 
Trigger in DBMS
Trigger in DBMSTrigger in DBMS
Trigger in DBMS
A. S. M. Shafi
 
UNIT-1-Security.ppt
UNIT-1-Security.pptUNIT-1-Security.ppt
UNIT-1-Security.ppt
DharaDarji5
 

Similar to Security in Relational model (20)

Sql ch 15 - sql security
Sql ch 15 - sql securitySql ch 15 - sql security
Sql ch 15 - sql security
 
Les01
Les01Les01
Les01
 
Les14
Les14Les14
Les14
 
Les13
Les13Les13
Les13
 
e computer notes - Controlling user access
e computer notes - Controlling user accesse computer notes - Controlling user access
e computer notes - Controlling user access
 
Database Security Methods, DAC, MAC,View
Database Security Methods, DAC, MAC,ViewDatabase Security Methods, DAC, MAC,View
Database Security Methods, DAC, MAC,View
 
Db pre
Db preDb pre
Db pre
 
Clase 18 privilegios modificada
Clase 18 privilegios   modificadaClase 18 privilegios   modificada
Clase 18 privilegios modificada
 
Clase 18 privilegios modificada
Clase 18 privilegios   modificadaClase 18 privilegios   modificada
Clase 18 privilegios modificada
 
User Information in Oracle introduction.pptx
User Information in Oracle introduction.pptxUser Information in Oracle introduction.pptx
User Information in Oracle introduction.pptx
 
Sql grant, revoke, privileges and roles
Sql grant, revoke, privileges and rolesSql grant, revoke, privileges and roles
Sql grant, revoke, privileges and roles
 
03_DP_300T00A_Secure_Environment.pptx
03_DP_300T00A_Secure_Environment.pptx03_DP_300T00A_Secure_Environment.pptx
03_DP_300T00A_Secure_Environment.pptx
 
Database models and DBMS languages
Database models and DBMS languagesDatabase models and DBMS languages
Database models and DBMS languages
 
Mysqldbatrainingsession12privilegesinmysql 170302152348
Mysqldbatrainingsession12privilegesinmysql 170302152348Mysqldbatrainingsession12privilegesinmysql 170302152348
Mysqldbatrainingsession12privilegesinmysql 170302152348
 
Chapter 6 Database Security and Authorization (4).pdf
Chapter 6 Database Security and Authorization (4).pdfChapter 6 Database Security and Authorization (4).pdf
Chapter 6 Database Security and Authorization (4).pdf
 
Security and Authorization
Security and AuthorizationSecurity and Authorization
Security and Authorization
 
Les14[1]Controlling User Access
Les14[1]Controlling User AccessLes14[1]Controlling User Access
Les14[1]Controlling User Access
 
8034.ppt
8034.ppt8034.ppt
8034.ppt
 
Trigger in DBMS
Trigger in DBMSTrigger in DBMS
Trigger in DBMS
 
UNIT-1-Security.ppt
UNIT-1-Security.pptUNIT-1-Security.ppt
UNIT-1-Security.ppt
 

More from Slideshare

OLAP
OLAPOLAP
Logical reasoning 21.1.13
Logical reasoning 21.1.13Logical reasoning 21.1.13
Logical reasoning 21.1.13
Slideshare
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
Slideshare
 
Reinforcement learning 7313
Reinforcement learning 7313Reinforcement learning 7313
Reinforcement learning 7313
Slideshare
 
Neural networks
Neural networksNeural networks
Neural networks
Slideshare
 
Instance based learning
Instance based learningInstance based learning
Instance based learning
Slideshare
 
Input & output devices
Input & output devicesInput & output devices
Input & output devices
Slideshare
 
Accessing I/O Devices
Accessing I/O DevicesAccessing I/O Devices
Accessing I/O Devices
Slideshare
 
16 queens problem - trial 2
16 queens problem - trial 216 queens problem - trial 2
16 queens problem - trial 2Slideshare
 
Basic Processing Unit
Basic Processing UnitBasic Processing Unit
Basic Processing Unit
Slideshare
 
Cache performance considerations
Cache performance considerationsCache performance considerations
Cache performance considerations
Slideshare
 
Cachememory
CachememoryCachememory
Cachememory
Slideshare
 
Memory management
Memory managementMemory management
Memory management
Slideshare
 
Secondary storage devices
Secondary storage devices Secondary storage devices
Secondary storage devices
Slideshare
 
Magnetic tape system
Magnetic tape systemMagnetic tape system
Magnetic tape system
Slideshare
 

More from Slideshare (15)

OLAP
OLAPOLAP
OLAP
 
Logical reasoning 21.1.13
Logical reasoning 21.1.13Logical reasoning 21.1.13
Logical reasoning 21.1.13
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
 
Reinforcement learning 7313
Reinforcement learning 7313Reinforcement learning 7313
Reinforcement learning 7313
 
Neural networks
Neural networksNeural networks
Neural networks
 
Instance based learning
Instance based learningInstance based learning
Instance based learning
 
Input & output devices
Input & output devicesInput & output devices
Input & output devices
 
Accessing I/O Devices
Accessing I/O DevicesAccessing I/O Devices
Accessing I/O Devices
 
16 queens problem - trial 2
16 queens problem - trial 216 queens problem - trial 2
16 queens problem - trial 2
 
Basic Processing Unit
Basic Processing UnitBasic Processing Unit
Basic Processing Unit
 
Cache performance considerations
Cache performance considerationsCache performance considerations
Cache performance considerations
 
Cachememory
CachememoryCachememory
Cachememory
 
Memory management
Memory managementMemory management
Memory management
 
Secondary storage devices
Secondary storage devices Secondary storage devices
Secondary storage devices
 
Magnetic tape system
Magnetic tape systemMagnetic tape system
Magnetic tape system
 

Recently uploaded

spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skillsspot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
haiqairshad
 
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UPLAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
RAHUL
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
GeorgeMilliken2
 
Pharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brubPharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brub
danielkiash986
 
Beyond Degrees - Empowering the Workforce in the Context of Skills-First.pptx
Beyond Degrees - Empowering the Workforce in the Context of Skills-First.pptxBeyond Degrees - Empowering the Workforce in the Context of Skills-First.pptx
Beyond Degrees - Empowering the Workforce in the Context of Skills-First.pptx
EduSkills OECD
 
The History of Stoke Newington Street Names
The History of Stoke Newington Street NamesThe History of Stoke Newington Street Names
The History of Stoke Newington Street Names
History of Stoke Newington
 
Electric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger HuntElectric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger Hunt
RamseyBerglund
 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
PECB
 
Standardized tool for Intelligence test.
Standardized tool for Intelligence test.Standardized tool for Intelligence test.
Standardized tool for Intelligence test.
deepaannamalai16
 
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptxPengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Fajar Baskoro
 
RHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem students
RHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem studentsRHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem students
RHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem students
Himanshu Rai
 
Présentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Présentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptxPrésentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Présentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
siemaillard
 
Nutrition Inc FY 2024, 4 - Hour Training
Nutrition Inc FY 2024, 4 - Hour TrainingNutrition Inc FY 2024, 4 - Hour Training
Nutrition Inc FY 2024, 4 - Hour Training
melliereed
 
math operations ued in python and all used
math operations ued in python and all usedmath operations ued in python and all used
math operations ued in python and all used
ssuser13ffe4
 
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching AptitudeUGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
S. Raj Kumar
 
SWOT analysis in the project Keeping the Memory @live.pptx
SWOT analysis in the project Keeping the Memory @live.pptxSWOT analysis in the project Keeping the Memory @live.pptx
SWOT analysis in the project Keeping the Memory @live.pptx
zuzanka
 
B. Ed Syllabus for babasaheb ambedkar education university.pdf
B. Ed Syllabus for babasaheb ambedkar education university.pdfB. Ed Syllabus for babasaheb ambedkar education university.pdf
B. Ed Syllabus for babasaheb ambedkar education university.pdf
BoudhayanBhattachari
 
Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"
National Information Standards Organization (NISO)
 
BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...
BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...
BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...
Nguyen Thanh Tu Collection
 
HYPERTENSION - SLIDE SHARE PRESENTATION.
HYPERTENSION - SLIDE SHARE PRESENTATION.HYPERTENSION - SLIDE SHARE PRESENTATION.
HYPERTENSION - SLIDE SHARE PRESENTATION.
deepaannamalai16
 

Recently uploaded (20)

spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skillsspot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
 
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UPLAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
 
Pharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brubPharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brub
 
Beyond Degrees - Empowering the Workforce in the Context of Skills-First.pptx
Beyond Degrees - Empowering the Workforce in the Context of Skills-First.pptxBeyond Degrees - Empowering the Workforce in the Context of Skills-First.pptx
Beyond Degrees - Empowering the Workforce in the Context of Skills-First.pptx
 
The History of Stoke Newington Street Names
The History of Stoke Newington Street NamesThe History of Stoke Newington Street Names
The History of Stoke Newington Street Names
 
Electric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger HuntElectric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger Hunt
 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
 
Standardized tool for Intelligence test.
Standardized tool for Intelligence test.Standardized tool for Intelligence test.
Standardized tool for Intelligence test.
 
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptxPengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptx
 
RHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem students
RHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem studentsRHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem students
RHEOLOGY Physical pharmaceutics-II notes for B.pharm 4th sem students
 
Présentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Présentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptxPrésentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Présentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
 
Nutrition Inc FY 2024, 4 - Hour Training
Nutrition Inc FY 2024, 4 - Hour TrainingNutrition Inc FY 2024, 4 - Hour Training
Nutrition Inc FY 2024, 4 - Hour Training
 
math operations ued in python and all used
math operations ued in python and all usedmath operations ued in python and all used
math operations ued in python and all used
 
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching AptitudeUGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
 
SWOT analysis in the project Keeping the Memory @live.pptx
SWOT analysis in the project Keeping the Memory @live.pptxSWOT analysis in the project Keeping the Memory @live.pptx
SWOT analysis in the project Keeping the Memory @live.pptx
 
B. Ed Syllabus for babasaheb ambedkar education university.pdf
B. Ed Syllabus for babasaheb ambedkar education university.pdfB. Ed Syllabus for babasaheb ambedkar education university.pdf
B. Ed Syllabus for babasaheb ambedkar education university.pdf
 
Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"
 
BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...
BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...
BÀI TẬP BỔ TRỢ TIẾNG ANH LỚP 9 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2024-2025 - ...
 
HYPERTENSION - SLIDE SHARE PRESENTATION.
HYPERTENSION - SLIDE SHARE PRESENTATION.HYPERTENSION - SLIDE SHARE PRESENTATION.
HYPERTENSION - SLIDE SHARE PRESENTATION.
 

Security in Relational model

  • 1. Security V. Saranya AP/CSE, Sri Vidya College of Engg & Tech, virudhunagar
  • 2. • A DBMS should provide a mechanism to ensure that “only authorized users can access the database”
  • 3. GRANT AND REVOKE • SQL provides “GRANT” and “REVOKE” statements to “allow security” to be set up on the tables in the database.
  • 4. Security Concepts • Authorization identifiers • Ownership • privileges
  • 5. Authorization Identifiers • are “Database users” assigned by DBA.
  • 6. Owner • “Can pass privileges” on to other users using the “GRANT” statement and can cancel the privileges passed on using “REVOKE” statement.
  • 7. Privileges • Are the actions that a user is permitted. – Select privilege to retrieve data from the table – Insert privilege to insert new rows into a table. – Update Privilege to modify rows of data in a table. – Delete Privilege to delete rows of data from a table. – References Privilege to reference columns of a named table in integrity constraints. – Usage  Privilege to use domains, collations, character sets and translations.
  • 8. Granting Privilege to other users • Used to GRANT privileges on database objects to specified users. • GRANT statement is used by the owner of a table to give other users access to the data.
  • 9. Syntax Used to grant all privileges to a user instead of having to specify the 6 privileges individually Syntax: GRANT [privilege list / All PRIVILEGES] On object name To {authorization id list / PUBLIC } Allow access to be granted to [WITH GRANT OPTION] all present and future Privilege list consists of one or more of the authorized users not just to the users currently known to the following DBMS. privileges separated by commas; Select Can be the name of a base Delete table, view, domain, character Insert[ (column name[….]) ] set, collation or translation Update (column name[….]) ] References (column name[….]) ] Usage Clause allows the users in authorizationIdList to pass the privileges to other user.
  • 10. Example 1 Give the user with authorization identifier manager full privileges to the staff table. GRANT ALL PRIVILEGES ON STAFF TO manager WITH GRANT OPTION;
  • 11. Example 2 Give users personnel and director the privileges select and update on column salary of the staff table. GRANT SELECT ,UPDATE (salary) ON staff WITH GRANT FOR is omitted, here the users TO personnel, Director; personnel & Director cannot pass the privileges on to other users.
  • 12. Example 3 Give all users the privileges SELECT on the branch table. GRANT SELECT ON BRANCH TO PUBLIC; Means that all users are able to retrieve all the data in the branch table.
  • 13. REVOKE • Revoke statement is used to take away all or some of the privileges that were previously granted to a user.
  • 14. GRANT OPTION FOR allows privileges passed on via the WITH GRANT OPTION of the GRANT statement to be revoked from the privileges themselves. Syntax ALL PRIVILEGES granted to a user by the user revoking the privileges. REVOKE [GRANT OPTION FOR] {privilege List/ALL PRIVILEGES] ON objectName FROM { AuthorizationIdList / PUBLIC } [RESTRICT / CASCADE]
  • 15. Example 1 Revoke the privilege SELECT on the branch table from all users. REVOKE SELECT ON branch FROM PUBLIC;
  • 16. Example 2 REVOKE all privileges you have given to Director on the staff table. REVOKE ALL PRIVILEGES ON STAFF FROM director;