Date: Sat, 08 Sep 2012 02:53:30 +0400 From: Alexander Cherepanov <cherepan@...me.ru> To: john-dev@...ts.openwall.com Subject: Formatting hashes (was: Re: Cracking Mountain Lion hashes (WIP)) Dhiru, all, Solar - On 2012-09-07 22:22, Dhiru Kholia wrote: > See attached code and earlier archive (use lulu.plist from it) > > $ml$23923*32*c3fa2e153466f7619286024fe7d812d0a8ae836295f84b9133ccc65456519fc3*128*ccb903ee691ade6d5dee9b3c6931ebed6ddbb1348f1b26c21add8ba0d45f27e61e97c0b80d9a18020944bb78f1ebda6fdd79c5cf08a12c80522caf987c287b6da10095bb8fd82fcc03803e86675d84744139b694da7cead3c0133033a6257335cb6be0ad68c14f20321315f0ea71670a8b78bc2759ad9751430f0c9c5040617a Is including lengths into the hash really useful? Isn't it better to use just $ between parts like this: $ml$23923$c3fa2e153466f7619286024fe7d812d0a8ae836295f84b9133ccc65456519fc3$ccb903ee691ade6d5dee9b3c6931ebed6ddbb1348f1b26c21add8ba0d45f27e61e97c0b80d9a18020944bb78f1ebda6fdd79c5cf08a12c80522caf987c287b6da10095bb8fd82fcc03803e86675d84744139b694da7cead3c0133033a6257335cb6be0ad68c14f20321315f0ea71670a8b78bc2759ad9751430f0c9c5040617a ? Next question is about encoding. Maybe it's better to use base64 instead of hex? Hashes would be much shorter. Maybe even totally mimic sha512crypt: $<prefix>$rounds=<rounds>$<salt>$<checksum> , where <salt> and <checksum> are base64-encoded? (Salt is not really encoded in sha512crypt but it doesn't matter here.) There are two things to consider here: - memory consumption (IIUC john stores hashes in their original text form); - parsing speed (at load time and in cmp_exact). And there cases of tens of thousands of hashes (like CMIYC) or even hundreds of millions (like Korelogic's files). Probably there should be guidelines for choosing formats for new hash types... -- Alexander Cherepanov
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.