diff options
author | Martin Willi <martin@revosec.ch> | 2010-08-20 15:57:47 +0200 |
---|---|---|
committer | Martin Willi <martin@revosec.ch> | 2010-08-23 09:47:03 +0200 |
commit | 3c19b3461f835b901395b3335d6456ca60dbe5ab (patch) | |
tree | 48b72a86bd7fa4ec3f14ff3240cae96d15334eb8 /src/libtls/tls_protection.c | |
parent | 0bcef5fe7a8f5fdd3b3e782f033b34ddc7e11ed1 (diff) | |
download | strongswan-3c19b3461f835b901395b3335d6456ca60dbe5ab.tar.bz2 strongswan-3c19b3461f835b901395b3335d6456ca60dbe5ab.tar.xz |
Introducing a dedicated debug message group for libtls
Diffstat (limited to 'src/libtls/tls_protection.c')
-rw-r--r-- | src/libtls/tls_protection.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/libtls/tls_protection.c b/src/libtls/tls_protection.c index 107751e92..90b30f99b 100644 --- a/src/libtls/tls_protection.c +++ b/src/libtls/tls_protection.c @@ -116,7 +116,7 @@ METHOD(tls_protection_t, process, status_t, { /* < TLSv1.1 uses IV from key derivation/last block */ if (data.len < bs || data.len % bs) { - DBG1(DBG_IKE, "encrypted TLS record length invalid"); + DBG1(DBG_TLS, "encrypted TLS record length invalid"); return FAILED; } iv = this->iv_in; @@ -129,7 +129,7 @@ METHOD(tls_protection_t, process, status_t, data = chunk_skip(data, iv.len); if (data.len < bs || data.len % bs) { - DBG1(DBG_IKE, "encrypted TLS record length invalid"); + DBG1(DBG_TLS, "encrypted TLS record length invalid"); return FAILED; } } @@ -144,7 +144,7 @@ METHOD(tls_protection_t, process, status_t, padding_length = data.ptr[data.len - 1]; if (padding_length >= data.len) { - DBG1(DBG_IKE, "invalid TLS record padding"); + DBG1(DBG_TLS, "invalid TLS record padding"); return FAILED; } data.len -= padding_length + 1; @@ -157,7 +157,7 @@ METHOD(tls_protection_t, process, status_t, bs = this->signer_in->get_block_size(this->signer_in); if (data.len <= bs) { - DBG1(DBG_IKE, "TLS record too short to verify MAC"); + DBG1(DBG_TLS, "TLS record too short to verify MAC"); return FAILED; } mac = chunk_skip(data, data.len - bs); @@ -168,7 +168,7 @@ METHOD(tls_protection_t, process, status_t, macdata = chunk_cat("mc", header, data); if (!this->signer_in->verify_signature(this->signer_in, macdata, mac)) { - DBG1(DBG_IKE, "TLS record MAC verification failed"); + DBG1(DBG_TLS, "TLS record MAC verification failed"); free(macdata.ptr); return FAILED; } @@ -228,7 +228,7 @@ METHOD(tls_protection_t, build, status_t, { /* TLSv1.1 uses random IVs, prepended to record */ if (!this->rng) { - DBG1(DBG_IKE, "no RNG supported to generate TLS IV"); + DBG1(DBG_TLS, "no RNG supported to generate TLS IV"); free(data->ptr); return FAILED; } |