X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=Common%2Frt%20api%2FChainWalkSet.h;h=6d991fe81fb3bfa6f421800e0e974c646feb0362;hb=0fb676244827a448dc60118d6558c4a4e346ffee;hp=427689454c9df7b71ae927c9ecb6162225feaecc;hpb=59bc65eea1e9a2cab6b1d51f4567cffc033fe938;p=freerainbowtables diff --git a/Common/rt api/ChainWalkSet.h b/Common/rt api/ChainWalkSet.h index 4276894..6d991fe 100644 --- a/Common/rt api/ChainWalkSet.h +++ b/Common/rt api/ChainWalkSet.h @@ -1,8 +1,27 @@ /* - RainbowCrack - a general propose implementation of Philippe Oechslin's faster time-memory trade-off technique. - - Copyright (C) Zhu Shuanglei -*/ + * freerainbowtables is a project for generating, distributing, and using + * perfect rainbow tables + * + * Copyright (C) Zhu Shuanglei + * Copyright Martin Westergaard Jørgensen + * Copyright 2009, 2010 Daniël Niggebrugge + * Copyright 2009, 2010 James Nobis + * + * This file is part of freerainbowtables. + * + * freerainbowtables is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * freerainbowtables is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with freerainbowtables. If not, see . + */ #ifndef _CHAINWALKSET_H #define _CHAINWALKSET_H @@ -30,9 +49,16 @@ private: int m_nRainbowTableIndex; // Discard all if not match int m_nRainbowChainLen; // Discard all if not match list m_lChainWalk; + bool debug; + string sPrecalcPathName; + int preCalcPart; + vector vPrecalcFiles; private: void DiscardAll(); + bool FindInFile(uint64* pIndexE, unsigned char* pHash, int nHashLen); + string CheckOrRotatePreCalcFile(); + void updateUsedPrecalcFiles(); public: uint64* RequestWalk(unsigned char* pHash, int nHashLen, @@ -40,8 +66,12 @@ public: string sPlainCharsetName, int nPlainLenMin, int nPlainLenMax, int nRainbowTableIndex, int nRainbowChainLen, - bool& fNewlyGenerated); + bool& fNewlyGenerated, + bool setDebug, + string sPrecalc); void DiscardWalk(uint64* pIndexE); + void StoreToFile(uint64* pIndexE, unsigned char* pHash, int nHashLen); + void removePrecalcFiles(); }; #endif