Security and Cryptography
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsSystem AdministrationSecurity and Cryptography

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old March 15th, 2012, 10:26 PM
CryptoQuestion CryptoQuestion is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2012
Posts: 1 CryptoQuestion User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 25 m 11 sec
Reputation Power: 0
Crypto Algorithm Evaluation - Interesting numerical hash

I got a numeric string. Decrypted text (plaintext) is not in english, it's in croatian, so it contains some non english chars (link - cannot link it, cause im new here, just google 'croatian alphabet', and head to the wiki result, which was second result on my pc, or just see my php code below).
Every alphabet char is represented by its numeric position key in the alphabet. So, a is 1, b is 2, c is 3 and so forth. Beware the differences between the languages, though, as we don't have q and w, but have some other chars.
The tricky part is that numerals are sortedfrom 0 to 9 (there's a zero because plaintext obviously contains a character which position is 10, 20 or 30).
Here's the encrypted string:
01111111111222223344566689999999 (32 numerals)
This shouldn't be too hard, but beware that frequency analysis is kind of no use here, since all these 1's and 2's are not always a and b, respectively; they can be 12, 13 and so forth. Again, beware the difference between english and our alphabet, number 4 is not d. Plaintext is 20 chars long, excluding spaces, and there are 4 words. No numbers or special chars.
I'm going to start working on it now, jump in if you feel so. Here's some PHP I got so far to help me out (dunno how I am going to use it atm):
PHP Code:
<?
$i 
01111111111222223344566689999999;
$s = array(
=> 'a',
=> 'b',
=> 'c',
=> 'č',
=> 'ć',
=> 'd',
=> 'dž',
=> 'đ',
=> 'e',
10 => 'f',
11 => 'g',
12 => 'h',
13 => 'i',
14 => 'j',
15 => 'k',
16 => 'l',
17 => 'lj',
18 => 'm',
19 => 'n',
20 => 'nj',
21 => 'o',
22 => 'p',
23 => 'r',
24 => 's',
25 => 'š',
26 => 't',
27 => 'u',
28 => 'v',
29 => 'z',
30 => 'ž');

$nn = array('g''p');
$m_0 = array('f''nj''ž');
$m_1 = array('a''f''g''h''i''j''k''l''lj''m''n''o');
$m_2 = array('b''h''nj''o''p''r''s''š''t''u''v''z');
$m_3 = array('c''i''r''ž');
$m_4 = array('č''j''s');
$m_5 = array('ć''k''š');
$m_6 = array('d''l''t');
$m_8 = array('đ''m''v');
$m_9 = array('e''n''z');

?>



Let the hacking begin

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationSecurity and Cryptography > Crypto Algorithm Evaluation - Interesting numerical hash

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap