summaryrefslogtreecommitdiffstats
path: root/src/lib/dns/tsig.h
diff options
context:
space:
mode:
authorJINMEI Tatuya <jinmei@isc.org>2010-10-19 15:52:19 +0200
committerJINMEI Tatuya <jinmei@isc.org>2010-10-19 15:52:19 +0200
commite08e6404bea7d20487e8345afe6798cbb1dec186 (patch)
tree28363f5ca640f4ce8b7e702ac3f8f9595901ce8d /src/lib/dns/tsig.h
parentworking branch for trac #381 (diff)
downloadkea-e08e6404bea7d20487e8345afe6798cbb1dec186.tar.xz
kea-e08e6404bea7d20487e8345afe6798cbb1dec186.zip
Initial implementation of TSIGKey and TSIGKeyRing, including detailed tests, documentation, and python binding.
git-svn-id: svn://bind10.isc.org/svn/bind10/branches/trac381@3278 e5f2f494-b856-4b98-b285-d166d9295462
Diffstat (limited to 'src/lib/dns/tsig.h')
-rw-r--r--src/lib/dns/tsig.h72
1 files changed, 0 insertions, 72 deletions
diff --git a/src/lib/dns/tsig.h b/src/lib/dns/tsig.h
deleted file mode 100644
index 7b09fd8cd6..0000000000
--- a/src/lib/dns/tsig.h
+++ /dev/null
@@ -1,72 +0,0 @@
-// Copyright (C) 2010 Internet Systems Consortium, Inc. ("ISC")
-//
-// Permission to use, copy, modify, and/or distribute this software for any
-// purpose with or without fee is hereby granted, provided that the above
-// copyright notice and this permission notice appear in all copies.
-//
-// THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
-// REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-// AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
-// INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
-// LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
-// OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-// PERFORMANCE OF THIS SOFTWARE.
-
-// $Id$
-
-#ifndef __TSIG_H
-#define __TSIG_H 1
-
-#include <string>
-#include <vector>
-
-#include <exceptions/exceptions.h>
-
-#include <dns/name.h>
-#include <dns/message.h>
-
-namespace isc {
-namespace dns {
-
-class BadTsigKey : public Exception {
-public:
- BadTsigKey(const char* file, size_t line, const char* what) :
- isc::Exception(file, line, what) {}
-};
-
-//
-// This class holds a Tsig key, including all its attributes.
-//
-class Tsig {
-public:
- enum TsigAlgorithm {
- HMACMD5 = 0,
- GSS = 1,
- HMACSHA1 = 2,
- HMACSHA224 = 3,
- HMACSHA265 = 4,
- HMACSHA384 = 5,
- HMACSHA512 = 6,
- };
-
- Tsig(const Name& name, TsigAlgorithm algorithm,
- const std::string& algorithm_data) :
- name_(name), algorithm_(algorithm), algorithm_data_(algorithm_data) {};
-
- bool signMessage(const Message& message);
- bool verifyMessage(const Message &message);
-
-private:
- Name name_;
- TsigAlgorithm algorithm_;
- std::string algorithm_data_;
-};
-
-}
-}
-
-#endif // __TSIG_H
-
-// Local Variables:
-// mode: c++
-// End: