switch hexdigest calculation