We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EntPayServiceImpl.encryptRSA 打包编译出错
打包后编译如下: package com.github.binarywang.wxpay.service.impl;
import com.github.binarywang.wxpay.bean.entpay.EntPayBankQueryRequest; import com.github.binarywang.wxpay.bean.entpay.EntPayBankQueryResult; import com.github.binarywang.wxpay.bean.entpay.EntPayBankRequest; import com.github.binarywang.wxpay.bean.entpay.EntPayBankResult; import com.github.binarywang.wxpay.bean.entpay.EntPayQueryRequest; import com.github.binarywang.wxpay.bean.entpay.EntPayQueryResult; import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackQueryRequest; import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackQueryResult; import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackRequest; import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackResult; import com.github.binarywang.wxpay.bean.entpay.EntPayRequest; import com.github.binarywang.wxpay.bean.entpay.EntPayResult; import com.github.binarywang.wxpay.bean.entpay.GetPublicKeyResult; import com.github.binarywang.wxpay.bean.entwxpay.EntWxEmpPayRequest; import com.github.binarywang.wxpay.bean.request.WxPayDefaultRequest; import com.github.binarywang.wxpay.bean.result.BaseWxPayResult; import com.github.binarywang.wxpay.config.WxPayConfig; import com.github.binarywang.wxpay.exception.WxPayException; import com.github.binarywang.wxpay.service.EntPayService; import com.github.binarywang.wxpay.service.WxPayService; import com.github.binarywang.wxpay.util.SignUtils; import java.io.File; import java.nio.charset.StandardCharsets; import java.nio.file.Files; import java.nio.file.OpenOption; import java.nio.file.Path; import java.nio.file.attribute.FileAttribute;
public class EntPayServiceImpl implements EntPayService {
中间省略
/* Error */ private String encryptRSA(File publicKeyFile, String srcString) throws WxPayException { // Byte code: // 0: new 101 org/bouncycastle/jce/provider/BouncyCastleProvider // 3: dup // 4: invokespecial 102 org/bouncycastle/jce/provider/BouncyCastleProvider: ()V // 7: invokestatic 103 java/security/Security:addProvider (Ljava/security/Provider;)I // 10: pop // 11: ldc 104 // 13: invokestatic 105 javax/crypto/Cipher:getInstance (Ljava/lang/String;)Ljavax/crypto/Cipher; // 16: astore_3 // 17: new 106 org/bouncycastle/openssl/PEMParser // 20: dup // 21: new 107 java/io/FileReader // 24: dup // 25: aload_1 // 26: invokespecial 108 java/io/FileReader: (Ljava/io/File;)V // 29: invokespecial 109 org/bouncycastle/openssl/PEMParser: (Ljava/io/Reader;)V // 32: astore 4 // 34: new 110 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter // 37: dup // 38: invokespecial 111 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter: ()V // 41: ldc 112 // 43: invokevirtual 113 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter:setProvider (Ljava/lang/String;)Lorg/bouncycastle/openssl/jcajce/JcaPEMKeyConverter; // 46: aload 4 // 48: invokevirtual 114 org/bouncycastle/openssl/PEMParser:readObject ()Ljava/lang/Object; // 51: checkcast 115 org/bouncycastle/asn1/x509/SubjectPublicKeyInfo // 54: invokevirtual 116 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter:getPublicKey (Lorg/bouncycastle/asn1/x509/SubjectPublicKeyInfo;)Ljava/security/PublicKey; // 57: astore 5 // 59: aload_3 // 60: iconst_1 // 61: aload 5 // 63: invokevirtual 118 javax/crypto/Cipher:init (ILjava/security/Key;)V // 66: aload_3 // 67: aload_2 // 68: getstatic 119 java/nio/charset/StandardCharsets:UTF_8 Ljava/nio/charset/Charset; // 71: invokevirtual 120 java/lang/String:getBytes (Ljava/nio/charset/Charset;)[B // 74: invokevirtual 121 javax/crypto/Cipher:doFinal ([B)[B // 77: astore 6 // 79: invokestatic 122 java/util/Base64:getEncoder ()Ljava/util/Base64$Encoder; // 82: aload 6 // 84: invokevirtual 123 java/util/Base64$Encoder:encodeToString ([B)Ljava/lang/String; // 87: astore 7 // 89: aload 4 // 91: invokevirtual 124 org/bouncycastle/openssl/PEMParser:close ()V // 94: aload 7 // 96: areturn // 97: astore 5 // 99: aload 4 // 101: invokevirtual 124 org/bouncycastle/openssl/PEMParser:close ()V // 104: goto +12 -> 116 // 107: astore 6 // 109: aload 5 // 111: aload 6 // 113: invokevirtual 126 java/lang/Throwable:addSuppressed (Ljava/lang/Throwable;)V // 116: aload 5 // 118: athrow // 119: astore_3 // 120: new 128 com/github/binarywang/wxpay/exception/WxPayException // 123: dup // 124: ldc -127 // 126: aload_3 // 127: invokespecial 130 com/github/binarywang/wxpay/exception/WxPayException: (Ljava/lang/String;Ljava/lang/Throwable;)V // 130: athrow // Line number table: // Java source line #175 -> byte code offset #0 // Java source line #176 -> byte code offset #11 // Java source line #177 -> byte code offset #17 // Java source line #178 -> byte code offset #34 // Java source line #179 -> byte code offset #48 // Java source line #181 -> byte code offset #59 // Java source line #182 -> byte code offset #66 // Java source line #183 -> byte code offset #79 // Java source line #184 -> byte code offset #89 // Java source line #183 -> byte code offset #94 // Java source line #177 -> byte code offset #97 // Java source line #185 -> byte code offset #119 // Java source line #186 -> byte code offset #120 // Local variable table: // start length slot name signature // 0 131 0 this EntPayServiceImpl // 0 131 1 publicKeyFile File // 0 131 2 srcString String // 16 51 3 cipher javax.crypto.Cipher // 119 8 3 e Exception // 32 68 4 reader org.bouncycastle.openssl.PEMParser // 57 5 5 publicKey java.security.PublicKey // 97 20 5 localThrowable Throwable // 77 6 6 encrypt byte[] // 107 5 6 localThrowable1 Throwable // 87 8 7 str String // Exception table: // from to target type // 34 89 97 java/lang/Throwable // 99 104 107 java/lang/Throwable // 0 94 119 java/lang/Exception // 97 119 119 java/lang/Exception } }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
简要描述
EntPayServiceImpl.encryptRSA 打包编译出错
模块版本情况
详细描述
打包后编译如下:
package com.github.binarywang.wxpay.service.impl;
import com.github.binarywang.wxpay.bean.entpay.EntPayBankQueryRequest;
import com.github.binarywang.wxpay.bean.entpay.EntPayBankQueryResult;
import com.github.binarywang.wxpay.bean.entpay.EntPayBankRequest;
import com.github.binarywang.wxpay.bean.entpay.EntPayBankResult;
import com.github.binarywang.wxpay.bean.entpay.EntPayQueryRequest;
import com.github.binarywang.wxpay.bean.entpay.EntPayQueryResult;
import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackQueryRequest;
import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackQueryResult;
import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackRequest;
import com.github.binarywang.wxpay.bean.entpay.EntPayRedpackResult;
import com.github.binarywang.wxpay.bean.entpay.EntPayRequest;
import com.github.binarywang.wxpay.bean.entpay.EntPayResult;
import com.github.binarywang.wxpay.bean.entpay.GetPublicKeyResult;
import com.github.binarywang.wxpay.bean.entwxpay.EntWxEmpPayRequest;
import com.github.binarywang.wxpay.bean.request.WxPayDefaultRequest;
import com.github.binarywang.wxpay.bean.result.BaseWxPayResult;
import com.github.binarywang.wxpay.config.WxPayConfig;
import com.github.binarywang.wxpay.exception.WxPayException;
import com.github.binarywang.wxpay.service.EntPayService;
import com.github.binarywang.wxpay.service.WxPayService;
import com.github.binarywang.wxpay.util.SignUtils;
import java.io.File;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.OpenOption;
import java.nio.file.Path;
import java.nio.file.attribute.FileAttribute;
public class EntPayServiceImpl
implements EntPayService
{
中间省略
/* Error */
private String encryptRSA(File publicKeyFile, String srcString)
throws WxPayException
{
// Byte code:
// 0: new 101 org/bouncycastle/jce/provider/BouncyCastleProvider
// 3: dup
// 4: invokespecial 102 org/bouncycastle/jce/provider/BouncyCastleProvider: ()V
// 7: invokestatic 103 java/security/Security:addProvider (Ljava/security/Provider;)I
// 10: pop
// 11: ldc 104
// 13: invokestatic 105 javax/crypto/Cipher:getInstance (Ljava/lang/String;)Ljavax/crypto/Cipher;
// 16: astore_3
// 17: new 106 org/bouncycastle/openssl/PEMParser
// 20: dup
// 21: new 107 java/io/FileReader
// 24: dup
// 25: aload_1
// 26: invokespecial 108 java/io/FileReader: (Ljava/io/File;)V
// 29: invokespecial 109 org/bouncycastle/openssl/PEMParser: (Ljava/io/Reader;)V
// 32: astore 4
// 34: new 110 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter
// 37: dup
// 38: invokespecial 111 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter: ()V
// 41: ldc 112
// 43: invokevirtual 113 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter:setProvider (Ljava/lang/String;)Lorg/bouncycastle/openssl/jcajce/JcaPEMKeyConverter;
// 46: aload 4
// 48: invokevirtual 114 org/bouncycastle/openssl/PEMParser:readObject ()Ljava/lang/Object;
// 51: checkcast 115 org/bouncycastle/asn1/x509/SubjectPublicKeyInfo
// 54: invokevirtual 116 org/bouncycastle/openssl/jcajce/JcaPEMKeyConverter:getPublicKey (Lorg/bouncycastle/asn1/x509/SubjectPublicKeyInfo;)Ljava/security/PublicKey;
// 57: astore 5
// 59: aload_3
// 60: iconst_1
// 61: aload 5
// 63: invokevirtual 118 javax/crypto/Cipher:init (ILjava/security/Key;)V
// 66: aload_3
// 67: aload_2
// 68: getstatic 119 java/nio/charset/StandardCharsets:UTF_8 Ljava/nio/charset/Charset;
// 71: invokevirtual 120 java/lang/String:getBytes (Ljava/nio/charset/Charset;)[B
// 74: invokevirtual 121 javax/crypto/Cipher:doFinal ([B)[B
// 77: astore 6
// 79: invokestatic 122 java/util/Base64:getEncoder ()Ljava/util/Base64$Encoder;
// 82: aload 6
// 84: invokevirtual 123 java/util/Base64$Encoder:encodeToString ([B)Ljava/lang/String;
// 87: astore 7
// 89: aload 4
// 91: invokevirtual 124 org/bouncycastle/openssl/PEMParser:close ()V
// 94: aload 7
// 96: areturn
// 97: astore 5
// 99: aload 4
// 101: invokevirtual 124 org/bouncycastle/openssl/PEMParser:close ()V
// 104: goto +12 -> 116
// 107: astore 6
// 109: aload 5
// 111: aload 6
// 113: invokevirtual 126 java/lang/Throwable:addSuppressed (Ljava/lang/Throwable;)V
// 116: aload 5
// 118: athrow
// 119: astore_3
// 120: new 128 com/github/binarywang/wxpay/exception/WxPayException
// 123: dup
// 124: ldc -127
// 126: aload_3
// 127: invokespecial 130 com/github/binarywang/wxpay/exception/WxPayException: (Ljava/lang/String;Ljava/lang/Throwable;)V
// 130: athrow
// Line number table:
// Java source line #175 -> byte code offset #0
// Java source line #176 -> byte code offset #11
// Java source line #177 -> byte code offset #17
// Java source line #178 -> byte code offset #34
// Java source line #179 -> byte code offset #48
// Java source line #181 -> byte code offset #59
// Java source line #182 -> byte code offset #66
// Java source line #183 -> byte code offset #79
// Java source line #184 -> byte code offset #89
// Java source line #183 -> byte code offset #94
// Java source line #177 -> byte code offset #97
// Java source line #185 -> byte code offset #119
// Java source line #186 -> byte code offset #120
// Local variable table:
// start length slot name signature
// 0 131 0 this EntPayServiceImpl
// 0 131 1 publicKeyFile File
// 0 131 2 srcString String
// 16 51 3 cipher javax.crypto.Cipher
// 119 8 3 e Exception
// 32 68 4 reader org.bouncycastle.openssl.PEMParser
// 57 5 5 publicKey java.security.PublicKey
// 97 20 5 localThrowable Throwable
// 77 6 6 encrypt byte[]
// 107 5 6 localThrowable1 Throwable
// 87 8 7 str String
// Exception table:
// from to target type
// 34 89 97 java/lang/Throwable
// 99 104 107 java/lang/Throwable
// 0 94 119 java/lang/Exception
// 97 119 119 java/lang/Exception
}
}
The text was updated successfully, but these errors were encountered: