Sha implementations corrected
Sha TH optimized to improve performance