Compact and unified hardware architecture for SHA-1 and SHA-256 of trusted mobile computing