473,386 Members | 1,773 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

NT/LM and Unix Crypt Hash Creation in C#

bb
I have a requirement to create and store in our database the users
password in a couple of additional hashes (we currently store an MD5
hash)

the spec is pretty brief...

Spec:
Store the NT Hash and Unix Crypt of password when a user
creates/modifies password
End.

Ive had a sniff around and not really found many good resources on how
these methods of hash creation are performed. I understood unix crypt
uses DES and i get a result like this when doing it on the unix shell

$ crypt google
nWw/IiIxKckm2

the NT/LM one seems to be a bit different, and various websites suggest
there are two hashes "The NTLM, NTLMv2, and Kerberos all use the NT
hash, also known as the Unicode hash. The LM authentication protocol
uses the LM hash."

I'd like to know how to create both!

Any pointers on this about preferably inbuild c# classes which will
create these hashes, or some keywords or urls for me to have a sniff
on.

Nov 17 '05 #1
1 4720
Hi,

bb wrote:
I understood unix crypt uses DES and i get a
result like this when doing it on the unix shell


This may or may not be relevant to your project, but MD5 crypt is more
commonly used today, while DES crypt is supported mainly for backwards
compatibility. MD5 encrypted password strings begin with the magic
characters "$1$" and are significantly longer.

Reference code for either of these should be very easy to find, thanks to
Linux and FreeBSD -- just Google something like "DES crypt source" or "MD5
crypt source".
--
Chris Priede
Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Paul Fournier | last post by:
Just wondering, does anyone know if the crypt() function in PHP will always return a 34 character string if not salted? I want to encrypt my user's passwords into a database and I want to make...
8
by: Ryan Lange | last post by:
I've seen md5() suggested a lot when it comes to password encryption, but I'm wondering what the advantage is over using crypt(). Or is it just personal preference? - Ryan
1
by: Marco Herrn | last post by:
Hi, I don't know wether this is really the best place for asking this question. If you know a better, please tell me. The problem is an understanding of the 3 modules for hash algorithms. I need...
0
by: aars | last post by:
Hello all, I am creating a user administration system where system administrator can activate services for a user, like webspace, a mail account or a subdomain. I now want to create a...
0
by: Walter Zydhek | last post by:
I have just finished porting and debugging a publicly available crypt(3) function as is used by Unix. I have ported it to a Managed C++ Class Library that can be used but such languages as...
4
by: eight02645999 | last post by:
hi i created a login page that authenticate the user and his/her password to the unix ssystem. what modules can i used to compare the unix password with what the user typed in the cgi form? the...
2
by: Carsten Maul | last post by:
Hi, I want to generate an MD5 checksum with crypt.h, installed OS Debian Woody. Unfortunately I only get DES hashes with strncpy(salt, row, 12); salt = '\0'; encryptedPass = crypt(passwd,...
1
by: Bilge TUTAK | last post by:
Hi All, Is there a function like crypt() of PHP. I want to verify a password using that password. It uses the password hash(from db,AD,or elsewhere) and the password user entered and returns the...
2
by: amygdala | last post by:
Hi, Does anybody now of a custom crypt function that implements sha1? The thing I like about crypt is that I don't have to worry about (re)generating salt when querying the database. Or are...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.