Skip to content

解密 #1

Open
Open

Description

@FS1360472174

解密使用PKCS5PADDING没有遇到过错误吗
有些加密信息解密的时候报
javax.crypto.BadPaddingException: Given final block not properly padded
at com.sun.crypto.provider.CipherCore.doFinal(CipherCore.java:989) ~[?:?]

Activity

  1. sinofool commented on Apr 12, 2018

    @sinofool
    Owner

    没有遇到过,看异常是结尾没有补齐数据。是不是没传完?

  2. FS1360472174 commented on Apr 15, 2018

    @FS1360472174
    Author

    不是,官网说的是用7PADDING,但是实际用5也可以解密。
    估计有可能是频繁更新session-key不一致导致的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions