summaryrefslogtreecommitdiff
path: root/modules/encryption
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2014-04-01 22:24:50 -0400
committerAdam <Adam@anope.org>2014-04-01 22:24:50 -0400
commit44637154da89028a99920bd6ead5d917d8a894a4 (patch)
treecb2bd670800efb25beb2c71983b1db49a3f78d49 /modules/encryption
parentb12a51a430b00e857cc5568c9fd994bbd88c8ff7 (diff)
Require cmake 2.8 and C++11 support
Diffstat (limited to 'modules/encryption')
-rw-r--r--modules/encryption/enc_bcrypt.cpp6
-rw-r--r--modules/encryption/enc_md5.cpp14
-rw-r--r--modules/encryption/enc_none.cpp6
-rw-r--r--modules/encryption/enc_old.cpp8
-rw-r--r--modules/encryption/enc_sha1.cpp14
-rw-r--r--modules/encryption/enc_sha256.cpp14
6 files changed, 31 insertions, 31 deletions
diff --git a/modules/encryption/enc_bcrypt.cpp b/modules/encryption/enc_bcrypt.cpp
index 2c50d5137..8ed5695ac 100644
--- a/modules/encryption/enc_bcrypt.cpp
+++ b/modules/encryption/enc_bcrypt.cpp
@@ -886,14 +886,14 @@ class EBCRYPT : public Module
throw ModuleException("BCrypt could not load!");
}
- EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) anope_override
+ EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) override
{
dest = "bcrypt:" + Generate(src, Salt());
Log(LOG_DEBUG_2) << "(enc_bcrypt) hashed password from [" << src << "] to [" << dest << "]";
return EVENT_ALLOW;
}
- void OnCheckAuthentication(User *, IdentifyRequest *req) anope_override
+ void OnCheckAuthentication(User *, IdentifyRequest *req) override
{
const NickAlias *na = NickAlias::Find(req->GetAccount());
if (na == NULL)
@@ -933,7 +933,7 @@ class EBCRYPT : public Module
}
}
- void OnReload(Configuration::Conf *conf) anope_override
+ void OnReload(Configuration::Conf *conf) override
{
Configuration::Block *block = conf->GetModule(this);
rounds = block->Get<unsigned int>("rounds", "10");
diff --git a/modules/encryption/enc_md5.cpp b/modules/encryption/enc_md5.cpp
index b56f03324..b49390d56 100644
--- a/modules/encryption/enc_md5.cpp
+++ b/modules/encryption/enc_md5.cpp
@@ -250,7 +250,7 @@ class MD5Context : public Encryption::Context
* operation, processing another message block, and updating the
* context.
*/
- void Update(const unsigned char *input, size_t len) anope_override
+ void Update(const unsigned char *input, size_t len) override
{
unsigned i, index, partLen;
@@ -285,7 +285,7 @@ class MD5Context : public Encryption::Context
/* MD5 finalization. Ends an MD5 message-digest opera
* the message digest and zeroizing the context.
*/
- void Finalize() anope_override
+ void Finalize() override
{
unsigned char bits[8];
unsigned index, padLen;
@@ -309,7 +309,7 @@ class MD5Context : public Encryption::Context
memset(this->buffer, 0, sizeof(this->buffer));
}
- Encryption::Hash GetFinalizedHash() anope_override
+ Encryption::Hash GetFinalizedHash() override
{
Encryption::Hash hash;
hash.first = this->digest;
@@ -323,12 +323,12 @@ class MD5Provider : public Encryption::Provider
public:
MD5Provider(Module *creator) : Encryption::Provider(creator, "md5") { }
- Encryption::Context *CreateContext(Encryption::IV *iv) anope_override
+ Encryption::Context *CreateContext(Encryption::IV *iv) override
{
return new MD5Context(iv);
}
- Encryption::IV GetDefaultIV() anope_override
+ Encryption::IV GetDefaultIV() override
{
Encryption::IV iv;
iv.first = md5_iv;
@@ -348,7 +348,7 @@ class EMD5 : public Module
}
- EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) anope_override
+ EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) override
{
MD5Context context;
@@ -364,7 +364,7 @@ class EMD5 : public Module
return EVENT_ALLOW;
}
- void OnCheckAuthentication(User *, IdentifyRequest *req) anope_override
+ void OnCheckAuthentication(User *, IdentifyRequest *req) override
{
const NickAlias *na = NickAlias::Find(req->GetAccount());
if (na == NULL)
diff --git a/modules/encryption/enc_none.cpp b/modules/encryption/enc_none.cpp
index 744c788f5..ae698914c 100644
--- a/modules/encryption/enc_none.cpp
+++ b/modules/encryption/enc_none.cpp
@@ -17,7 +17,7 @@ class ENone : public Module
}
- EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) anope_override
+ EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) override
{
Anope::string buf = "plain:";
Anope::string cpass;
@@ -28,7 +28,7 @@ class ENone : public Module
return EVENT_ALLOW;
}
- EventReturn OnDecrypt(const Anope::string &hashm, const Anope::string &src, Anope::string &dest) anope_override
+ EventReturn OnDecrypt(const Anope::string &hashm, const Anope::string &src, Anope::string &dest) override
{
if (!hashm.equals_cs("plain"))
return EVENT_CONTINUE;
@@ -38,7 +38,7 @@ class ENone : public Module
return EVENT_ALLOW;
}
- void OnCheckAuthentication(User *, IdentifyRequest *req) anope_override
+ void OnCheckAuthentication(User *, IdentifyRequest *req) override
{
const NickAlias *na = NickAlias::Find(req->GetAccount());
if (na == NULL)
diff --git a/modules/encryption/enc_old.cpp b/modules/encryption/enc_old.cpp
index c8c1093da..89c228b1d 100644
--- a/modules/encryption/enc_old.cpp
+++ b/modules/encryption/enc_old.cpp
@@ -19,14 +19,14 @@ class OldMD5Provider : public Encryption::Provider
public:
OldMD5Provider(Module *creator) : Encryption::Provider(creator, "oldmd5") { }
- Encryption::Context *CreateContext(Encryption::IV *iv) anope_override
+ Encryption::Context *CreateContext(Encryption::IV *iv) override
{
if (md5)
return md5->CreateContext(iv);
return NULL;
}
- Encryption::IV GetDefaultIV() anope_override
+ Encryption::IV GetDefaultIV() override
{
if (md5)
return md5->GetDefaultIV();
@@ -51,7 +51,7 @@ class EOld : public Module
}
- EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) anope_override
+ EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) override
{
if (!md5)
return EVENT_CONTINUE;
@@ -79,7 +79,7 @@ class EOld : public Module
return EVENT_ALLOW;
}
- void OnCheckAuthentication(User *, IdentifyRequest *req) anope_override
+ void OnCheckAuthentication(User *, IdentifyRequest *req) override
{
const NickAlias *na = NickAlias::Find(req->GetAccount());
if (na == NULL)
diff --git a/modules/encryption/enc_sha1.cpp b/modules/encryption/enc_sha1.cpp
index 38f32b2cb..79d657493 100644
--- a/modules/encryption/enc_sha1.cpp
+++ b/modules/encryption/enc_sha1.cpp
@@ -120,7 +120,7 @@ class SHA1Context : public Encryption::Context
memset(this->digest, 0, sizeof(this->digest));
}
- void Update(const unsigned char *data, size_t len) anope_override
+ void Update(const unsigned char *data, size_t len) override
{
uint32_t i, j;
@@ -141,7 +141,7 @@ class SHA1Context : public Encryption::Context
memcpy(&this->buffer[j], &data[i], len - i);
}
- void Finalize() anope_override
+ void Finalize() override
{
uint32_t i;
unsigned char finalcount[8];
@@ -164,7 +164,7 @@ class SHA1Context : public Encryption::Context
this->Transform(this->buffer);
}
- Encryption::Hash GetFinalizedHash() anope_override
+ Encryption::Hash GetFinalizedHash() override
{
Encryption::Hash hash;
hash.first = this->digest;
@@ -178,12 +178,12 @@ class SHA1Provider : public Encryption::Provider
public:
SHA1Provider(Module *creator) : Encryption::Provider(creator, "sha1") { }
- Encryption::Context *CreateContext(Encryption::IV *iv) anope_override
+ Encryption::Context *CreateContext(Encryption::IV *iv) override
{
return new SHA1Context(iv);
}
- Encryption::IV GetDefaultIV() anope_override
+ Encryption::IV GetDefaultIV() override
{
Encryption::IV iv;
iv.first = sha1_iv;
@@ -203,7 +203,7 @@ class ESHA1 : public Module
}
- EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) anope_override
+ EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) override
{
SHA1Context context;
@@ -219,7 +219,7 @@ class ESHA1 : public Module
return EVENT_ALLOW;
}
- void OnCheckAuthentication(User *, IdentifyRequest *req) anope_override
+ void OnCheckAuthentication(User *, IdentifyRequest *req) override
{
const NickAlias *na = NickAlias::Find(req->GetAccount());
if (na == NULL)
diff --git a/modules/encryption/enc_sha256.cpp b/modules/encryption/enc_sha256.cpp
index cccbceea1..8be792346 100644
--- a/modules/encryption/enc_sha256.cpp
+++ b/modules/encryption/enc_sha256.cpp
@@ -173,7 +173,7 @@ class SHA256Context : public Encryption::Context
memset(this->digest, 0, sizeof(this->digest));
}
- void Update(const unsigned char *message, size_t mlen) anope_override
+ void Update(const unsigned char *message, size_t mlen) override
{
unsigned tmp_len = SHA256_BLOCK_SIZE - this->len, rem_len = mlen < tmp_len ? mlen : tmp_len;
@@ -195,7 +195,7 @@ class SHA256Context : public Encryption::Context
this->tot_len += (block_nb + 1) << 6;
}
- void Finalize() anope_override
+ void Finalize() override
{
unsigned block_nb = 1 + ((SHA256_BLOCK_SIZE - 9) < (this->len % SHA256_BLOCK_SIZE));
unsigned len_b = (this->tot_len + this->len) << 3;
@@ -208,7 +208,7 @@ class SHA256Context : public Encryption::Context
UNPACK32(this->h[i], &this->digest[i << 2]);
}
- Encryption::Hash GetFinalizedHash() anope_override
+ Encryption::Hash GetFinalizedHash() override
{
Encryption::Hash hash;
hash.first = this->digest;
@@ -222,12 +222,12 @@ class SHA256Provider : public Encryption::Provider
public:
SHA256Provider(Module *creator) : Encryption::Provider(creator, "sha256") { }
- Encryption::Context *CreateContext(Encryption::IV *iv) anope_override
+ Encryption::Context *CreateContext(Encryption::IV *iv) override
{
return new SHA256Context(iv);
}
- Encryption::IV GetDefaultIV() anope_override
+ Encryption::IV GetDefaultIV() override
{
Encryption::IV iv;
iv.first = sha256_h0;
@@ -281,7 +281,7 @@ class ESHA256 : public Module
use_iv = false;
}
- EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) anope_override
+ EventReturn OnEncrypt(const Anope::string &src, Anope::string &dest) override
{
if (!use_iv)
NewRandomIV();
@@ -302,7 +302,7 @@ class ESHA256 : public Module
return EVENT_ALLOW;
}
- void OnCheckAuthentication(User *, IdentifyRequest *req) anope_override
+ void OnCheckAuthentication(User *, IdentifyRequest *req) override
{
const NickAlias *na = NickAlias::Find(req->GetAccount());
if (na == NULL)