Skip to content

Commit 0b625f0

Browse files
committed
Q13 and Q1$
1 parent a318190 commit 0b625f0

File tree

1 file changed

+26
-3
lines changed

1 file changed

+26
-3
lines changed

README.md

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -953,8 +953,8 @@
953953
| 10| [What is Datamasking?](#what-is-datamasking)|
954954
| 11| [What is hashing and explain how it works?](#what-is-hashing-and-explain-how-it-works)|
955955
| 12| [What are salts and why are they so important?](#what-is-hashing-and-explain-how-it-works)|
956-
| 11| [What is hashing and explain how it works?](#what-is-hashing-and-explain-how-it-works)|
957-
| 11| [What is hashing and explain how it works?](#what-is-hashing-and-explain-how-it-works)|
956+
| 13| [What are pepper and why are they so important?](#what-is-hashing-and-explain-how-it-works)|
957+
| 14| [What are JWT?](#what-are-jwt)|
958958
959959
1. ### What is MongoDB?
960960
@@ -1154,9 +1154,32 @@
11541154

11551155
12. ### What are salts and why are they so important?
11561156

1157-
It's a unique value that can be added to the end of the password to create a different hash value. This adds a layer of security to the hashing process, specifically against brute force attacks(Trying all possible combintaion of password) and also against rainbow table(a table containing all common hashed text and their respective passwords)<br/>
1157+
It's a unique value that can be added to the end of the password to create a different hash value. This adds a layer of security to the hashing process<br/>
1158+
They are so important as they prevent **brute force attacks**(Trying all possible combintaion of password) and also against **rainbow table**(a table containing all common hashed text and their respective passwords)<br/>
1159+
1160+
**[⬆ Back to Top](#table-of-contents---mongodb-and-mongoose)**
1161+
1162+
13. ### What are pepper and why are they so important?
1163+
1164+
A pepper is a secret added to an input such as a password prior to being hashed with a cryptographic hash function<br/>
1165+
A pepper performs a comparable role to a salt, but while a salt is not secret (merely unique) and can be stored alongside the hashed output<br/> A pepper is secret and must not be stored with the output. The hash and salt are usually stored in a database, but a pepper must be stored separately (e.g. in a configuration file) to prevent it from being obtained by the attacker in case of a database breach. <br/> Where the salt only has to be long enough to be unique, a pepper has to be secure to remain secret (at least 112 bits is recommended by NIST), otherwise an attacker only needs one known entry to crack the pepper.<br/> Finally, the pepper must be generated anew for every application it is deployed in, otherwise a breach of one application would result in lowered security of another application.
1166+
1167+
11581168

11591169
**[⬆ Back to Top](#table-of-contents---mongodb-and-mongoose)**
11601170

1171+
14. ### What are JWT?
1172+
1173+
JSON Web Token (JWT) is an open standard (RFC 7519) that defines a compact and self-contained way for securely transmitting information between parties as a JSON object<br/>
1174+
some scenarios where JSON Web Tokens are useful:<br/>
1175+
**Authorization**: This is the most common scenario for using JWT. Once the user is logged in, each subsequent request will include the JWT, allowing the user to access routes, services, and resources that are permitted with that token. Single Sign On is a feature that widely uses JWT nowadays, because of its small overhead and its ability to be easily used across different domains.<br/>
1176+
1177+
**Information Exchange**: JSON Web Tokens are a good way of securely transmitting information between parties. Because JWTs can be signed—for example, using public/private key pairs—you can be sure the senders are who they say they are. Additionally, as the signature is calculated using the header and the payload, you can also verify that the content hasn't been tampered with.<br/>
1178+
1179+
![jwt](https://research.securitum.com/wp-content/uploads/sites/2/2019/10/jwt_ng1_en.png)
11611180

11621181

1182+
1183+
**[⬆ Back to Top](#table-of-contents---mongodb-and-mongoose)**
1184+
1185+

0 commit comments

Comments
 (0)