aboutsummaryrefslogtreecommitdiffstats
path: root/src/stream/turing/turing.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/stream/turing/turing.cpp')
-rw-r--r--src/stream/turing/turing.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/stream/turing/turing.cpp b/src/stream/turing/turing.cpp
index 1e2203480..810f65ca4 100644
--- a/src/stream/turing/turing.cpp
+++ b/src/stream/turing/turing.cpp
@@ -257,15 +257,15 @@ void Turing::key_schedule(const byte key[], u32bit length)
S3[i] = (W3 & 0xFFFFFF00) | C3;
}
- resync(0, 0);
+ set_iv(0, 0);
}
/*
* Resynchronization
*/
-void Turing::resync(const byte iv[], u32bit length)
+void Turing::set_iv(const byte iv[], u32bit length)
{
- if(length % 4 != 0 || length > 16)
+ if(!valid_iv_length(length))
throw Invalid_IV_Length(name(), length);
SecureVector<u32bit> IV(length / 4);
@@ -295,7 +295,7 @@ void Turing::resync(const byte iv[], u32bit length)
/*
* Clear memory of sensitive data
*/
-void Turing::clear() throw()
+void Turing::clear()
{
S0.clear();
S1.clear();