* keyArray: loginUserId用逗号拼接的字符串
javapublic String authToken(String projectKeyId, String secretKey, String keyArray) throws Exception {
String message = "ai="+projectKeyId+"&loginUserId="+keyArray;
Mac hmac = Mac.getInstance("HmacSHA256");
hmac.init(new SecretKeySpec(secretKey.getBytes("UTF-8"), "HmacSHA256"));
byte[] signature = hmac.doFinal(message.getBytes("UTF-8"));
return Hex.encodeHexString(signature);