diff options
author | Christian Pointner <equinox@anytun.org> | 2009-02-18 13:08:59 +0000 |
---|---|---|
committer | Christian Pointner <equinox@anytun.org> | 2009-02-18 13:08:59 +0000 |
commit | d97760a781a793d35dfe75367dd8d80ab59bbb49 (patch) | |
tree | 362e1f7f198e2549b56dab7bf1eb564d15b48b91 /src/cipherFactory.cpp | |
parent | static build mostly fixed (diff) |
added anytun02 compat runtime switch
Diffstat (limited to 'src/cipherFactory.cpp')
-rw-r--r-- | src/cipherFactory.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/cipherFactory.cpp b/src/cipherFactory.cpp index e53620e..f6f383b 100644 --- a/src/cipherFactory.cpp +++ b/src/cipherFactory.cpp @@ -36,19 +36,19 @@ #include "cipher.h" -Cipher* CipherFactory::create(std::string const& type, kd_dir_t dir) +Cipher* CipherFactory::create(std::string const& type, kd_dir_t dir, bool anytun02_compat) { if( type == "null" ) return new NullCipher(); #ifndef NO_CRYPT else if( type == "aes-ctr" ) - return new AesIcmCipher(dir); + return new AesIcmCipher(dir, anytun02_compat); else if( type == "aes-ctr-128" ) - return new AesIcmCipher(dir, 128); + return new AesIcmCipher(dir, anytun02_compat, 128); else if( type == "aes-ctr-192" ) - return new AesIcmCipher(dir, 192); + return new AesIcmCipher(dir, anytun02_compat, 192); else if( type == "aes-ctr-256" ) - return new AesIcmCipher(dir, 256); + return new AesIcmCipher(dir, anytun02_compat, 256); #endif else throw std::invalid_argument("cipher not available"); |