Authorization
Në shqip: Autorizim
ShpjegimiSQ
Autorizimi vendos çfarë të lejohet të bësh pasi je identifikuar. P.sh. mësuesi mund t'i ndryshojë notat, ndërsa nxënësi vetëm mund t'i shohë.
EnglishEN
Authorization decides what you're allowed to do once you've been identified. For example, a teacher can change grades, while a student can only view them.
Si ta mendosh
Pasi hyn në stadium, bileta të tregon ku mund të ulesh: në tribunë apo në lozhën VIP. Hyrja është autentifikim, vendi është autorizim.
Lexoje në anglisht
Once you're inside the stadium, your ticket says where you may sit: the regular stand or the VIP box. Getting in is authentication; your seat is authorization.
Shembull kodipython
def ndrysho_noten(perdoruesi, nota):
if perdoruesi.roli != "mesues":
return "Nuk ke leje për këtë veprim."
# ...përndryshe ruaj notën e re