我得到的消息時,我嘗試登入交易:NBitcoin拋出InvalidOperationException異常消息:「Mac HMACSHA256無法識別。」
Transaction payment = new Transaction();
BitcoinSecret PaymentSecret = new BitcoinSecret("1sXCvdpXz...UqkXW9mvT");
...
payment.Sign(Container.PaymentSecret, false);
我深入到開源NBitcoin API,並計算出這些行給我的錯誤信息。我能做什麼? (https://github.com/NicolasDorier/NBitcoin/blob/master/NBitcoin/Crypto/DeterministicECDSA.cs)
try
{
hmac = MacUtilities.GetMac(macName);
}
catch(SecurityUtilityException nsae)
{
throw new InvalidOperationException(nsae.Message, nsae);
}
事實上,它的工作方式。 – nopara73