Click here to Skip to main content
15,899,126 members
Home / Discussions / Database
   

Database

 
AnswerRe: DateTime Conversion Error Pin
Ritesh12347-Mar-06 1:40
Ritesh12347-Mar-06 1:40 
AnswerRe: DateTime Conversion Error Pin
jonathan157-Mar-06 1:44
jonathan157-Mar-06 1:44 
AnswerRe: DateTime Conversion Error Pin
HimaBindu Vejella8-Mar-06 0:14
HimaBindu Vejella8-Mar-06 0:14 
QuestionProcedure Pin
Support1236-Mar-06 23:20
Support1236-Mar-06 23:20 
AnswerRe: Procedure Pin
goyal manish8-Mar-06 3:12
goyal manish8-Mar-06 3:12 
GeneralRe: Procedure Pin
Support1238-Mar-06 3:14
Support1238-Mar-06 3:14 
QuestionPassword Encryption Pin
Brendan Vogt6-Mar-06 19:52
Brendan Vogt6-Mar-06 19:52 
AnswerRe: Password Encryption Pin
Colin Angus Mackay8-Mar-06 2:36
Colin Angus Mackay8-Mar-06 2:36 
ma se wrote:
What is the difference between the 2?


The password is a salted-hash. The PasswordSalt is the salt value used by the hashing algorithm (and I'll get to what that is in a moment). Basically the idea is that a dictionary could be built containing a set of common passwords and their corresponding hash values. This makes reversing the database very easy. A hash is a one-way encryption of some data, you cannot take the hashed value in the Password column and reverse it in to the original password (hence the need for a dictionary to be built).

Now, there is also the scenario that Alice and Mallory are users on a system. Unknown to each other they have chosen the same password. The hash values of that password will be the same. If Mallory happens to see the table in the database and sees that the hash value for his password and Alice's password are the same, he can conclude that they both have the same password and he can then malliciously gain access to Alice's account. This is bad.

So, to reduce the effectiveness of a dictionary attack and the consequence of happening to have the same password as some other user you can add a salt value to the password. This effectively adds a random element that makes the resulting hash values very different.

The salt can be known as it gives no real benefit to the attacker. The dictionary is useless because it would have to be regenerated by adding the salt value on to each plain text value and re-hashing it and then comparing the hash values. So, the effect is back to doing a brute force attack which is slow.

ma se wrote:
Are both required?


Yes, both are required. When a user types a password, the known salt is added to it and it is then hashed. The hash value in the database is compared with the hash value generated by the user input+salt. If the salted hash values match then the user can be given access. If you take away the salt values then the user cannot be authenticated.

Does this help?

ColinMackay.net
Scottish Developers are looking for speakers for user group sessions over the next few months. Do you want to know more?

QuestionRe: Password Encryption Pin
Brendan Vogt8-Mar-06 2:47
Brendan Vogt8-Mar-06 2:47 
AnswerRe: Password Encryption Pin
Colin Angus Mackay8-Mar-06 3:05
Colin Angus Mackay8-Mar-06 3:05 
QuestionORA:12535 TNS Timed out issue Pin
vhariharan6-Mar-06 14:24
vhariharan6-Mar-06 14:24 
Questionclob into oracle Pin
Lash206-Mar-06 10:44
Lash206-Mar-06 10:44 
QuestionStored procedure should only update supplied values. Pin
MY12016-Mar-06 3:06
MY12016-Mar-06 3:06 
AnswerRe: Stored procedure should only update supplied values. Pin
Colin Angus Mackay6-Mar-06 4:32
Colin Angus Mackay6-Mar-06 4:32 
AnswerRe: Stored procedure should only update supplied values. Pin
Chandana Subasinghe6-Mar-06 13:06
Chandana Subasinghe6-Mar-06 13:06 
QuestionData exceeds length of varchar datatype Pin
smadan6-Mar-06 0:30
smadan6-Mar-06 0:30 
AnswerRe: Data exceeds length of varchar datatype Pin
Colin Angus Mackay6-Mar-06 0:49
Colin Angus Mackay6-Mar-06 0:49 
GeneralRe: Data exceeds length of varchar datatype Pin
Dinuj Nath6-Mar-06 0:58
Dinuj Nath6-Mar-06 0:58 
GeneralRe: Data exceeds length of varchar datatype Pin
Colin Angus Mackay6-Mar-06 1:24
Colin Angus Mackay6-Mar-06 1:24 
GeneralRe: Data exceeds length of varchar datatype Pin
Dinuj Nath6-Mar-06 1:29
Dinuj Nath6-Mar-06 1:29 
GeneralRe: Data exceeds length of varchar datatype Pin
smadan6-Mar-06 1:21
smadan6-Mar-06 1:21 
AnswerRe: Data exceeds length of varchar datatype Pin
HimaBindu Vejella8-Mar-06 0:19
HimaBindu Vejella8-Mar-06 0:19 
GeneralRe: Data exceeds length of varchar datatype Pin
smadan8-Mar-06 0:42
smadan8-Mar-06 0:42 
QuestionDataSets and VS2005 Pin
slappe5-Mar-06 23:16
slappe5-Mar-06 23:16 
QuestionDevelopin Import Export tool Pin
tusha5-Mar-06 20:20
tusha5-Mar-06 20:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.