code: public static String privateKeyEncrypt(String key, String plainText) throws NoSuchAlgorithmException,
              InvalidKeySpecException, NoSuchPaddingException, UnsupportedEncodingException, BadPaddingException,
              IllegalBlockSizeException, InvalidKeyException {
          PrivateKey privateKey = commonGetPrivatekeyByText(key);
          Cipher cipher = Cipher.getInstance(RSA);
          cipher.init(Cipher.ENCRYPT_MODE, privateKey);
          byte [] result = cipher.doFinal(plainText.getBytes(Charset.UTF_8));
  
          return Base64.byteArrayToBase64(result);
      }
docs: 私钥加密
  @param key [ellipsis]
  @param plainText [ellipsis]
  @return [ellipsis]
  @throws NoSuchAlgorithmException [ellipsis]
  @throws InvalidKeySpecException [ellipsis]
  @throws NoSuchPaddingException [ellipsis]
  @throws UnsupportedEncodingException [ellipsis]
  @throws BadPaddingException [ellipsis]
  @throws IllegalBlockSizeException [ellipsis]
  @throws InvalidKeyException [ellipsis]