File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
java/advanced/RewardedSSVExample/src/main/java/com/example/rewardedssv Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change 11package com .example .rewardedssv ;
22
3+ import static java .nio .charset .StandardCharsets .UTF_8 ;
4+
35import com .google .crypto .tink .subtle .Base64 ;
46import com .google .crypto .tink .subtle .EcdsaVerifyJce ;
57import com .google .crypto .tink .subtle .EllipticCurves ;
1012import java .io .InputStreamReader ;
1113import java .net .HttpURLConnection ;
1214import java .net .URL ;
13- import java .nio .charset .Charset ;
1415import java .security .GeneralSecurityException ;
1516import java .security .interfaces .ECPublicKey ;
1617import java .util .Enumeration ;
@@ -101,9 +102,7 @@ public ResponseEntity<?> index(HttpServletRequest request) {
101102 https://developers.google.com/admob/android/rewarded-video-ssv#get_content_to_be_verified
102103 */
103104 byte [] payload =
104- queryString
105- .substring (0 , queryString .indexOf (SIGNATURE_PARAM_KEY ) - 1 )
106- .getBytes (Charset .forName ("UTF-8" ));
105+ queryString .substring (0 , queryString .indexOf (SIGNATURE_PARAM_KEY ) - 1 ).getBytes (UTF_8 );
107106
108107 response .put ("payload" , new String (payload ));
109108 response .put ("key_id" , keyId .toString ());
You can’t perform that action at this time.
0 commit comments