projects
/
anytun.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
New release 0.3.7-1
[anytun.git]
/
src
/
authAlgo.h
diff --git
a/src/authAlgo.h
b/src/authAlgo.h
index
a1fcea4
..
758e754
100644
(file)
--- a/
src/authAlgo.h
+++ b/
src/authAlgo.h
@@
-101,10
+101,13
@@
public:
//****** Sha1AuthAlgo ******
//* HMAC SHA1 Auth Tag Generator Class
//****** Sha1AuthAlgo ******
//* HMAC SHA1 Auth Tag Generator Class
+class AuthAlgoFactory;
+
class Sha1AuthAlgo : public AuthAlgo
{
class Sha1AuthAlgo : public AuthAlgo
{
+ friend class AuthAlgoFactory;
+
public:
public:
- Sha1AuthAlgo(kd_dir_t d);
~Sha1AuthAlgo();
void generate(KeyDerivation& kd, EncryptedPacket& packet);
~Sha1AuthAlgo();
void generate(KeyDerivation& kd, EncryptedPacket& packet);
@@
-113,8
+116,11
@@
public:
static const uint32_t DIGEST_LENGTH = 20;
private:
static const uint32_t DIGEST_LENGTH = 20;
private:
+ Sha1AuthAlgo(kd_dir_t d);
+ bool Init();
+
#if defined(USE_SSL_CRYPTO)
#if defined(USE_SSL_CRYPTO)
- HMAC_CTX ctx_;
+ HMAC_CTX
*
ctx_;
#elif defined(USE_NETTLE)
struct hmac_sha1_ctx ctx_;
#else // USE_GCRYPT is the default
#elif defined(USE_NETTLE)
struct hmac_sha1_ctx ctx_;
#else // USE_GCRYPT is the default