Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 122563
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T04:08:54+00:00 2026-05-11T04:08:54+00:00

We need to PGP encrypt files and send them over FTP to a third

  • 0

We need to PGP encrypt files and send them over FTP to a third party. The files are encrypted with the DH/DSS public key of the third party and signed with our private key.

The third party have our public key and their own private key. The encryption/decryption works, but the third party are getting warnings when they try to verify our signature.

When we try to decrypt and verify similarly encrypted files using PGP Desktop the files verify without warning.

The third party are using ‘McAfee E-Business Server’

The exact warning is: WARNING: Bad signature, doesn’t match file contents! Bad signature from user ‘users name’

The code is a little involved, but I posted it on my blog. I can post it here instead of a link if that is more appropriate.

Any insight as to how to solve this issue is appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T04:08:55+00:00Added an answer on May 11, 2026 at 4:08 am

    While I can’t give a thorough explanation as to the details of the problem, here is a solution that works. First of all it seems that the different PGP implementations are very sensitive to which program was used to genereate the keys in use.

    The failing scenario:

    1. Create keys in PGP Desktop (RSA v4, 2048/2048)
    2. Encrypt in BouncyCastle (DH/DSS, Elgamal)
    3. Sign in BouncyCastle (With the RSA key)
    4. Decryption and signature verification success in PGP Desktop.
    5. Decryption success but signature verification fails in McAfee Business Server.

    In order to make McAfee Business Server succeed in verifying the keys either create the keys in BouncyCastle using the code from the BouncyCastle source code.(Org.BouncyCastle.Bcpg.OpenPgp.Examples.RsaKeyRingGenerator) This code can be changed if you need specific key properties.

    Another alternative is to use McAfee Business Server to generate the keys. For that you need access to the software. I did my tests with a trial version. (Which by the way was a pain in the neck to get up and running)

    Update: I did all my tests on E-Business Server 8.5.3 (trial). I reached the point where I could encrypt and sign in Bounty and decrypt and verify in E-Business Server. Turns out the third party are using E-Business Server 7.0 which refused to verify the signature. In order to get everything working we needed to create V3 signatures.

    We changed from:

    PgpSignatureGenerator pgpSignatureGenerator = new PgpSignatureGenerator(m_encryptionKeys.SecretKey.PublicKey.Algorithm, HashAlgorithmTag.Sha1); 

    to

    PgpV3SignatureGenerator pgpV3SignatureGenerator = new PgpV3SignatureGenerator(m_encryptionKeys.SecretKey.PublicKey.Algorithm, HashAlgorithmTag.Sha1); 
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 120k
  • Answers 120k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer If you want the same key for encrypting and decrypting… May 12, 2026 at 12:15 am
  • Editorial Team
    Editorial Team added an answer A slightly indirect answer... Why don't you just setup DNS… May 12, 2026 at 12:15 am
  • Editorial Team
    Editorial Team added an answer If you were to have one central system for all… May 12, 2026 at 12:15 am

Related Questions

We need to capture live video and display easily on Linux. We need a
We need to move off traditional FTP for security purposes (it transmits it's passwords
We need to programatically burn files to CD in a C\C++ Windows XP/Vista application
We need to replace the menu system in our main ASP.NET application. So naturally

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.