Skip to main content

Java SDK upload resulted in invlaid signature for my partner but I am able to upload just fine

Comments

1 comment

  • Aleksandar Kostadinov

    Hi An,

    The Signature parameter is calculated based on the parameters passed as part of the upload() method plus your cloud's API Secret. Given that you mentioned the code is the same, as you're using the same code repository, that leaves the API Secret value that is part of the SDK configuration.

    As a first step, I would recommend double-checking that the value of the api_secret that your partner has configured in the SDK is the right one - and specifically, that there are no leading or trailing whitespaces or characters missing from the start/end of the secret. When copying/pasting the api_secret, I've encountered cases where additional whitespace can accidentally be included before/after the api_secret string and due to that, it will cause a different signature to be generated (that is not valid) and hence the request will be rejected when it reaches Cloudinary.

    The other thing to check is if the permission/path of the environment file makes it accessible to the script you're running with the Cloudinary SDK. If the file can't be found and/or read for some reason, then the credentials won't make it into the SDK configuration and the signature would effectively be signed with an api_secret of empty string which will again cause the signature to be invalid.

    Please let us know how it goes.

    0

Post is closed for comments.