summaryrefslogtreecommitdiff
path: root/eccrypto.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'eccrypto.cpp')
-rw-r--r--eccrypto.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/eccrypto.cpp b/eccrypto.cpp
index f76c495a..9a0914c0 100644
--- a/eccrypto.cpp
+++ b/eccrypto.cpp
@@ -28,6 +28,9 @@
#include "ec2n.h"
#include "misc.h"
+#include <iostream>
+#include <sstream>
+
// Squash MS LNK4221 and libtool warnings
#ifndef CRYPTOPP_MANUALLY_INSTANTIATE_TEMPLATES
extern const char ECCRYPTO_FNAME[] = __FILE__;
@@ -683,6 +686,13 @@ OID DL_GroupParameters_EC<EC>::GetAlgorithmID() const
return ASN1::id_ecPublicKey();
}
+std::ostream& operator<<(std::ostream& os, const DL_GroupParameters_EC<ECP>::Element& obj)
+{
+ std::ostringstream oss;
+ oss << "(" << std::hex << obj.x << ", " << std::hex << obj.y << ")";
+ return os << oss.str();
+}
+
// ******************************************************************
template <class EC>