bc-csharp icon indicating copy to clipboard operation
bc-csharp copied to clipboard

Unable to Encrypt

Open jlandree opened this issue 5 years ago • 1 comments

Please see error info:

Stream clear = pbe.GetDataStream(sKey);

PgpObjectFactory plainFact = new PgpObjectFactory(clear);

PgpObject message = plainFact.NextPgpObject();

if (message is PgpCompressedData) { PgpCompressedData cData = (PgpCompressedData)message; PgpObjectFactory pgpFact = new PgpObjectFactory(cData.GetDataStream());

message = pgpFact.NextPgpObject(); }

The logic then returns False and falls into this reason:

string.Format(“Message is not a simple encrypted file. THe type unknown for file {0}”, outputFileName),

jlandree avatar Apr 27 '20 14:04 jlandree

This also affects the decryption.

jlandree avatar Apr 29 '20 16:04 jlandree