修改
This commit is contained in:
@@ -16,7 +16,7 @@ import java.util.Map;
|
|||||||
* @date: 2024/12/11
|
* @date: 2024/12/11
|
||||||
**/
|
**/
|
||||||
@Service
|
@Service
|
||||||
public class ClientService2 {
|
public class ClientService {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private AppKeyConfig appKeyConfig;
|
private AppKeyConfig appKeyConfig;
|
||||||
@@ -24,7 +24,7 @@ public class SignatureUtil {
|
|||||||
*/
|
*/
|
||||||
public static String generateSignature(Map<String, String> parameters, String secret) throws UnsupportedEncodingException, NoSuchAlgorithmException {
|
public static String generateSignature(Map<String, String> parameters, String secret) throws UnsupportedEncodingException, NoSuchAlgorithmException {
|
||||||
//1.对参数进行排序
|
//1.对参数进行排序
|
||||||
Map<tring, String> treeMap=new TreeMap<>(parameters);
|
Map<String, String> treeMap = new TreeMap<>(parameters);
|
||||||
// 2. 拼接参数字符串
|
// 2. 拼接参数字符串
|
||||||
String content = joinParameters(treeMap);
|
String content = joinParameters(treeMap);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user