Parcourir la source

[trac781] rename 'main' cryptolink file, and clean up includes

Jelte Jansen il y a 14 ans
Parent
commit
20336851f4

+ 1 - 1
src/lib/cryptolink/Makefile.am

@@ -8,5 +8,5 @@ CLEANFILES = *.gcno *.gcda
 
 lib_LTLIBRARIES = libcryptolink.la
 
-libcryptolink_la_SOURCES = crypto.h crypto.cc
+libcryptolink_la_SOURCES = cryptolink.h cryptolink.cc
 libcryptolink_la_SOURCES += crypto_hmac.h crypto_hmac.cc

+ 15 - 2
src/lib/cryptolink/crypto_hmac.cc

@@ -1,5 +1,18 @@
-
-#include <crypto.h>
+// Copyright (C) 2011  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.
+
+#include <cryptolink.h>
 
 #include <boost/scoped_ptr.hpp>
 

+ 1 - 3
src/lib/cryptolink/crypto_hmac.h

@@ -12,13 +12,11 @@
 // OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 // PERFORMANCE OF THIS SOFTWARE.
 
-#include <string>
 #include <dns/buffer.h>
-#include <exceptions/exceptions.h>
 
 #include <boost/noncopyable.hpp>
 
-#include <cryptolink/crypto.h>
+#include <cryptolink/cryptolink.h>
 
 #ifndef _ISC_CRYPTO_HMAC_H
 #define _ISC_CRYPTO_HMAC_H

+ 1 - 12
src/lib/cryptolink/crypto.cc

@@ -12,23 +12,12 @@
 // OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 // PERFORMANCE OF THIS SOFTWARE.
 
-#include "crypto.h"
+#include "cryptolink.h"
 
 #include <botan/botan.h>
-#include <botan/hmac.h>
-#include <botan/hash.h>
-#include <botan/types.h>
-
-#include <dns/buffer.h>
-#include <dns/name.h>
-#include <dns/util/base64.h>
-
-#include <string>
 
 #include <boost/scoped_ptr.hpp>
 
-#include <iostream>
-
 using namespace std;
 using namespace isc::dns;
 

src/lib/cryptolink/crypto.h → src/lib/cryptolink/cryptolink.h


+ 1 - 1
src/lib/cryptolink/tests/crypto_unittests.cc

@@ -15,7 +15,7 @@
 #include <config.h>
 #include <gtest/gtest.h>
 
-#include <cryptolink/crypto.h>
+#include <cryptolink/cryptolink.h>
 #include <dns/buffer.h>
 #include <exceptions/exceptions.h>
 

+ 0 - 1
src/lib/cryptolink/tests/run_unittests.cc

@@ -15,7 +15,6 @@
 #include <gtest/gtest.h>
 
 #include <dns/tests/unittest_util.h>
-#include <cryptolink/crypto.h>
 
 int
 main(int argc, char* argv[]) {

+ 1 - 1
src/lib/dns/tsigkey.cc

@@ -18,7 +18,7 @@
 
 #include <exceptions/exceptions.h>
 
-#include <cryptolink/crypto.h>
+#include <cryptolink/cryptolink.h>
 
 #include <dns/name.h>
 #include <dns/util/base64.h>