You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: provenances.rs
    path of file: ./repos/holochain-rust/crates/core/src/nucleus/validation
    
    the code of the file until where you have to start completion: use crate::nucleus::validation::{ValidationError, ValidationResult};
use boolinator::Boolinator;
use holochain_core_types::validation::ValidationData;
use holochain_dpki::utils::Verify;

#[holochain_tracing_macros::newrelic_autotrace(HOLOCHAIN_CORE)]
pub fn validate_provenances(validation_data: &ValidationData) -> ValidationResult {
    let header = &validation_data.package.chain_header;
    header
        .provenances()
       
    
pub fn validate_provenances(validation_data: &ValidationData) -> ValidationResult {
    let header = &validation_data.package.chain_header;
    header
        .provenances()
        .iter()
        .map(|provenance| {
            let maybe_has_authored = provenance.verify(header.entry_address().to_string());
            match maybe_has_authored {
                Err(_) => {
                    Err(ValidationError::Fail(format!(
                        "Signature of entry {} from author {} failed to verify public signing key. Key might be invalid.",
                        header.entry_address(),
                        provenance.source(),
                    )))
                },
                Ok(has_authored) => {
                    has_authored.ok_or(ValidationError::Fail(format!(
                        "Signature of entry {} from author {} invalid",
                        header.entry_address(),
                        provenance.source(),
                    )))
                },
            }
        })
        .collect::<Result<Vec<()>, ValidationError>>()?;
    Ok(())
}