Abstract
My project would be to explore Intel’s open source library (for C++), named TBB (Threading Building Blocks), and make its use to analyze performance gain for the implementation of OCB (Offset Codebook). The analysis would begin with identifying the parallel portions inside an OCB algorithm, followed by its implementation using TBB. After that I would analyze the performance gain obtained by changing various parameters of the OCB algorithm. TBB(Threading Building Blocks) : It is Intel’s open source template library for C++. The aim of it is to provide task level parallelism as opposed to thread level parallelism. It makes implementation more portable and easy to understand. TBB library internally keeps a pool of worker threads. The application developer needs to specify the parallel portion of the application and most of the remaining work is taken care of by the TBB library. The library determines iv required no of threads for the task and schedules them on available processor cores. TBB uses work-stealing scheduler design to schedule its threads. For developers, the benefits of TBB are : 1. It reduces the length of the code for a multithreaded application. 2. It relieves the programmer from handling all the thread management stuff. 3. It automatically identifies the underlying system and determines optimal no of threads. It also automatically balances the work load between these threads and makes maximum use of all the available processor cores to achieve maximum performance. 4. The applications developed using TBB automatically becomes portable and scalable to machines with any no of core. OCB(Offset Codebook) : It is a shared key encryption - authentication scheme, built from a block cipher. OCB achieves authenticated encryption in essentially the same amount of time as other modes, like CBC, achieve privacy alone. Or in other words we can say that it takes about half the time as "conventional" modes, like CCM, to achieve privacy and authenticity combined. On top of this OCB is a simple, easy and highly parallelizable method which can be easily implemented in hardware and software. It can also be proved that it is as secure as its underlying primitive algorithms. Some of the key features of OCB are : 1. It can encrypt messages of any bit length and messages don’t have to be multiple of the block length. 2. Encryption and decryption depend on an n-bit nonce N, which must be selected as a new value for each encryption. The nonce need not be random or secret. 3. It is an on-line algorithm, meaning one need not know the length of the header or message to proceed with encryption, and one need not know the length of header or cipher text to proceed with decryption. 4. OCB is parallelizable : the bulk of its block cipher calls may be performed simultaneously. Thus OCB is suitable for encrypting messages in hardware at the highest network speeds. 5. It needs very little memory to run. 6. It is nearly endian-neutral.