aboutsummaryrefslogtreecommitdiffstats
path: root/community/softhsm/softhsm-2.5.0-botan_ecb-exception-fix.patch
blob: a71081e0eed837d31fa97fa3f5d67841515e470e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
commit a9a40fc64635cfb924279cae3c42e6946e89718c
Author: tcely <tcely@users.noreply.github.com>
Date:   Wed Mar 6 07:14:32 2019 -0500

    fix protected Exception usage

diff --git a/src/lib/crypto/Botan_ecb.cpp b/src/lib/crypto/Botan_ecb.cpp
index f27276e..6947aab 100644
--- a/src/lib/crypto/Botan_ecb.cpp
+++ b/src/lib/crypto/Botan_ecb.cpp
@@ -108,7 +108,7 @@ void ECB_Encryption::finish(secure_vector<byte>& buffer, size_t offset)
    padding().add_padding(buffer, bytes_in_final_block, BS);
 
    if(buffer.size() % BS)
-      throw Exception("Did not pad to full block size in " + name());
+      throw Invalid_State("Did not pad to full block size in " + name());
 
    update(buffer, offset);
    }