From 1caa9258685fa5fad8935d3bfcd0eac7d7f84f1e Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Sat, 19 Dec 2015 14:41:39 +0100 Subject: Increase GCM IV size from 96 to 128 bits This pushes back the birthday bound for collisions to make it virtually irrelevant. --- cryptfs/address_translation.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cryptfs/address_translation.go') diff --git a/cryptfs/address_translation.go b/cryptfs/address_translation.go index 147040c..b21cfc7 100644 --- a/cryptfs/address_translation.go +++ b/cryptfs/address_translation.go @@ -44,7 +44,7 @@ func (be *CryptFS) CipherSizeToPlainSize(cipherSize uint64) uint64 { blockNo := be.CipherOffToBlockNo(cipherSize - 1) blockCount := blockNo + 1 - overhead := BLOCK_OVERHEAD*blockCount + HEADER_LEN + overhead := be.BlockOverhead()*blockCount + HEADER_LEN return cipherSize - overhead } @@ -56,7 +56,7 @@ func (be *CryptFS) PlainSizeToCipherSize(plainSize uint64) uint64 { blockNo := be.PlainOffToBlockNo(plainSize - 1) blockCount := blockNo + 1 - overhead := BLOCK_OVERHEAD*blockCount + HEADER_LEN + overhead := be.BlockOverhead()*blockCount + HEADER_LEN return plainSize + overhead } -- cgit v1.2.3