pub fn validate_nonce( data: &str, nonce: u128, difficulty: u128, hash_func_name: &str, ) -> Result<bool, Box<dyn Error>>