|
|
@ -41,20 +41,28 @@ public class IdCardCryptoUtil { |
|
|
String userIdCode = IdCardCryptoUtil.symmetricEncryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "1608434855568265217"); |
|
|
String userIdCode = IdCardCryptoUtil.symmetricEncryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "1608434855568265217"); |
|
|
String userNameCode = IdCardCryptoUtil.symmetricEncryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "汤家荣"); |
|
|
String userNameCode = IdCardCryptoUtil.symmetricEncryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "汤家荣"); |
|
|
|
|
|
|
|
|
String secret = IdCardCryptoUtil.symmetricEncryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "fed73fcc-0cae-44da-bbae-5a47f9688b4e"); |
|
|
// String secret = IdCardCryptoUtil.symmetricEncryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "fed73fcc-0cae-44da-bbae-5a47f9688b4e");
|
|
|
// String phone = IdCardCryptoUtil.symmetricDecryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "0PPEx9wD2DLva7zpWJt8MQ==");
|
|
|
// String phone = IdCardCryptoUtil.symmetricDecryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", "0PPEx9wD2DLva7zpWJt8MQ==");
|
|
|
|
|
|
|
|
|
// System.out.println(userIdCode);
|
|
|
// System.out.println(userIdCode);
|
|
|
// System.out.println(phone);
|
|
|
// System.out.println(phone);
|
|
|
|
|
|
|
|
|
// System.out.println(userNameCode);
|
|
|
// System.out.println(userNameCode);
|
|
|
System.out.println(secret); |
|
|
// System.out.println(secret);
|
|
|
// Map<String,Object> heardMap = new HashMap<>();
|
|
|
Map<String,Object> heardMap = new HashMap<>(); |
|
|
// heardMap.put("x-auth-channel", IdUtil.simpleUUID());
|
|
|
heardMap.put("x-auth-channel", IdUtil.simpleUUID()); |
|
|
// heardMap.put("x-auth-app-code","zfjdm");
|
|
|
heardMap.put("x-auth-app-code","zfjdm"); |
|
|
// String s = IdCardCryptoUtil.httpSendPost("http://egbpub.siqhz.com/egb/api/thirdauth/pub/auth/token?userId=" +userIdCode+ "&userName="+ userNameCode,
|
|
|
String s = IdCardCryptoUtil.httpSendPost("http://egbpub.siqhz.com/egb/api/thirdauth/pub/auth/token",userIdCode,userNameCode,"zfjdm"); |
|
|
// "userId= " + userIdCode + "&userName=" + userNameCode, heardMap);
|
|
|
System.out.println(s); |
|
|
// System.out.println(s);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String secret = IdCardCryptoUtil.symmetricEncryptIdCard("eWIzY3BMRVNEQXhvUUlXMA==", s); |
|
|
|
|
|
Map<String,Object> params = new HashMap<>(); |
|
|
|
|
|
params.put("accessKeySign",secret); |
|
|
|
|
|
params.put("appCode","zfjdm"); |
|
|
|
|
|
String data = HttpUtil.httpSendPost("http://egbpub.siqhz.com/egb/api/thirdauth/pub/auth/getUserInfo", |
|
|
|
|
|
JSONObject.toJSONString(params),new HashMap<>()); |
|
|
|
|
|
System.out.println(data); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|