AdamBrill
11-26-2003, 10:22 PM
Hey guys!
I've been wanting to start a challenge for a while, so here it finally is. ;) Here are some generic rules for the challenges:
Rules:
#1. You cannot get off-topic. If you do get off-topic, your entry will be removed from the challenge and you will be warned. If you are a repeat offender, you may get banned from all challenges.
#2. You cannot post the answer or any hints on the forums until told to do so. If you do, your entry will be removed from the challenge and you will be warned. Once again, if you are a repeat offender, you may get banned from all challenges.
#3. You cannot get help from anywhere; you must solve/complete the challenges yourself. If you are caught cheating, you will probably be banned from all challenges.
#4. You must follow all rules given in the challenge.
And here is the first challenge:
It's called Break the Security! :D
Here is the encrypted string(all supposed to be on one line):
0582062206220611054306300622062506180557054305950615061606260543061606260543062706150612054306260627 062506160621061405430627061506080627054306300608062605430612062106100625063206230627061206110557
And here is the encrypting/decrypting functions:
function create_pass(pass){
return pass.charCodeAt(0)+pass.charCodeAt(1)+pass.charCodeAt(2)+pass.charCodeAt(3)+pass.charCodeAt(4);
}
function encrypt(text,pass){
pass = create_pass(pass);
str = "";
for(x=0; x<text.length; x++){
add = "";
code = text.charCodeAt(x);
code += pass;
for(y=0; y<4-String(code).length; y++){
add += "0";
}
add += code;
str += add;
}
return str;
}
function decrypt(text,pass){
pass = create_pass(pass);
text_array = new Array();
while(text.length > 0){
text_array[text_array.length] = Number(text.substring(0,4)-pass);
text = text.substring(4);
}
str = "";
for(x=0; x<text_array.length; x++){
str += String.fromCharCode(text_array[x]);
}
return str;
}
Goal:
Break the security and tell me what the unencrypted string is. You will get extra points for telling me what the password that I used was.
It is extremely simple, but I figured I should make the first one pretty easy. ;) So, good luck, guys. And remember rule #2... :)
If you figure it out, PM me the answer...
EDIT: Change of plans. The first person to come up with the correct answer wins. If you come up with the correct decrypted string AND a password to fit, post it on here and you won... Do not post only the string; you must have both the decrypted string and a password before posting your answer.
EDIT #2: Since it was pointed out to me that there are multiple passwords that will work for this, you only need to come up with one password that will work, not necessarily my password.
I've been wanting to start a challenge for a while, so here it finally is. ;) Here are some generic rules for the challenges:
Rules:
#1. You cannot get off-topic. If you do get off-topic, your entry will be removed from the challenge and you will be warned. If you are a repeat offender, you may get banned from all challenges.
#2. You cannot post the answer or any hints on the forums until told to do so. If you do, your entry will be removed from the challenge and you will be warned. Once again, if you are a repeat offender, you may get banned from all challenges.
#3. You cannot get help from anywhere; you must solve/complete the challenges yourself. If you are caught cheating, you will probably be banned from all challenges.
#4. You must follow all rules given in the challenge.
And here is the first challenge:
It's called Break the Security! :D
Here is the encrypted string(all supposed to be on one line):
0582062206220611054306300622062506180557054305950615061606260543061606260543062706150612054306260627 062506160621061405430627061506080627054306300608062605430612062106100625063206230627061206110557
And here is the encrypting/decrypting functions:
function create_pass(pass){
return pass.charCodeAt(0)+pass.charCodeAt(1)+pass.charCodeAt(2)+pass.charCodeAt(3)+pass.charCodeAt(4);
}
function encrypt(text,pass){
pass = create_pass(pass);
str = "";
for(x=0; x<text.length; x++){
add = "";
code = text.charCodeAt(x);
code += pass;
for(y=0; y<4-String(code).length; y++){
add += "0";
}
add += code;
str += add;
}
return str;
}
function decrypt(text,pass){
pass = create_pass(pass);
text_array = new Array();
while(text.length > 0){
text_array[text_array.length] = Number(text.substring(0,4)-pass);
text = text.substring(4);
}
str = "";
for(x=0; x<text_array.length; x++){
str += String.fromCharCode(text_array[x]);
}
return str;
}
Goal:
Break the security and tell me what the unencrypted string is. You will get extra points for telling me what the password that I used was.
It is extremely simple, but I figured I should make the first one pretty easy. ;) So, good luck, guys. And remember rule #2... :)
If you figure it out, PM me the answer...
EDIT: Change of plans. The first person to come up with the correct answer wins. If you come up with the correct decrypted string AND a password to fit, post it on here and you won... Do not post only the string; you must have both the decrypted string and a password before posting your answer.
EDIT #2: Since it was pointed out to me that there are multiple passwords that will work for this, you only need to come up with one password that will work, not necessarily my password.