Исследование алгоритмов оценки стойкости пароля
Дипломная работа - Компьютеры, программирование
Другие дипломы по предмету Компьютеры, программирование
176.
.Грушо А.А. Теоретические основы защиты информации / А.А. Грушо, Е.Е. Тимонина // - 1996. - С. 31.
.Домашев А.В. Программирование алгоритмов защиты информации / А.В. Домашев, А.Ю. Щербаков // - 2000. - С. 288.
.Варфоломеев А.А. Блочные криптосистемы. Основные свойства и методы анализа стойкости / А.А. Варфоломеев, А.Е. Жуков // - 1998. - С. 200.
.Спесивцев А.В. Защита информации в персональных / А.В. Спесивцев // - 1992. - С. 278.
.Ростовцев А.Г. Защита информации в компьютерных системах. Элементы криптологии / А.Г. Ростовцев, В.А. Матвеев / Под редакцией П.Д. Зегжды. - 1993. - С. 365.
8.Fluhrer S.R. Statistical analysis of the alleged RC4 keystream generator / S.R. Fluhrer, D.A. McGrew // Fast Software Encryption, Cambridge Security Workshop Proceedings. - 2000. - Р. 127-139.
.Golic J.Dj. Linear models for keystream generators / J.Dj. Golic // IEEE Transactions on Computers. - 1996. - V. 45. - Р. 41-49.
.Menezes A.J. Handbook of Applied Cryptography / A.J. Menezes, S.A. Vanstone // - 1996. - Р. 780.
Приложение
Листинг алгоритма оценки стойкости пароля от Microsoft
var kNoCanonicalCounterpart = 0;kCapitalLetter = 0;kSmallLetter = 1;kDigit = 2;kPunctuation = 3;kAlpha = 4;
var kCanonicalizeLettersOnly = true;kCananicalizeEverything = false;
var gDebugOutput = null;kDebugTraceLevelNone = 0;kDebugTraceLevelSuperDetail = 120;kDebugTraceLevelRealDetail = 100;kDebugTraceLevelAll = 80;kDebugTraceLevelMost = 60;kDebugTraceLevelFew = 40;kDebugTraceLevelRare = 20;
var gDebugTraceLevel = kDebugTraceLevelNone;DebugPrint(){string = "";(gDebugTraceLevel && gDebugOutput && DebugPrint.arguments && (DebugPrint.arguments.length > 1) && (DebugPrint.arguments[0] <= gDebugTraceLevel)){(var index = 1; index < DebugPrint.arguments.length; index++){+= DebugPrint.arguments[index] + " ";
}+= "
\n";(string);
}
}CSimilarityMap(){.m_elements = "";.m_canonicalCounterparts = "";
}SimilarityMap_Add(element, canonicalCounterpart){.m_elements += element;.m_canonicalCounterparts += canonicalCounterpart;
}SimilarityMap_Lookup(element){canonicalCounterpart = kNoCanonicalCounterpart;index = this.m_elements.indexOf(element);(index >= 0){= this.m_canonicalCounterparts.charAt(index);
}{
}canonicalCounterpart;
}SimilarityMap_GetCount(){this.m_elements.length;
}.prototype.Add = SimilarityMap_Add;.prototype.Lookup = SimilarityMap_Lookup;.prototype.GetCount = SimilarityMap_GetCount;CDictionaryEntry(length, wordList){.m_length = length;.m_wordList = wordList;
}DictionaryEntry_Lookup(strWord){fFound = false;(strWord.length == this.m_length){nFirst = 0;nLast = this.m_wordList.length - 1;(nFirst <= nLast){nCurrent = Math.floor((nFirst + nLast)/2);(strWord == this.m_wordList[nCurrent]){= true;;
}if (strWord > this.m_wordList[nCurrent]){= nCurrent - 1;
}{= nCurrent + 1;
}
}
}fFound;
}.prototype.Lookup = DictionaryEntry_Lookup;CDictionary(){.m_entries = new Array()
}Dictionary_Lookup(strWord){(var index = 0; index < this.m_entries.length; index++){(this.m_entries[index].Lookup(strWord)){true;
}
}
}Dictionary_Add(length, wordList){iL=this.m_entries.length;cD=new CDictionaryEntry(length, wordList)
this.m_entries[iL]=cD;
}.prototype.Lookup = Dictionary_Lookup;.prototype.Add = Dictionary_Add;gSimilarityMap = new CSimilarityMap();gDictionary = new CDictionary();CharacterSetChecks(type, fResult){.type = type;.fResult = fResult;
}isctype(character, type, nDebugLevel){
var fResult = false;(type){
case kCapitalLetter:((character >= 'A') && (character <= 'Z')){= true;
};kSmallLetter:((character >= 'a') && (character <= 'z')){= true;
};kDigit:((character >= '0') && (character <= '9')){= true;
};kPunctuation:("!@#$%^&*()_+-='\";:[{]}\|.>,= 0){= true;
};kAlpha:(isctype(character, kCapitalLetter) || isctype(character, kSmallLetter)){= true;
};:;
}fResult;
}CanonicalizeWord(strWord, similarityMap, fLettersOnly){canonicalCounterpart = kNoCanonicalCounterpart;strCanonicalizedWord = "";nStringLength = 0;((strWord != null) && (strWord.length > 0)){= strWord;= strCanonicalizedWord.toLowerCase();(similarityMap.GetCount() > 0){= strCanonicalizedWord.length;(var index = 0; index < nStringLength; index++){(fLettersOnly && !isctype(strCanonicalizedWord.charAt(index), kSmallLetter, kDebugTraceLevelSuperDetail)){;
}= similarityMap.Lookup(strCanonicalizedWord.charAt(index));(canonicalCounterpart != kNoCanonicalCounterpart){= strCanonicalizedWord.substring(0, index) + canonicalCounterpart +.substring(index + 1, nStringLength);
}
}
}
}strCanonicalizedWord;
}IsLongEnough(strWord, nAtLeastThisLong){((strWord == null) || isNaN(nAtLeastThisLong)){false;
}if (strWord.length < nAtLeastThisLong){false;
}true;
}SpansEnoughCharacterSets(strWord, nAtLeastThisMany){nCharSets = 0;characterSetChecks = new Array(CharacterSetChecks(kCapitalLetter, false),CharacterSetChecks(kSmallLetter, false),CharacterSetChecks(kDigit, false),CharacterSetChecks(kPunctuation, false)
);((strWord == null) || isNaN(nAtLeastThisMany)){false;
}(var index = 0; index < strWord.length; index++){(var nCharSet = 0; nCharSet < characterSetChecks.length;nCharSet++){(!characterSetChecks[nCharSet].fResult && isctype(strWord.charAt(index), characterSetChecks[nCharSet].type, kDebugTraceLevelAll)){[nCharSet].fResult = true;;
}
}
}(var nCharSet = 0; nCharSet < characterSetChecks.length;nCharSet++){(characterSetChecks[nCharSet].fResult){++;
}
}(nCharSets < nAtLeastThisMany){false;
}true;
}FoundInDictionary(strWord, similarityMap, dictionary){strCanonicalizedWord = "";((strWord == null) || (similarityMap == null) || (dictionary == null)){true;
}= CanonicalizeWord(strWord, similarityMap, kCanonicalizeLettersOnly);(dictionary.Lookup(strCanonicalizedWord)){true;
}false;
}IsCloseVariationOfAWordInDictionary(strWord, threshold, similarityMap, dictionary){strCanonicalizedWord = "";nMinimumMeaningfulMatchLength = 0;((strWord == null) || isNaN(threshold) || (similarityMap == null) || (dictionary == null)){true;
}= CanonicalizeWord(strWord, similarityMap, kCananicalizeEverything);= Math.floor((threshold) * strCanonicalizedWord.length);(var nSubStringLength = strCanonicalizedWord.length; nSubStringLength >= nMinimumMeaningfulMatchLength; nSubStringLength--){(var nSubStringStart = 0; (nSubStringStart + nMinimumMeaningfulMatchLength) < strCanonicalizedWord.length; nSubStringStart++){strSubWord = strCanonicalizedWord.substr(nSubStringStart, nSubStringLength);(dictionary.Lookup(strSubWord)){true;
}
}
}false;
}ClientSideStrongPassword(){(IsLongEnough(ClientSideStrongPassword.arguments[0], "8") && SpansEnoughCharacterSets(ClientSideStrongPassword.arguments[0], "3") && (!(IsCloseVariationOfAWordInDictionary(ClientSideStrongPassword.arguments[0], "0.6", ClientSideStrongPassword.arguments[1], ClientSideStrongPassword.arguments[2]))));
}ClientSideBestPassword(){(IsLongEnough(ClientSideBestPassword.arguments[0], "14") &&(ClientSideBestPassword.arguments[0], "3") && (!(IsCloseVariationOfAWordInDictionary(ClientSideBestPassword.arguments[0], "0.6", ClientSideBestPassword.arguments[1], ClientSideBestPassword.arguments[2]))));
}ClientSideMediumPassword(){(IsLongEnough(ClientSideMediumPassword.arguments[0], "8") && SpansEnoughCharacterSets(ClientSideMediumPassword.arguments[0], "2") && (!(FoundInDictionary(ClientSideMediumPassword.arguments[0], ClientSideMediumPassword.arguments[1], ClientSideMediumPassword.arguments[2]))));
}ClientSideWeakPassword(){(IsLongEnough(ClientSideWeakPassword.arguments[0], "1") || (!(IsLongEnough(ClientSideWeakPassword.arguments[0], "0"))));
}GEId(sID){document.getElementById(sID);
}EvalPwdStrength(oF,sP){(ClientSideBestPassword(sP,gSimilarityMap,gDictionary)){(4,'pwdChkCon4');
}if(ClientSideStrongPassword(sP,gSimilarityMap,gDictionary)){(3,'pwdChkCon3');
}if(ClientSideMediumPassword(sP,gSimilarityMap,gDictionary)){(2,'pwdChkCon2');
}if(ClientSideWeakPassword(sP,gSimilarityMap,gDictionary)){(1,'pwdChkCon1');
}{(0,'pwdChkCon0');
}
}PadPasswd(oF,lPwd){(typeof oF.PwdPad=="object"){
var sPad="djg";lPad=sPad.length-lPwd;.PwdPad.value=sPad.substr(0,(lPad<0)?0:lPad);
}
}DispPwdStrength(iN,sHL){(iN>4){ iN=4;
}(var i=0;i0){("idSM"+i).className=sHCR;
}("idSMT"+i).style.display=((i==iN)?"inline":"none");
}
}