本文介绍了HMAC-SHA256在德尔福的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要为Amazon Web服务API生成HMAC-SHA256签名。旧的DCPcrypt库具有sha256例程,但不进行HMAC签名。任何人都知道可以使用的免费散列图书馆?
I need to generate HMAC-SHA256 signatures for the Amazon web services API. The old DCPcrypt library has sha256 routines but does not do HMAC signing. Anyone know of a free hashing library I could use?
推荐答案
经过多一点搜索,我发现OpenStreamSec - 它看起来像几年前被遗弃,但仍在D2007中编译。
After a little more searching I found OpenStreamSec - which looks like it was abandoned a few years ago but still compiles in D2007.
为Amazon生成HMAC-256非常简单:
Generating a HMAC-256 for Amazon is really simple:
StrToMime64(HMACString(haSHA256, SecretKey, 32, DataToHash));
这篇关于HMAC-SHA256在德尔福的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!