14 - Authentication Flashcards
(49 cards)
process of verifying that someone is who they say they are
authentication
reasons for authentication (3)
- saving client-client data
- customizing user experience
- authorization/usage control
- user’s browsing or activity history
- list of API calls
saving client-client data
users have preferences and settings
customizing user experience
- different permissions for admin and regular users
- limit API calls over a set period of time
authorization/usage control
involves granting access to resources based on someone’s identity
authorization
true/false
a user can be authenticated, but not authorized to access a particular resource
true
what do we need for authentication (2)
- credentials
- authentication token or session id from the server
an identity and an authentication factor
credentials
used for subsequent requests that require authentication
authentication token or session id from the server
servers remember users with the use of ___ or ____
cookies, sessions
2 kinds of auth
- token-based auth
- session-based auth
the __ gives out tokens to clients
authenticating server
a string of data
token
a generic medium of information
token
true/false
tokens can either be signed or encrypted but not both
false, it can be signed, encrypted, both, or neither
auth tokens are usually at least ___
signed
a/an ___ message means that its origin can be verified
signed
a/an ___ message means that only its intended recipient can read it
encrypted
true/false
clients send an auth token with every request that needs authentication
true
how does authentication using a token work? (4)
- client logs in using credentials
- client receives auth token
- user sends the auth token instead of credentials
- server validates the auth token
how does session-based authentication work? (4)
- client logs in using credentials
- client receives a reference to the session
- user sends the session ID with subsequent requests
- server checks if session is still valid
users use their ___ to maintain their logged in state in session-based auth
session ID
what is the difference between session-based auth and token-based auth in terms of session info?
session-based auth: the server keeps all the session data
token-based auth: all session info can be kept in the token