cancel
Showing results for 
Search instead for 
Did you mean: 
Subscribe

Hi Experts,

I have received both public and private keys from business and they are of type RSA-4096 with .ASC extension. The keys are generated by the business using a tool called GPG Keychain on a Mac machine. The keys are deployed on the server in the standard path - /usr/sap/<System ID>/<Instance ID>/sec

When I use them to encrypt the file, the encryption works fine but when I use the keys to decrypt the files, it fails in PI with the error:

com.sap.aii.af.lib.mp.module.ModuleException: File is no valid PGP Message, could not apply decryption.

The decryption is working fine in the tool but it is not working fine in SAP PI. Even a simple encrypted txt file (of extension .pgp) is failing with the above error. The configuration of the module is shown below in the snapshot:

Regards,

Arkesh

0 Likes
View Entire Topic
Former Member

Hello Arkesh,

Is the File encrypted + signed?

If yes you need to add the below in the module

partnerPublicKey

arkesh_sharma
Product and Topic Expert
Product and Topic Expert
0 Likes

Hi Raghuraman,

I checked with the person who created the encrypted file, he said it is not signed and only encrypted.

So I did not use partnerPublicKey parameter.

Former Member
0 Likes

Hello Arkesh,

Then this error could be due to wrong encryption of file and or any special characters/texts added in file by mistake.

Can you retest with new file or check if any issue is there in the file.

arkesh_sharma
Product and Topic Expert
Product and Topic Expert
0 Likes

Hi Raghuraman,

Is there a tool that you can suggest to find out the special characters in the encrypted file ?

Regards,

Arkesh

Former Member
0 Likes

Hello Arkesh,

You can decrypt using IGOLDER ,Manoj also suggested the same.

It could be due to wrong key or file issues(additional characters are something).