Please go through the points below and answer questions in the comments and discuss them with your mates.
- What are the benefits of registration and signing in on GitHub?
- What is the difference between authentication and authorization?
- How can we prevent a request from being fulfilled? Like trying to access a private GitHub repo of someone else?
- After the user logs in using the backend end-point we create, how can we can keep that user logged in all the time without asking them to login again each time they visit the website or send a request that require authentication?
- What is base64 encoding?
- What are salt rounds? how does it work?
- What is Caesar Cipher? How only the communicating sides knows how to decrypt the message?
Noor Awied, Ezgi Okur, Mohammad Sheikh Ibrahim
1- What are the benefits of registration and signing in on GitHub?
You can upload your projects to share with others.
You can connect with others - follow your teammates or users whom you like their work.
You can use forking to copy someone's work and work on it.
You can watch others' codes and the development of it.
You can use like to see the projects or posts later.
You can reach your projects from multiple devices.
You can save your progression and keep track of your project and continue working later.
2- What is the difference between authentication and authorization?
Authentication:
The process of verifying the identity of the person making the request. it is done using passwords and pins and other data provided by the user. authentication is one of the first most important steps for managing what a user can access.
rely on information like : what you know: ex password, what you possess: ex token , what you are: ex biometrics
Authorization:
determining what files, data,...etc the user can access in an application.it is done by certain permissions and settings that are set by the application developers.Authorization cannot be done without authentication so it’s the step after authenticating the user.
Most popular techniques: Role-based authorization: by the roles defined by the organization for your authenticated account, Attribute-based authorization: bu following a series of certain attributes
3- How can we prevent a request from being fulfilled? Like trying to access a private GitHub repo of someone else?
by setting up authorization process in the api, we could put access management policies
4- After the user logs in using the backend end-point we create, how can we can keep that user logged in all the time without asking them to login again each time they visit the website or send a request that require authentication?
use either JSON Web Tokens (JWTs) or sessions to keep track of user login, because When we browse the web we use HTTP, which is a stateless protocol. So, the only way to remember the states of our application is using either sessions or tokens.
5- What is base64 encoding?
The base64 is a binary to a text encoding scheme that represents binary data in an ASCII string format. It is designed to carry data stored in binary format across the channels. It helps your data to end up to the other side safely without any corruption. It prevents these types of situations like -some protocols interpret your binary data as control characters (like a modem), or your binary data could be screwed up because the underlying protocol might think that you've entered a special character combination (like how FTP translates line endings). It takes any form of data and transforms it into a long string of plain text. base64 uses only 6-bits(2⁶ = 64 characters) to ensure the printable data is human readable.
6- What are salt rounds? how does it work?
Bcypt is a password hashing function that allows building a password security platform that can evolve alongside hardware technology.It uses the expensive key setup phase of the Blowfish cipher.
cryptographic salt is made up of random bits added to each password instance before its hashing. Salts create unique passwords even in the instance of two users choosing the same passwords.The salt is usually included in the resulting hash-string in readable form. So with storing the hash-string you also store the salt.
A salt round means the cost factor. The cost factor controls how much time is needed to calculate a single BCrypt hash.
When BCrypt was first published, in 1999, they listed their implementation's default cost factors:
normal user: 6
super user: 8
A bcrypt cost of 6 means 64 rounds (26 = 64).
Every BCrypt implementation uses 10 as the default cost.
7- What is Caesar Cipher? How only the communicating sides knows how to decrypt the message?
a Caesar cipher, also known as Caesar's cipher, the shift cipher, Caesar's code or Caesar shift, is one of the simplest and most widely known encryption techniques. It is a type of substitution cipher in which each letter in the plaintext is replaced by a letter some fixed number of positions down the alphabet. For example, with a left shift of 3, D would be replaced by A, E would become B, and so on.