home *** CD-ROM | disk | FTP | other *** search
- #ifndef __ENCRYPT_H__
- #define __ENCRYPT_H__
-
- /* Xceed Encryption Library - Encrypt Sample Application
- * Copyright (c) 2001 Xceed Software Inc.
- *
- * [Encrypt.h]
- *
- * This console application shows how to encrypt a file, using different
- * encryption methods. It specifically demonstrates:
- * - The SetSecretKeyFromPassPhrase, SetRandomInitVector, WriteFile and
- * ProcessFile methods.
- * - The EncryptionMethod, EncryptionMode properties.
- *
- * This file is part of the Xceed Encryption Library sample
- * applications. The source code in this file is only intended as
- * a supplement to Xceed Encryption Library's documentation,
- * and is provided "as is", without warranty of any kind, either
- * expressed or implied.
- */
-
- //
- // The Visual C++ compiler will automatically generate wrapper classes
- // around available interfaces found in this type library.
- //
-
- #import "XceedCRY.dll" no_namespace named_guids
-
- //
- // Constants
- //
-
- //Size of the buffer used to read characters from the console.
- #define BUFFER_SIZE 0x4000
-
- //The size of pass phrase generated secret key. It could be one of the following :
- //128, 192 or 256.
- #define KEY_SIZE 128
-
-
- //
- // Enumerations
- //
-
- //The different encryption methods supported by the Xceed Encryption
- //library.
- enum EEncryptionMethod
- {
- emRijndael = 0,
- emTwofish = 1
- };
-
- //
- // Data types
- //
-
- //Structure that will be used in an array providing a correspondance
- //table between the possible encryption methods passed on the command line
- //and their value in Xceed Encryption Library.
- struct SEncryptionMethod
- {
- const char* pszCommandLine;
- EEncryptionMethod eMethod;
- };
-
-
- //
- // Prototypes
- //
-
- void ShowHelp();
-
- bool ExtractParameters( int argc, char* argv[],
- IXceedEncryptionPtr piEncrypt,
- _bstr_t& bstrInputFileName,
- _bstr_t& bstrOutputFileName );
-
- #endif // __ENCRYPT_H__
-