用Quicker可以实现AES加密+SHA签名吗?

动作需求 · 1479 次浏览
NoahWong 创建于 2020-11-11 12:16

用Quicker可以实现AES加密+SHA签名吗?

样例:

https://gw2.wishingstarmoye.com/gw2api/gw2crafts

POST数据

sign=19fa0207173de41f6c75482a46608a094cd0a462
&nonce=CAHAaJu8KQBRISXr
&data=kDkvUHkdIOs+erJg70ZICpW1THLMK6HMr1GHcIjH2eU0dDcSA+6eBP4nQnSx1zBgLwVNYJ3IuBxcP/TimBwhMoqKFFxKpEUdcaugS7OcMI43R96u2pr9Wruzi9wImCYv24gzdTOTHOsMqnsYH+ErncIDmS+eNG9uDY1kdoOrXWympZ/tjPDeoTp1OLSBWA5+UsMn8JsV5UwMMYYiIe2VI5U9XuzL+95YI6WsAdW/NhIaUSrGyniQYfnfkpxFMrBtBMnaWZ83db3yQrAf1JNPcByEiJgVR/9RAlnXvCs9WWc2djhlHEiMRz6NlmPTwaVAOvGFRKyCd3ZkW4Y3/uDhqiFY1CgP7VfkYqDyerwPibbiCa70Bi39oIh+dWzazw3ukVKd1v2+rEhfnmbMq66/Vl+E8BQcKNM8Ico++btOUoE1FOgs8hYmaaL9PUZ/mvkzbzD9WPfaHJBquca33xl9AZ7yknMapBzp7ROnCIZe9SP20+Zb5wXTODWJzlQ/QryENQaPvxbGQBcDeu6p7iS61EX6jlmS3f0CWWKmTbC5cMtpI20IsS03aLlhClA3TcUAYjzvabUCeWUnZ64IwK/QRXUygMWHD/VcGE6VzGm5dnUUXNbtYzMKDYqVEepS8nLKOWgYwKt6l8BMF4rprxCeBo39yYxTdGmuRCEuuSY/IzgaAQvggNapsUbIulwJnDPMkYnLawEo4Szx/ex1WOvIyJTsG6tjeCJWqZIgagWrlYufgqTtUOi+8CnxyMRFtuDzQmOVONpc2BZ4lFlcbP++L8rzg/TaGE5dbvyyy1t9NN9kpLG6L4evHWYyjm/gyFMpqyNz+a8DSvsCn9Vj3xDj94OXblHeSIvd6bxnzVWTDxrw5UPJvlgMMCbmqJlarskvW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92SeHPgHdP9b6sNoGXD3SlN+sA7vyZxAoIqvt/KvQpMvFkUN2U7Ee6fSGP5bgTKTmmT4fmBXbqezjmzBBygXfnFHTbYMSXkGgK6rtktpkRavMjS/eFL5qtvOCKfW5dixxI4ivSPSAdIO7imkB1haT6tW+iQJvhvCb4TpBQ0iIYvXOOnM3qIXhSkMyNSubBcM76nyQBSWjNH52wsHjMViKDB3/w3ypZmC6sxcDgqNydGujklz4nU6iZySdCviHOGSmvcKVT6g3LIexI3oj52YVcOI80ivVNn0ssbOq856/VRibSq02+x6l91UiP9Po+/mSR6nQYIoxW0pgY+OLIL0/2lEHClCAKUQ6YxGsjN+TWrpqZLzMHc15/OLM1AxhEyWUzoAk0mI5zZvORjiHCmIdDxGLW9VdN0c4/5D4M26IFAb3zFd3ax+yKmorgM=

固定参数:
token=U7aGiqz8P0k2Tcf3wig0
aeskey=MfNBeTrC6ut4aM864HZAlyVqhhxn9sf30ZxVDWILxIg

参数说明:
sign:签名,SHA1(token + nonce + 加密后的数据)
nonce:随机字符串,由客户端自己生成,长度不限,非空
data:加密后的数据

数据加密:
算法:AES-256-CBC
密钥:aeskey在末尾追加=号并进行base64解码(密钥为二进制数据,非文本)
IV向量:密钥的前16个字节 (二进制数据,非文本)
加密前的明文数据:数组格式,例如 ["test", "test1"]

响应:
名值对
{"test":"测试","test1":"测试1"}

NoahWong 最后更新于 2020/11/12

回复内容
Cesar 2020-11-11 13:00
#1
可以实现,用c#脚本
NoahWong 2020-11-11 13:35 :

大佬有空写一个吗

Cesar 回复 NoahWong 2020-11-11 14:52 :

AES加密密钥是byte[]?

NoahWong 回复 Cesar 2020-11-11 14:53 :

算法:AES-256-CBC

密钥:aeskey在末尾追加=号并进行base64解码(密钥为二进制数据,非文本)

IV向量:密钥的前16个字节 (二进制数据,非文本)

加密前的明文数据:数组格式,例如 ["test", "test1"]

NoahWong 最后更新于 2020-11-11 14:54
Cesar 2020-11-11 16:22
#2

https://getquicker.net/SubProgram?id=4e301704-017f-4cfa-6fb0-08d885e79281

Cesar 2020-11-12 09:55
#3
想问一下使用是否正常,我这里没有进行测试,因为没有可用的测试数据
NoahWong 2020-11-12 09:58 :

其实我试了之后有点问题,会显示输入的不是有效的Base-64字符串,因为它包含非Base-64字符、两个以上的填充字符,或者填充字符间包含非法字符。

Cesar 回复 NoahWong 2020-11-12 10:00 :

你能给我发一个可测试的样本吗,并且给我正确答案,我由此进行对照

NoahWong 回复 Cesar 2020-11-12 10:01 :

我把内容扩充到主楼了,你看一下

NoahWong 回复 Cesar 2020-11-12 10:03 :

我这个需求其实是“发送英文数据,从这个数据库中获得英文对应的中文”,不过好像需要经过加密。

Cesar 回复 NoahWong 2020-11-12 10:15 :

我试了下,有点小bug,更新了。另外你是不是没有给key手动加=

NoahWong 回复 Cesar 2020-11-12 10:18 :
Cesar 回复 NoahWong 2020-11-12 10:20 :


NoahWong 回复 Cesar 2020-11-12 10:23 :

得到了这个? Po6W2g9iLqzuHUM9KSPYT2/LvORq7azCf0NqXXOkPvc=

Cesar 回复 NoahWong 2020-11-12 10:24 :

有啥问题吗

NoahWong 回复 Cesar 2020-11-12 10:26 :

没,我就是确定一下,我也不知道得到的是不是对的

NoahWong 回复 Cesar 2020-11-12 10:32 :

请问nonce是什么。。怎么获得的

Cesar 回复 NoahWong 2020-11-12 10:33 :

nonce你自己生成就好了

NoahWong 回复 Cesar 2020-11-12 10:37 :

可是不知道怎么生成。。

Cesar 回复 NoahWong 2020-11-12 10:38 :

你先自己随便填一个就行,自己随便敲几个字母


NoahWong 回复 NoahWong 2020-11-12 11:02 :

 

NoahWong 最后更新于 2020-11-12 11:03
NoahWong 回复 Cesar 2020-11-12 11:03 :

上面那个样例data为什么我一直返回的error,请问是哪里设置不对吗?https://getquicker.net/sharedaction?code=e2d44b2b-7b24-4182-6fc4-08d885e79281

Cesar 回复 NoahWong 2020-11-12 11:07 :

这个就不清楚了

NoahWong 回复 Cesar 2020-11-12 11:08 :

好吧

回复主贴