Error The invoice hash API body does not match the (calculated) Hash of the XML

this my code
string certBase64 = Encoding.UTF8.GetString(Convert.FromBase64String(currentCompliance.binarySecurityToken));

    byte\[\] privateKeyBytes = Convert.FromBase64String(currentCompliance.privateKey_Base64);
    string privateKeyPem = Encoding.UTF8.GetString(privateKeyBytes);


    EInvoiceSigner signer = new EInvoiceSigner();


    SignResult result = signer.SignDocument(xmlDocument, certBase64, privateKeyPem);

i use sdk 3.4.8

and i use simulate