aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/examples/bzip.cpp4
-rw-r--r--doc/examples/cryptobox.cpp2
-rw-r--r--doc/examples/dsa_sign.cpp2
-rw-r--r--doc/examples/dsa_ver.cpp2
-rw-r--r--doc/examples/encrypt.cpp2
-rw-r--r--doc/examples/hash_quickly.cpp2
-rw-r--r--doc/examples/hasher.cpp2
-rw-r--r--doc/examples/hasher2.cpp2
-rw-r--r--doc/examples/package.cpp2
-rw-r--r--doc/examples/stack.cpp2
-rw-r--r--doc/examples/tls_client.cpp4
-rw-r--r--doc/log.txt1
12 files changed, 15 insertions, 12 deletions
diff --git a/doc/examples/bzip.cpp b/doc/examples/bzip.cpp
index c3509c4da..6137bb6af 100644
--- a/doc/examples/bzip.cpp
+++ b/doc/examples/bzip.cpp
@@ -84,8 +84,8 @@ int main(int argc, char* argv[])
outfile = outfile.replace(outfile.find(SUFFIX),
SUFFIX.length(), "");
- std::ifstream in(infile.c_str());
- std::ofstream out(outfile.c_str());
+ std::ifstream in(infile.c_str(), std::ios::binary);
+ std::ofstream out(outfile.c_str(), std::ios::binary);
if(!in)
{
std::cout << "ERROR: could not read " << infile << std::endl;
diff --git a/doc/examples/cryptobox.cpp b/doc/examples/cryptobox.cpp
index f45f00ca1..38d750d17 100644
--- a/doc/examples/cryptobox.cpp
+++ b/doc/examples/cryptobox.cpp
@@ -27,7 +27,7 @@ int main(int argc, char* argv[])
std::string pass = argv[1];
std::string filename = argv[2];
- std::ifstream input(filename.c_str());
+ std::ifstream input(filename.c_str(), std::ios::binary);
std::vector<byte> file_contents;
while(input.good())
diff --git a/doc/examples/dsa_sign.cpp b/doc/examples/dsa_sign.cpp
index ea23907cf..5f02c0dc1 100644
--- a/doc/examples/dsa_sign.cpp
+++ b/doc/examples/dsa_sign.cpp
@@ -32,7 +32,7 @@ int main(int argc, char* argv[])
try {
std::string passphrase(argv[3]);
- std::ifstream message(argv[2]);
+ std::ifstream message(argv[2], std::ios::binary);
if(!message)
{
std::cout << "Couldn't read the message file." << std::endl;
diff --git a/doc/examples/dsa_ver.cpp b/doc/examples/dsa_ver.cpp
index b30208559..a666259c1 100644
--- a/doc/examples/dsa_ver.cpp
+++ b/doc/examples/dsa_ver.cpp
@@ -47,7 +47,7 @@ int main(int argc, char* argv[])
Botan::LibraryInitializer init;
- std::ifstream message(argv[2]);
+ std::ifstream message(argv[2], std::ios::binary);
if(!message)
{
std::cout << "Couldn't read the message file." << std::endl;
diff --git a/doc/examples/encrypt.cpp b/doc/examples/encrypt.cpp
index b5568ca50..8f53c85e3 100644
--- a/doc/examples/encrypt.cpp
+++ b/doc/examples/encrypt.cpp
@@ -96,7 +96,7 @@ int main(int argc, char* argv[])
return 1;
}
- std::ifstream in(filename.c_str());
+ std::ifstream in(filename.c_str(), std::ios::binary);
if(!in)
{
std::cout << "ERROR: couldn't open " << filename << std::endl;
diff --git a/doc/examples/hash_quickly.cpp b/doc/examples/hash_quickly.cpp
index bf6fe1d82..005a6d719 100644
--- a/doc/examples/hash_quickly.cpp
+++ b/doc/examples/hash_quickly.cpp
@@ -83,7 +83,7 @@ int main(int argc, char* argv[])
for(size_t i = 1; argv[i]; ++i)
{
- std::ifstream in(argv[i]);
+ std::ifstream in(argv[i], std::ios::binary);
if(!in)
continue;
diff --git a/doc/examples/hasher.cpp b/doc/examples/hasher.cpp
index f3f2ab874..e5c52ba55 100644
--- a/doc/examples/hasher.cpp
+++ b/doc/examples/hasher.cpp
@@ -35,7 +35,7 @@ int main(int argc, char* argv[])
Botan::Pipe pipe(new Botan::Fork(hash, COUNT));
- std::ifstream file(argv[j]);
+ std::ifstream file(argv[j], std::ios::binary);
if(!file)
{
std::cout << "ERROR: could not open " << argv[j] << std::endl;
diff --git a/doc/examples/hasher2.cpp b/doc/examples/hasher2.cpp
index abbe11622..b6303b644 100644
--- a/doc/examples/hasher2.cpp
+++ b/doc/examples/hasher2.cpp
@@ -42,7 +42,7 @@ int main(int argc, char* argv[])
new Botan::Hash_Filter(name[2]),
};
- std::ifstream file(argv[j]);
+ std::ifstream file(argv[j], std::ios::binary);
if(!file)
{
std::cout << "ERROR: could not open " << argv[j] << std::endl;
diff --git a/doc/examples/package.cpp b/doc/examples/package.cpp
index 38a2e1666..02cf52816 100644
--- a/doc/examples/package.cpp
+++ b/doc/examples/package.cpp
@@ -18,7 +18,7 @@ namespace {
std::vector<byte> slurp_file(const std::string& filename)
{
- std::ifstream in(filename.c_str());
+ std::ifstream in(filename.c_str(), std::ios::binary);
std::vector<byte> out;
byte buf[4096] = { 0 };
diff --git a/doc/examples/stack.cpp b/doc/examples/stack.cpp
index f569004fc..0c00ed183 100644
--- a/doc/examples/stack.cpp
+++ b/doc/examples/stack.cpp
@@ -70,7 +70,7 @@ int main(int argc, char* argv[])
int skipped = 0;
for(int j = 1; argv[j] != 0; j++)
{
- std::ifstream file(argv[j]);
+ std::ifstream file(argv[j], std::ios::binary);
if(!file)
{
std::cout << "ERROR: could not open " << argv[j] << std::endl;
diff --git a/doc/examples/tls_client.cpp b/doc/examples/tls_client.cpp
index c17ffe4da..854cb3b28 100644
--- a/doc/examples/tls_client.cpp
+++ b/doc/examples/tls_client.cpp
@@ -39,7 +39,9 @@ int main(int argc, char* argv[])
TLS_Policy policy;
- TLS_Client tls(policy, *rng, sock);
+ TLS_Client tls(std::tr1::bind(&Socket::read, std::tr1::ref(sock), _1, _2),
+ std::tr1::bind(&Socket::write, std::tr1::ref(sock), _1, _2),
+ policy, *rng);
printf("Handshake extablished...\n");
diff --git a/doc/log.txt b/doc/log.txt
index 382ccd8d4..392c7beff 100644
--- a/doc/log.txt
+++ b/doc/log.txt
@@ -4,6 +4,7 @@
- Fix a number of CRL encoding and decoding bugs
- Use small tables in the first round of AES
- Add hex encoding/decoding functions that can be used without a Pipe
+ - Add base64 encoding functions that can be used without a Pipe
- Add support for dynamic engine loading on Windows
- Allow using PBKDF2 with empty passphrases
- Switch default PKCS #8 encryption algorithm from AES-128 to AES-256