Article View: alt.hacker
Article #48Re: shadow file
From: Walter Roberson
Date: Wed, 08 Dec 2004 17:11
Date: Wed, 08 Dec 2004 17:11
39 lines
2825 bytes
2825 bytes
In article <cp6ki9$je4$05$1@news.t-online.com>, Frank <lol@privacy.net> wrote: :i'd like to see if it's possible to decode this file.... :root:$1$BZftq3sP$xEeZmr2fGEnKjVAxzj/o51:12747:0:99999:7::: That looks like a standard /etc/shadow line in an OS that allows the glibc extensions to encrypted passwords. According to http://unixhelp.ed.ac.uk/CGI/man-cgi?crypt+3 GNU EXTENSION The glibc2 version of this function has the following additional fea- tures. If salt is a character string starting with the three charac- ters "$1$" followed by at most eight characters, and optionally termi- nated by "$", then instead of using the DES machine, the glibc crypt function uses an MD5-based algorithm, and outputs up to 34 bytes, namely "$1$<string>$", where "<string>" stands for the up to 8 charac- ters following "$1$" in the salt, followed by 22 bytes chosen from the set [a-zA-Z0-9./]. The entire key is significant here (instead of only the first 8 bytes). Thus, in order to decode the password, one would have to find a password whose MD5 was represented in base64 as xEeZmr2fGEnKjVAxzj/o51 . MD5 is a 128 bit hash, so brute force would require an average of 2^127 operations to find a match. That's a lot of computation. There are services which are generating pretty much all 8 bit lowercase + digit plaintexts and using MD5 to encrypt them and saving the result, but these services don't work with the "salted" MD5 of shadow password files. http://passcracking.com/ -- *We* are now the times. -- Wim Wenders (WoD)
Technical Details
Message-ID:
<cp7cjq$sqh$1@canopus.cc.umanitoba.ca>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!cyclone.bc.net!torn!canopus.cc.umanitoba.ca!not-for-mailReferences:
<cp6ki9$je4$05$1@news.t-online.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 102c45,4a0979912b4865b8 X-Google-Thread: fbc6f,4a0979912b4865b8 X-Google-Thread: 113446,4a0979912b4865b8 X-Google-Thread: 106e9e,4a0979912b4865b8 X-Google-Thread: ff723,4a0979912b4865b8 X-Google-Thread: 10952f,4a0979912b4865b8 X-Google-Attributes: gid102c45,gidfbc6f,gid113446,gid106e9e,gidff723,gid10952f,public X-Google-Language: ENGLISH,ASCII-7-bit Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!cyclone.bc.net!torn!canopus.cc.umanitoba.ca!not-for-mail From: roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson) Newsgroups: alt.hacker,alt.hacking,be.comp.security,comp.os.linux.security,comp.security.misc,comp.security.unix Subject: Re: shadow file Date: 8 Dec 2004 17:11:22 GMT Organization: National Research Council Canada - Conseil national de rechereches Canada Lines: 39 Message-ID: <cp7cjq$sqh$1@canopus.cc.umanitoba.ca> References: <cp6ki9$je4$05$1@news.t-online.com> NNTP-Posting-Host: zeno.ibd.nrc-cnrc.gc.ca X-Trace: canopus.cc.umanitoba.ca 1102525882 29521 192.70.172.31 (8 Dec 2004 17:11:22 GMT) X-Complaints-To: abuse@cc.umanitoba.ca NNTP-Posting-Date: 8 Dec 2004 17:11:22 GMT Originator: roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson)